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

Add simple Prometheus update metrics #2899

Merged
merged 1 commit into from
Jan 23, 2023

Conversation

bbockelm
Copy link
Contributor

We are observing some timeouts in the topology webapp logs around update intervals. Provide some clarity by adding a Prometheus endpoint and exporting the update timing.

We are observing some timeouts in the topology webapp logs around
update intervals.  Provide some clarity by adding a Prometheus
endpoint and exporting the update timing.
Copy link
Collaborator

@matyasselmeci matyasselmeci left a comment

Choose a reason for hiding this comment

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

LGTM though I don't have any experience with either prometheus-client and or DispatcherMiddleware. How do you test it?

Also, can you add a link to the /metrics endpoint to the front page (src/templates/homepage.html.j2, under "XML and other machine-readable data")

@matyasselmeci
Copy link
Collaborator

I can add it too.

@matyasselmeci matyasselmeci merged commit a49de09 into opensciencegrid:master Jan 23, 2023
@matyasselmeci
Copy link
Collaborator

I just realized this adds a dependency on prometheus-client to models.py. We can't do that -- models.py is also used by various scripts such as osg-scitokens-mapfile. Sorry, I have to revert.

@bbockelm
Copy link
Contributor Author

@matyasselmeci - how should we resolve this? Create dummy objects if the import fails?

@matyasselmeci
Copy link
Collaborator

That's the approach I'm thinking of, too.

@brianhlin
Copy link
Member

Create dummy objects if the import fails?

@matyasselmeci did you get around to this?

@matyasselmeci
Copy link
Collaborator

I didn't realize it was on my plate, so no.

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.

3 participants