From be74e0c4f2186e829dacb2d9c5d7f42132c4308c Mon Sep 17 00:00:00 2001 From: Matt Lord Date: Fri, 31 Jan 2025 11:29:28 -0500 Subject: [PATCH] Don't use ephemeral code for journal event participants Don't retry if topo server can't resolve in the vtgate Signed-off-by: Matt Lord --- go/vt/vtgate/vstream_manager.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/go/vt/vtgate/vstream_manager.go b/go/vt/vtgate/vstream_manager.go index 3a8e98f1c66..4b0b4ba812b 100644 --- a/go/vt/vtgate/vstream_manager.go +++ b/go/vt/vtgate/vstream_manager.go @@ -170,7 +170,7 @@ func (vsm *vstreamManager) VStream(ctx context.Context, tabletType topodatapb.Ta } if ts == nil { log.Errorf("unable to get topo server in VStream()") - return vterrors.Errorf(vtrpcpb.Code_FAILED_PRECONDITION, "unable to get topoology server") + return vterrors.Errorf(vtrpcpb.Code_INTERNAL, "unable to get topoology server") } vs := &vstream{ vgtid: vgtid, @@ -956,7 +956,7 @@ func (vs *vstream) getJournalEvent(ctx context.Context, sgtid *binlogdatapb.Shar mode = matchAll je.participants[inner] = false case matchNone: - return nil, vterrors.Errorf(vtrpcpb.Code_FAILED_PRECONDITION, "not all journaling participants are in the stream: journal: %v, stream: %v", + return nil, vterrors.Errorf(vtrpcpb.Code_INTERNAL, "not all journaling participants are in the stream: journal: %v, stream: %v", journal.Participants, vs.vgtid.ShardGtids) } continue nextParticipant @@ -966,7 +966,7 @@ func (vs *vstream) getJournalEvent(ctx context.Context, sgtid *binlogdatapb.Shar case undecided, matchNone: mode = matchNone case matchAll: - return nil, vterrors.Errorf(vtrpcpb.Code_FAILED_PRECONDITION, "not all journaling participants are in the stream: journal: %v, stream: %v", + return nil, vterrors.Errorf(vtrpcpb.Code_INTERNAL, "not all journaling participants are in the stream: journal: %v, stream: %v", journal.Participants, vs.vgtid.ShardGtids) } }