Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 10 additions & 1 deletion eppoclient/assignmentlogger.go
Original file line number Diff line number Diff line change
@@ -1,11 +1,20 @@
package eppoclient

import "fmt"
import (
"context"
"fmt"
)

// IAssignmentLogger is be deprecated at next major version
// and replaced by IAssignmentLoggerContext
type IAssignmentLogger interface {
LogAssignment(event AssignmentEvent)
}

type IAssignmentLoggerContext interface {
LogAssignment(context.Context, AssignmentEvent)
}

Comment on lines 10 to +17
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks for adding this. would appreciate a comment on IAssignmentLogger declaring it deprecated at next major version.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added the comment πŸ‘

// BanditActionLogger is going to be merged into IAssignmentLogger in
// the next major version.
type BanditActionLogger interface {
Expand Down
2 changes: 1 addition & 1 deletion eppoclient/bandits_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ func Test_bandits_sdkTestData(t *testing.T) {
logger := new(mockLogger)
logger.Mock.On("LogAssignment", mock.Anything).Return()
logger.Mock.On("LogBanditAction", mock.Anything).Return()
client := newEppoClient(configStore, nil, nil, logger, applicationLogger)
client := newEppoClient(configStore, nil, nil, logger, nil, applicationLogger)

tests := readJsonDirectory[banditTest]("test-data/ufc/bandit-tests/")
for file, test := range tests {
Expand Down
Loading