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

Stored Request Cache Bug? #338

Closed
dbemiller opened this issue Feb 12, 2018 · 2 comments
Closed

Stored Request Cache Bug? #338

dbemiller opened this issue Feb 12, 2018 · 2 comments
Assignees
Labels

Comments

@dbemiller
Copy link
Contributor

dbemiller commented Feb 12, 2018

The other day, I saw some weird behavior.

@anwzhang sent me an HTTP payload with Stored Request IDs to reproduce an issue she was seeing. I didn't see the same behavior locally. I retried the request several times, and always got back the same result. After a meeting, I tried it again and got a different error. Again, the result was consistent. Later that day, I tried it again and got the result she expected.

Judging by the symptoms, I think this is a bug in the Stored Request cache. Unfortunately I don't remember exactly what the response was on the first call for each of these cases... but with local dev & remote database, it's very common that the first request to the DB times out, and subsequent ones work fine.

I think what's happening is that the call to the database returns some corrupt data, which we then save to the cache. Depending on exactly when the request times out, we can see different behavior for the same request.

@dbemiller dbemiller self-assigned this Feb 12, 2018
@dbemiller dbemiller added the bug label Feb 12, 2018
@dbemiller
Copy link
Contributor Author

I found these issues, which may also be related: golang/go#23519 and lib/pq#706

@dbemiller
Copy link
Contributor Author

As a workaround for now, I think we should only send back stored request data if all of it comes back error-free.

One botched request isn't a big deal... as long as we don't cache bad response data. And if we can only resolve "some" of the stored request data, then it still probably won't make a valid auction request anyway.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants