chore: update go-eventlogger (#3707)

* chore: update go-eventlogger
This commit is contained in:
Irena Rindos authored and GitHub committed 2023-09-12 11:03:18 -04:00
1 parent 9733a250fa
commit 6f10a0ac87
5 files changed
+17 -12

No files matched your search

+1 -1
View File
@@ -23,7 +23,7 @@ require (
github.com/hashicorp/boundary/sdk v0.0.35
github.com/hashicorp/cap v0.3.3
github.com/hashicorp/dawdle v0.4.0
github.com/hashicorp/eventlogger v0.1.2-0.20230428153751-cca445805f24
github.com/hashicorp/eventlogger v0.2.4
github.com/hashicorp/eventlogger/filters/encrypt v0.1.8-0.20230428153751-cca445805f24
github.com/hashicorp/go-bexpr v0.1.12
github.com/hashicorp/go-cleanhttp v0.5.2
+2 -2
View File
@@ -306,8 +306,8 @@ github.com/hashicorp/dbassert v0.0.0-20230622135851-cc4c0f18f4a7/go.mod h1:1J4pH
github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
github.com/hashicorp/errwrap v1.1.0 h1:OxrOeh75EUXMY8TBjag2fzXGZ40LB6IKw45YeGUDY2I=
github.com/hashicorp/errwrap v1.1.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4=
github.com/hashicorp/eventlogger v0.1.2-0.20230428153751-cca445805f24 h1:vtCJgcxwDMFrpUgVMfjtwXY1YqvHbj8pNA7GsXYEoLg=
github.com/hashicorp/eventlogger v0.1.2-0.20230428153751-cca445805f24/go.mod h1://CHt6/j+Q2lc0NlUB5af4aS2M0c0aVBg9/JfcpAyhM=
github.com/hashicorp/eventlogger v0.2.4 h1:necVV63wmgRlQCjjDrm7NLCyqmNM8OAvGfcSP0KJXNI=
github.com/hashicorp/eventlogger v0.2.4/go.mod h1://CHt6/j+Q2lc0NlUB5af4aS2M0c0aVBg9/JfcpAyhM=
github.com/hashicorp/eventlogger/filters/encrypt v0.1.8-0.20230428153751-cca445805f24 h1:mopKPTxSaVr24uSysyRwywTDs85L5b05qqZvEkWa0qc=
github.com/hashicorp/eventlogger/filters/encrypt v0.1.8-0.20230428153751-cca445805f24/go.mod h1:EQPLoX6CONA9BSYUovTQBHfPGE91g7wOxv03sO29FzY=
github.com/hashicorp/go-bexpr v0.1.12 h1:XrdVhmwu+9iYxIUWxsGVG7NQwrhzJZ0vR6nbN5bLgrA=
+9 -4
View File
@@ -482,10 +482,15 @@ func (b *testMockBroker) Send(ctx context.Context, t eventlogger.EventType, payl
}
return eventlogger.Status{}, nil
}
func (b *testMockBroker) Reopen(ctx context.Context) error { return nil }
func (b *testMockBroker) RegisterPipeline(def eventlogger.Pipeline) error { return nil }
func (b *testMockBroker) StopTimeAt(t time.Time) {}
func (b *testMockBroker) RegisterNode(id eventlogger.NodeID, node eventlogger.Node) error { return nil }
func (b *testMockBroker) Reopen(ctx context.Context) error { return nil }
func (b *testMockBroker) RegisterPipeline(def eventlogger.Pipeline, opt ...eventlogger.Option) error {
return nil
}
func (b *testMockBroker) StopTimeAt(t time.Time) {}
func (b *testMockBroker) RegisterNode(id eventlogger.NodeID, node eventlogger.Node, opt ...eventlogger.Option) error {
return nil
}
func (b *testMockBroker) SetSuccessThreshold(t eventlogger.EventType, successThreshold int) error {
return nil
}
+3 -3
View File
@@ -59,9 +59,9 @@ type broker interface {
Send(ctx context.Context, t eventlogger.EventType, payload any) (eventlogger.Status, error)
Reopen(ctx context.Context) error
StopTimeAt(now time.Time)
RegisterNode(id eventlogger.NodeID, node eventlogger.Node) error
RegisterNode(id eventlogger.NodeID, node eventlogger.Node, opt ...eventlogger.Option) error
SetSuccessThreshold(t eventlogger.EventType, successThreshold int) error
RegisterPipeline(def eventlogger.Pipeline) error
RegisterPipeline(def eventlogger.Pipeline, opt ...eventlogger.Option) error
}
// queuedEvent stores an event and the context that was associated with it when
@@ -241,7 +241,7 @@ func NewEventer(log hclog.Logger, serializationLock *sync.Mutex, serverName stri
case opts.withBroker != nil:
b = opts.withBroker
default:
b = eventlogger.NewBroker()
b, _ = eventlogger.NewBroker()
}
e := &Eventer{
+2 -2
View File
@@ -325,7 +325,7 @@ func (b *testMockBroker) Reopen(ctx context.Context) error {
return nil
}
func (b *testMockBroker) RegisterPipeline(def eventlogger.Pipeline) error {
func (b *testMockBroker) RegisterPipeline(def eventlogger.Pipeline, opt ...eventlogger.Option) error {
b.pipelines = append(b.pipelines, def)
return nil
}
@@ -341,7 +341,7 @@ func (b *testMockBroker) StopTimeAt(t time.Time) {
b.stopTimeAt = t
}
func (b *testMockBroker) RegisterNode(id eventlogger.NodeID, node eventlogger.Node) error {
func (b *testMockBroker) RegisterNode(id eventlogger.NodeID, node eventlogger.Node, opt ...eventlogger.Option) error {
b.registeredNodeIds = append(b.registeredNodeIds, id)
return nil
}