Skip to content

How to configure to use headers expiration date #146

@peterkimga

Description

@peterkimga

Hi

I use your package as a part of this implementation:

https://github.com/googleapis/google-api-php-client#caching

I got 2 problems with this. And I think you can help me with just the secound one. But I will tell you both of them anyway :)

  1. My application makes 2 calls at the same time and I got the error:
{
    "statusCode": 500,
    "error": {
        "type": "SERVER_ERROR",
        "description": "ERROR: unlink(\/home\/<server_name>\/domains\/<domain>\/app\/..\/cache\/federated_signon_certs_v3): No such file or directory on line 26a in file \/home\/<server_name>\/domains\/<domain>\/vendor\/league\/flysystem\/src\/Adapter\/Local.php."
    }
}

So the first request is deleting the file before it got the content and the second one comes in and it throws this error.

  1. The Google Auth keys are updated every 24h. There is a specific header telling when they will expire but the file is updated every 2h or so anyway. So the headers are ignored and it uses some default refresh value. If you know what should I add to this setup to use the headers expiry date so the first request after the expiry date will trigger the update of cache would be great.

Regards
Peter

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions