-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Cache swift authentication token in memcache #4116
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
Conversation
|
@icewind1991, thanks for your PR! By analyzing the history of the files in this pull request, we identified @butonic, @nickvergessen and @MorrisJobke to be potential reviewers. |
| $serviceName = null; | ||
| $cachedTokenString = $this->memcache->get('token'); | ||
| if ($cachedTokenString) { | ||
| $cachedToken = unserialize($cachedTokenString); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
https://github.com/nextcloud/3rdparty/blob/f5555fef8e80d8380efb44dc8b7622a1de573c15/rackspace/php-opencloud/lib/OpenCloud/OpenStack.php#L398-L409 claims this is an array. Can we use json_encode and json_decode thus? :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the array contains objects, so we can't json it
75c9a30 to
67fe4b2
Compare
|
@icewind1991 Conflicts :/ |
ad7a7b5 to
e3fe734
Compare
|
rebased |
Codecov Report
@@ Coverage Diff @@
## master #4116 +/- ##
============================================
- Coverage 54.2% 54.18% -0.03%
- Complexity 21294 21300 +6
============================================
Files 1310 1310
Lines 81253 81285 +32
Branches 1285 1285
============================================
+ Hits 44043 44044 +1
- Misses 37210 37241 +31
Continue to review full report at Codecov.
|
MorrisJobke
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested and works 👍
Signed-off-by: Robin Appelman <robin@icewind.nl>
Signed-off-by: Robin Appelman <robin@icewind.nl>
e3fe734 to
205d558
Compare
|
Updated the merged 3rdparty submodule. |
Signed-off-by: Robin Appelman <robin@icewind.nl>
2724561 to
6991b79
Compare
|
@LukasReschke switched to json @MorrisJobke please retest |
MorrisJobke
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Still works 👍
Prevents having to do an authentication roundtrip every request.
Requires