Skip to content

There should be an option to let cache pool handle expiration, instead of having to set expires_at #49

@ostrolucky

Description

@ostrolucky
Q A
Version 1.5.0

When creating cache pool (e.g. in Symfony), user must choose default lifetime. When using php-http cache-plugin, user must again configure default_ttl option.

These two options do the same thing. There should be a way to configure cache plugin to let expire cache items organically by cache pool.

This is problematic, because lot of times I create separate cache pools for each http client and I have to duplicate this configuration and making sure changes in them are propagated to all places.

Furthermore, cache plugin implements expiration functionality by itself unnecessarily. There is no need to store expiresAt data, that's what is $cacheItem->expiresAfter() call for.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions