You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I use this method in combination with fastAPI in order to expose metrics over the API. The data come from a JSON file saved on Linux system (where the service runs).
When changing the values in the file in order to create metrics the metric value does not change, only when restarting the web server (Uvicorn).
Why are the changed values not recalculated?
For opening the file I use the standard command with open('filename.json', mode = 'r') as f:
Thank you in advance for the feedback!
The text was updated successfully, but these errors were encountered:
Would you be able to provide more details? If you are not re-reading (and possibly re-opening) the file on each request I can imagine the file in the Python process not being updated.
Hi,
I use this method in combination with fastAPI in order to expose metrics over the API. The data come from a JSON file saved on Linux system (where the service runs).
When changing the values in the file in order to create metrics the metric value does not change, only when restarting the web server (Uvicorn).
Why are the changed values not recalculated?
For opening the file I use the standard command with open('filename.json', mode = 'r') as f:
Thank you in advance for the feedback!
The text was updated successfully, but these errors were encountered: