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

adds grpc-ecosystem go-grpc-prometheus interceptors to server.go #254

Merged
merged 2 commits into from
May 29, 2020

Conversation

michaelschiff
Copy link
Collaborator

@michaelschiff michaelschiff commented Feb 12, 2020

This change is Reviewable

@michaelschiff
Copy link
Collaborator Author

Not sure how you feel about the addition of another dependency, but its nice to have the same standard metrics on all grpc services. Another option is giving the user an ability to pass options to the GRPC server (which may actually be more flexible long-term).

Copy link
Contributor

@jgraettinger jgraettinger left a comment

Choose a reason for hiding this comment

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

I'm wary here because once added it can't be removed. I'd actually like to move away from "official" client-side metrics instrumentation in favor of #235 , and am a believer in decoupling responsibility for metric identification/extraction/aggregation from services themselves.

That said, one idea that occurs to me though is there's no particular reason the GRPCServer needs to be created in New. That could instead be a responsibility of InitApplication. It'd require moving RegisterShardServer to after InitApplication, and creating a default GRPCServer if one hasn't been yet, but that seems pretty minor?

Then the application has full flexibility to wire up any grpc.ServerOptions it wants.

Reviewable status: 0 of 2 files reviewed, all discussions resolved (waiting on @jgraettinger)

@michaelschiff
Copy link
Collaborator Author

I agree, that feels like a more flexible approach.

@jgraettinger jgraettinger merged commit e3f9135 into gazette:master May 29, 2020
@jgraettinger
Copy link
Contributor

Reconsidered this, and believe it's a good idea. Building on the grpc-prometheus ecosystem allows for things like mixing in prepackaged Grafana dashboards / Prometheus rules / alerts etc for exploring these metrics (though to be honest I'm not finding much, beyond grpc-ecosystem/go-grpc-prometheus#68)

@michaelschiff michaelschiff deleted the feature/grpc-ecosystem branch May 30, 2020 00:59
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.

None yet

2 participants