Skip to content

Support for traces in sessions #604

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jul 4, 2024
Merged

Support for traces in sessions #604

merged 1 commit into from
Jul 4, 2024

Conversation

alexandrosfilios
Copy link
Contributor

No description provided.

@alexandrosfilios alexandrosfilios requested a review from adecaro July 3, 2024 09:32
@alexandrosfilios alexandrosfilios marked this pull request as ready for review July 3, 2024 09:32
@@ -23,6 +24,7 @@ type Message struct {
FromPKID []byte // PK identifier of the caller
Status int32 // Message Status (OK, ERROR)
Payload []byte // Payload
Ctx context.Context
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is this guaranteed to be serializable?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it isn't, but it doesn't have to be

@@ -53,9 +55,15 @@ type Session interface {
// Send sends the payload to the endpoint
Send(payload []byte) error

// SendWithContext sends the payload to the endpoint with the passed context
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

does this mean that the context is part of the message or the context is used to control the send operation itself?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

no it's part of the message. it carries some information. in this case the span context

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would clarify in the comment then

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No but the context doesn't have to do only with the span. The span uses the context but the context has more functions in general, e.g. canceling the context, or adding baggage values

Signed-off-by: Alexandros Filios <[email protected]>
@adecaro adecaro self-requested a review July 4, 2024 15:55
Copy link
Contributor

@adecaro adecaro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@alexandrosfilios alexandrosfilios merged commit f31aaad into main Jul 4, 2024
18 checks passed
@alexandrosfilios alexandrosfilios deleted the f-traces-session branch July 4, 2024 16:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants