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
We noticed that occasionally GET requests for markets.json return empty result. The problem always corrects itself without intervention. It also always happens 2-3s after past a minute which makes me thing it's related with the following cronjob:
If there is a temporary storate slowness we can serve empty or incomplete file for a brief moment.
It would be good to make the update operation atomic (simple way could be to write markets.json.new and then move to markets.json but there may be a better way in go).
The text was updated successfully, but these errors were encountered:
We noticed that occasionally GET requests for markets.json return empty result. The problem always corrects itself without intervention. It also always happens 2-3s after past a minute which makes me thing it's related with the following cronjob:
I looked at the code and the file is truncated using
os.Create()
and then written again:https://github.com/stellar/go/blob/master/services/ticker/internal/utils/main.go#L21
If there is a temporary storate slowness we can serve empty or incomplete file for a brief moment.
It would be good to make the update operation atomic (simple way could be to write markets.json.new and then move to markets.json but there may be a better way in go).
The text was updated successfully, but these errors were encountered: