Conversation
Signed-off-by: majkio <michal.hodan@protonmail.com>
mikeee
left a comment
There was a problem hiding this comment.
I think it'd be good to consolidate the getStringValueFromExtension() helper function to an internal package e.g. internal/structpb so that we're not duplicating code unnecessarily. I'd also in an ideal world like to see some debugging to differentiate between whether a key has a value declared as "" or whether the key is missing alltogether. What do you think?
tthophan
left a comment
There was a problem hiding this comment.
Decision: comment · Confidence: 95%
Adds TraceID and TraceParent extraction from TopicEvent extensions. Duplicated helper function getStringValueFromExtension in two packages.
| @@ -297,3 +300,18 @@ func (s *Subscription) closeStreamOnly() error { | |||
| } | |||
There was a problem hiding this comment.
Move getStringValueFromExtension to service/common or internal to avoid duplication with service/grpc/topic.go.
| func (s *Server) OnBulkTopicEventAlpha1(ctx context.Context, in *runtimev1pb.TopicEventBulkRequest) (*runtimev1pb.TopicEventBulkResponse, error) { | ||
| panic("This API callback is not supported.") | ||
| } | ||
|
|
There was a problem hiding this comment.
Duplicated helper. Move to shared location.
Description
Added support for extracting TraceId and TraceParent from Cloud Events Extension
Issue reference
Please reference the issue this PR will close: #355
Checklist
Please make sure you've completed the relevant tasks for this PR, out of the following list: