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

New API to register handlers, dont use init anymore #10

Merged
merged 7 commits into from
Oct 10, 2020
Merged

Conversation

arl
Copy link
Owner

@arl arl commented Oct 10, 2020

  • define Register(*http.ServeMux) and RegisterDefault() so that we don't force the default serve mux on library users (previously registered in init()).

  • modify examples to adapt to the new API

  • add _example/gorilla/mux.go to show how to register statsviz handlers with a gorilla mux router

  • update README to refect the new API

@arl arl changed the title Dont use init New API to register handlers, dont use init anymore Oct 10, 2020
@arl arl merged commit 589e395 into master Oct 10, 2020
@arl arl deleted the dont-use-init branch October 10, 2020 21:01
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.

1 participant