Skip to content

Commit

Permalink
switch to struct not method
Browse files Browse the repository at this point in the history
  • Loading branch information
ankitpatel96 committed Oct 16, 2024
1 parent 83b585e commit b1ebb26
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions processor/schemaprocessor/internal/translation/revision_v1.go
Original file line number Diff line number Diff line change
Expand Up @@ -124,11 +124,11 @@ func newSpanEventChangeList(spanEvents ast.SpanEvents) *changelist.ChangeList {
acceptableEventNames = append(acceptableEventNames, string(eventName))
}

attributeChangeSet := migrate.NewMultiConditionalAttributeSet(renamedAttribute.AttributeMap, map[string][]string{
multiConditionalAttributeSet := migrate.NewMultiConditionalAttributeSet(renamedAttribute.AttributeMap, map[string][]string{
"span.name": acceptableSpanNames,
"event.name": acceptableEventNames,
})
spanEventAttributeChangeSet := operator.NewSpanEventConditionalAttributeOperator(attributeChangeSet)
spanEventAttributeChangeSet := operator.SpanEventConditionalAttributeOperator{MultiConditionalAttributeSet: multiConditionalAttributeSet}
values = append(values, spanEventAttributeChangeSet)
} else {
panic("spanEvents change must have either RenameEvents or RenameAttributes")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -227,15 +227,15 @@ func TestNewRevisionV1(t *testing.T) {
"started": "application started",
}),
},
operator.NewSpanEventConditionalAttributeOperator(
migrate.NewMultiConditionalAttributeSet(
operator.SpanEventConditionalAttributeOperator{
MultiConditionalAttributeSet: migrate.NewMultiConditionalAttributeSet(
map[string]string{"service.app.name": "service.name"},
map[string][]string{
"span.name": {"service running"},
"event.name": {"service errored"},
},
),
),
},
}},
metrics: &changelist.ChangeList{Migrators: []migrate.Migrator{
operator.MetricSignalNameChange{SignalNameChange: migrate.NewSignalNameChange(map[string]string{
Expand Down

0 comments on commit b1ebb26

Please sign in to comment.