Serialization/Deadlock issue under high load

Created on 9 March 2017, about 8 years ago
Updated 7 October 2024, 6 months ago

When there're mutiple concurrent requests using the same access_token (being an Authorization header of an access_token query parameter), the update of the last usage timestamp of the token leads to a database serialization issue. The exception bubbles and leads to the access being denied.

It happens on relatively moderate trafic (~10 simultaneous HTTP request using the same token).

If I comment out

// Track last access on the token.
$this->logAccessTime($token);

in OAuth2Storage::getAccessToken(), everything goes smoothly (albeit the timestamp not being updated, obviously).

I do not see any way to easily solve this.

🐛 Bug report
Status

RTBC

Version

1.0

Component

Code

Created by

🇨🇦Canada garphy

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

Production build 0.71.5 2024