Skip to content
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

Don't flag errors in class "Success" #1

Merged
merged 1 commit into from
Sep 16, 2018

Conversation

bboreham
Copy link
Contributor

E.g. if the operation was cancelled, that's not an error.

Fixes grpc-ecosystem/grpc-opentracing#44

E.g. if the operation was cancelled, that's not an error.

Signed-off-by: Bryan Boreham <[email protected]>
@rnburn
Copy link
Collaborator

rnburn commented Sep 15, 2018

LGTM

Though, I'm not sure what that client argument is suppose to be for. Could it be simplified to

	if c != Success {
		ext.Error.Set(span, true)
	}

@rnburn
Copy link
Collaborator

rnburn commented Sep 15, 2018

I suppose it's there so that the server doesn't mark its span as an error if the problem originated from the client.

@rnburn rnburn merged commit 57cc2ef into opentracing-contrib:master Sep 16, 2018
@rnburn
Copy link
Collaborator

rnburn commented Sep 16, 2018

@bboreham - Looks like there's a test case that also needs to be updated for this https://circleci.com/gh/opentracing-contrib/go-grpc/2?utm_campaign=vcs-integration-link&utm_medium=referral&utm_source=github-build-link.

Could you put in a follow up PR for it?

@bboreham
Copy link
Contributor Author

I'm not sure what that client argument is suppose to be for.

I too was puzzled.

I suppose it's there so that the server doesn't mark its span as an error if the problem originated from the client.

That can't be it - client can only turn the error flag on in that line

@bboreham
Copy link
Contributor Author

@rnburn note I created #2 to fix the test case

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

How to avoid logging a cancelled operation as an error?
3 participants