Skip to content

Commit

Permalink
feat: add a log line for knowing when a keyspace event is received
Browse files Browse the repository at this point in the history
Signed-off-by: Manan Gupta <[email protected]>
  • Loading branch information
GuptaManan100 committed Dec 3, 2024
1 parent ffb17e7 commit fa39c67
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion go/vt/vtgate/buffer/buffer.go
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ func CausedByFailover(err error) bool {
log.V(2).Infof("Checking error (type: %T) if it is caused by a failover. err: %v", err, err)
reason, isFailover := isFailoverError(err)
if isFailover {
log.V(2).Infof("CausedByFailover signalling failover for reason: %s", reason)
log.Infof("CausedByFailover signalling failover for reason: %s", reason)
}
return isFailover
}
Expand Down Expand Up @@ -208,6 +208,7 @@ func (b *Buffer) WaitForFailoverEnd(ctx context.Context, keyspace, shard string,
}

func (b *Buffer) HandleKeyspaceEvent(ksevent *discovery.KeyspaceEvent) {
log.Infof("Keyspace Event received for keyspace %v", ksevent.Keyspace)
for _, shard := range ksevent.Shards {
sb := b.getOrCreateBuffer(shard.Target.Keyspace, shard.Target.Shard)
if sb != nil {
Expand Down

0 comments on commit fa39c67

Please sign in to comment.