mirror of
https://github.com/fluencelabs/tendermint
synced 2025-06-24 02:01:43 +00:00
use the tag interface for pubsub. (#1438)
* use the tag interface for pubsub. * update tmlibs. * Fix unresolved conflict.
This commit is contained in:
committed by
Anton Kaliaev
parent
d93e177a69
commit
6a48bd0c88
@ -67,7 +67,7 @@ func (b *EventBus) UnsubscribeAll(ctx context.Context, subscriber string) error
|
||||
func (b *EventBus) Publish(eventType string, eventData TMEventData) error {
|
||||
// no explicit deadline for publishing events
|
||||
ctx := context.Background()
|
||||
b.pubsub.PublishWithTags(ctx, eventData, map[string]interface{}{EventTypeKey: eventType})
|
||||
b.pubsub.PublishWithTags(ctx, eventData, tmpubsub.NewTagMap(map[string]interface{}{EventTypeKey: eventType}))
|
||||
return nil
|
||||
}
|
||||
|
||||
@ -114,7 +114,7 @@ func (b *EventBus) PublishEventTx(event EventDataTx) error {
|
||||
logIfTagExists(TxHeightKey, tags, b.Logger)
|
||||
tags[TxHeightKey] = event.Height
|
||||
|
||||
b.pubsub.PublishWithTags(ctx, event, tags)
|
||||
b.pubsub.PublishWithTags(ctx, event, tmpubsub.NewTagMap(tags))
|
||||
return nil
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user