:zap: Simple Cache Abstraction Layer for PHP

Overview

Build Status FOSSA Status Coverage Status Scrutinizer Code Quality Codacy Badge Latest Stable Version Total Downloads License Donate to this project using Paypal Donate to this project using Patreon

Simple Cache Class

This is a simple Cache Abstraction Layer for PHP >= 7.0 that provides a simple interaction with your cache-server. You can define the Adapter / Serializer in the "constructor" or the class will auto-detect you server-cache in this order:

  1. Memcached / Memcache
  2. Redis
  3. Xcache
  4. APC / APCu
  5. OpCache (via PHP-files)
  6. Static-PHP-Cache

Get "Simple Cache"

You can download it from here, or require it using composer.

{
  "require": {
    "voku/simple-cache": "4.*"
  }
}

Install via "composer require"

composer require voku/simple-cache

Quick Start

use voku\cache\Cache;

require_once 'composer/autoload.php';

$cache = new Cache();
$ttl = 3600; // 60s * 60 = 1h
$cache->setItem('foo', 'bar', $ttl);
$bar = $cache->getItem('foo');

Usage

use voku\cache\Cache;

$cache = new Cache();
  
if ($cache->getCacheIsReady() === true && $cache->existsItem('foo')) {
  return $cache->getItem('foo');
} else {
  $bar = someSpecialFunctionsWithAReturnValue();
  $cache->setItem('foo', $bar);
  return $bar;
}

If you have an heavy task e.g. a really-big-loop, then you can also use static-cache. But keep in mind, that this will be stored into PHP (it needs more memory).

use voku\cache\Cache;

$cache = new Cache();
  
if ($cache->getCacheIsReady() === true && $cache->existsItem('foo')) {
  for ($i = 0; $i <= 100000; $i++) {
    echo $this->cache->getItem('foo', 3); // use also static-php-cache, when we hit the cache 3-times
  }
  return $cache->getItem('foo');
} else {
  $bar = someSpecialFunctionsWithAReturnValue();
  $cache->setItem('foo', $bar);
  return $bar;
}

PS: By default, the static cache is also used by >= 10 cache hits. But you can configure this behavior via $cache->setStaticCacheHitCounter(INT).

No-Cache for the admin or a specific ip-address

If you use the parameter "$checkForUser" (=== true) in the constructor, then the cache isn't used for the admin-session.

-> You can also overwrite the check for the user, if you add a global function named "checkForDev()".

Overwrite the auto-connection option

You can overwrite the cache auto-detect via "CacheAdapterAutoManager" and the "$cacheAdapterManagerForAutoConnect" option in the "Cache"-constructor. Additional you can also activate the "$cacheAdapterManagerForAutoConnectOverwrite" option in the "Cache"-constructor, so that you can implement your own cache auto-detect logic.

$cacheManager = new \voku\cache\CacheAdapterAutoManager();

// 1. check for "APCu" support first
$cacheManager->addAdapter(
    \voku\cache\AdapterApcu::class
);

// 2. check for "APC" support
$cacheManager->addAdapter(
    \voku\cache\AdapterApcu::class
);

// 3. try "OpCache"-Cache
$cacheManager->addAdapter(
    \voku\cache\AdapterOpCache::class,
    static function () {
        $cacheDir = \realpath(\sys_get_temp_dir()) . '/simple_php_cache_opcache';

        return $cacheDir;
    }
);

// 4. try "File"-Cache
$cacheManager->addAdapter(
    \voku\cache\AdapterFileSimple::class,
    static function () {
        $cacheDir = \realpath(\sys_get_temp_dir()) . '/simple_php_cache_file';

        return $cacheDir;
    }
);


// 5. use Memory Cache as final fallback
$cacheManager->addAdapter(
    \voku\cache\AdapterArray::class
);

$cache = new \voku\cache\CachePsr16(
    null, // use auto-detection
    null, // use auto-detection
    false, // do not check for usage
    true, // enable the cache
    false, // do not check for admin session
    false, // do not check for dev
    false, // do not check for admin session
    false, // do not check for server vs. client ip
    '', // do not use "_GET"-parameter for disabling
    $cacheManager, // new auto-detection logic
    true // overwrite the auto-detection logic
);

Support

For support and donations please visit Github | Issues | PayPal | Patreon.

For status updates and release announcements please visit Releases | Twitter | Patreon.

For professional support please contact me.

Thanks

  • Thanks to GitHub (Microsoft) for hosting the code and a good infrastructure including Issues-Managment, etc.
  • Thanks to IntelliJ as they make the best IDEs for PHP and they gave me an open source license for PhpStorm!
  • Thanks to Travis CI for being the most awesome, easiest continous integration tool out there!
  • Thanks to StyleCI for the simple but powerfull code style check.
  • Thanks to PHPStan && Psalm for relly great Static analysis tools and for discover bugs in the code!

License

FOSSA Status

Comments
  • Cleaning .gitignore

    Cleaning .gitignore

    None of this crap needs to be here, besides /vendor/, which is a root-relative directory, hence the enclosing slashes. Moreover, the previous version of this file ignored composer.lock which is usually incorrect.

    opened by Bilge 5
  • Upgrade code to work in PHP8 or greater and/or Laravel 9 or greater

    Upgrade code to work in PHP8 or greater and/or Laravel 9 or greater

    Fixes: https://github.com/voku/simple-cache/issues/29

    This repo doesn't work in PHP 8, 8.1 or 8.2 due to the namespaces not being Capitalized.

    • Have updated the namespaces.
    • Have updated composer.json and removed php 7 as security updates ended in 28 November 2022.
    • Have updated readme with new namespaces

    Need to update the connecting repos now.

    Linked to Pull Requests

    https://github.com/voku/html-compress-twig/pull/5

    https://github.com/voku/HtmlMin/pull/85

    https://github.com/voku/simple_html_dom/pull/95

    https://github.com/voku/simple-cache/pull/30

    https://github.com/voku/portable-ascii/pull/87

    Tested on the following

    Tested on PHP 8.2 and Laravel 9.1


    This change is Reviewable

    opened by summercms 4
  • Possible to set cache dir?

    Possible to set cache dir?

    Are feature requests okay here?

    If I see that correctly the OpCache Constructor supports setting a cache dir, but the class above (Cache) seems to have no way to actually to set that variable when calling that constructor. Is there a way to configure it?

    On some shared hosters you do not actually want to write to the configured PHP tmp directory, but rather to a project specific tmp directory.

    opened by onli 4
  • Update phpunit/phpunit requirement from ~6.0 || ~7.0 to ~6.0 || ~7.0 || ~8.0

    Update phpunit/phpunit requirement from ~6.0 || ~7.0 to ~6.0 || ~7.0 || ~8.0

    Updates the requirements on phpunit/phpunit to permit the latest version.

    Changelog

    Sourced from phpunit/phpunit's changelog.

    8.0.1 - 2019-02-03

    Fixed

    • Fixed #3509: Process Isolation does not work with phpunit.phar

    [8.0.0] - 2019-02-01

    Changed

    • Implemented #3060: Cleanup PHPUnit\Framework\Constraint\Constraint
    • Implemented #3133: Enable dependency resolution by default
    • Implemented #3236: Define which parts of PHPUnit are covered by the backward compatibility promise
    • Implemented #3244: Enable result cache by default
    • Implemented #3288: The void_return fixer of php-cs-fixer is now in effect
    • Implemented #3439: Improve colorization of TestDox output
    • Implemented #3444: Consider data provider that provides data with duplicate keys to be invalid
    • Implemented #3467: Code location hints for [**requires**](https://github.com/requires) annotations as well as --SKIPIF--, --EXPECT--, --EXPECTF--, --EXPECTREGEX--, and --{SECTION}_EXTERNAL-- sections of PHPT tests
    • Implemented #3481: Improved --help output

    Deprecated

    • Implemented #3332: Deprecate annotation(s) for expecting exceptions
    • Implemented #3338: Deprecate assertions (and helper methods) that operate on (non-public) attributes
    • Implemented #3341: Deprecate optional parameters of assertEquals() and assertNotEquals()
    • Implemented #3369: Deprecate assertInternalType() and assertNotInternalType()
    • Implemented #3388: Deprecate the TestListener interface
    • Implemented #3425: Deprecate optional parameters of assertContains() and assertNotContains() as well as using these methods with string haystacks
    • Implemented #3494: Deprecate assertArraySubset()

    Removed

    • Implemented #2762: Drop support for PHP 7.1
    • Implemented #3123: Remove PHPUnit_Framework_MockObject_MockObject

    [8.0.0]: https://github.com/sebastianbergmann/phpunit/compare/7.5...8.0.0

    Commits

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot ignore this [patch|minor|major] version will close this PR and stop Dependabot creating any more for this minor/major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language
    • @dependabot badge me will comment on this PR with code to add a "Dependabot enabled" badge to your readme

    Additionally, you can set the following in your Dependabot dashboard:

    • Update frequency (including time of day and day of week)
    • Automerge options (never/patch/minor, and dev/runtime dependencies)
    • Pull request limits (per update run and/or open at any time)
    • Out-of-range updates (receive only lockfile updates, if desired)
    • Security updates (receive only security updates, if desired)

    Finally, you can contact us by mentioning @dependabot.


    This change is Reviewable

    dependencies 
    opened by dependabot-preview[bot] 4
  • Add license scan report and status

    Add license scan report and status

    Your FOSSA integration was successful! Attached in this PR is a badge and license report to track scan status in your README.

    Below are docs for integrating FOSSA license checks into your CI:


    This change is Reviewable

    opened by fossabot 3
  • 2.0.1 composer breaks simple-mysqli

    2.0.1 composer breaks simple-mysqli

    This is fixed in master but it isn't pushed as a release so it has broken simple-mysqli suddenly.

    "autoload": {
        "psr-0": {
            "voku": "src"
        }
    }
    

    Needs to be:

    "autoload": {
        "psr-0": {
            "voku\\cache\\": "src"
        }
    }
    
    opened by igloocube 3
  • Update phpunit/phpunit requirement from ~6.0 to ~6.0 || ~7.0

    Update phpunit/phpunit requirement from ~6.0 to ~6.0 || ~7.0

    Updates the requirements on phpunit/phpunit to permit the latest version.

    Changelog

    Sourced from phpunit/phpunit's changelog.

    7.5.1 - 2018-12-12

    Fixed

    • Fixed #3441: Call to undefined method DataProviderTestSuite::usesDataProvider()

    [7.5.0] - 2018-12-07

    Added

    • Implemented #3340: Added assertEqualsCanonicalizing(), assertEqualsIgnoringCase(), assertEqualsWithDelta(), assertNotEqualsCanonicalizing(), assertNotEqualsIgnoringCase(), and assertNotEqualsWithDelta() as alternatives to using assertEquals() and assertNotEquals() with the $delta, $canonicalize, or $ignoreCase parameters
    • Implemented #3368: Added assertIsArray(), assertIsBool(), assertIsFloat(), assertIsInt(), assertIsNumeric(), assertIsObject(), assertIsResource(), assertIsString(), assertIsScalar(), assertIsCallable(), assertIsIterable(), assertIsNotArray(), assertIsNotBool(), assertIsNotFloat(), assertIsNotInt(), assertIsNotNumeric(), assertIsNotObject(), assertIsNotResource(), assertIsNotString(), assertIsNotScalar(), assertIsNotCallable(), assertIsNotIterable() as alternatives to assertInternalType() and assertNotInternalType()
    • Implemented #3391: Added a TestHook that fires after each test, regardless of result
    • Implemented #3417: Refinements related to test suite sorting and TestDox result printer
    • Implemented #3422: Added assertStringContainsString(), assertStringContainsStringIgnoringCase(), assertStringNotContainsString(), and assertStringNotContainsStringIgnoringCase()

    Deprecated

    • The methods assertInternalType() and assertNotInternalType() are now deprecated. There is no behavioral change in this version of PHPUnit. Using these methods will trigger a deprecation warning in PHPUnit 8 and in PHPUnit 9 these methods will be removed.
    • The methods assertAttributeContains(), assertAttributeNotContains(), assertAttributeContainsOnly(), assertAttributeNotContainsOnly(), assertAttributeCount(), assertAttributeNotCount(), assertAttributeEquals(), assertAttributeNotEquals(), assertAttributeEmpty(), assertAttributeNotEmpty(), assertAttributeGreaterThan(), assertAttributeGreaterThanOrEqual(), assertAttributeLessThan(), assertAttributeLessThanOrEqual(), assertAttributeSame(), assertAttributeNotSame(), assertAttributeInstanceOf(), assertAttributeNotInstanceOf(), assertAttributeInternalType(), assertAttributeNotInternalType(), attributeEqualTo(), readAttribute(), getStaticAttribute(), and getObjectAttribute() are now deprecated. There is no behavioral change in this version of PHPUnit. Using these methods will trigger a deprecation warning in PHPUnit 8 and in PHPUnit 9 these methods will be removed.
    • The optional parameters $delta, $maxDepth, $canonicalize, and $ignoreCase of assertEquals() and assertNotEquals() are now deprecated. There is no behavioral change in this version of PHPUnit. Using these parameters will trigger a deprecation warning in PHPUnit 8 and in PHPUnit 9 these parameters will be removed.
    • The annotations [**expectedException**](https://github.com/expectedException), [**expectedExceptionCode**](https://github.com/expectedExceptionCode), [**expectedExceptionMessage**](https://github.com/expectedExceptionMessage), and [**expectedExceptionMessageRegExp**](https://github.com/expectedExceptionMessageRegExp) are now deprecated. There is no behavioral change in this version of PHPUnit. Using these annotations will trigger a deprecation warning in PHPUnit 8 and in PHPUnit 9 these annotations will be removed.
    • Using the methods assertContains() and assertNotContains() on string haystacks is now deprecated. There is no behavioral change in this version of PHPUnit. Using these methods on string haystacks will trigger a deprecation warning in PHPUnit 8 and in PHPUnit 9 these methods cannot be used on on string haystacks anymore.
    • The optional parameters $ignoreCase, $checkForObjectIdentity, and $checkForNonObjectIdentity of assertContains() and assertNotContains() are now deprecated. There is no behavioral change in this version of PHPUnit. Using these parameters will trigger a deprecation warning in PHPUnit 8 and in PHPUnit 9 these parameters will be removed.

    Fixed

    • Fixed #3428: TestSuite setup failures are not logged correctly
    • Fixed #3429: Inefficient loop in getHookMethods()
    • Fixed #3437: JUnit logger skips PHPT tests

    [7.5.0]: https://github.com/sebastianbergmann/phpunit/compare/7.4.5...7.5.0

    Commits

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Note: This repo was added to Dependabot recently, so you'll receive a maximum of 5 PRs for your first few update runs. Once an update run creates fewer than 5 PRs we'll remove that limit.

    You can always request more updates by clicking Bump now in your Dependabot dashboard.

    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot ignore this [patch|minor|major] version will close this PR and stop Dependabot creating any more for this minor/major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    • @dependabot use these labels will set the current labels as the default for future PRs for this repo and language
    • @dependabot use these reviewers will set the current reviewers as the default for future PRs for this repo and language
    • @dependabot use these assignees will set the current assignees as the default for future PRs for this repo and language
    • @dependabot use this milestone will set the current milestone as the default for future PRs for this repo and language
    • @dependabot badge me will comment on this PR with code to add a "Dependabot enabled" badge to your readme

    Additionally, you can set the following in your Dependabot dashboard:

    • Update frequency (including time of day and day of week)
    • Automerge options (never/patch/minor, and dev/runtime dependencies)
    • Pull request limits (per update run and/or open at any time)
    • Out-of-range updates (receive only lockfile updates, if desired)
    • Security updates (receive only security updates, if desired)

    Finally, you can contact us by mentioning @dependabot.


    This change is Reviewable

    dependencies 
    opened by dependabot-preview[bot] 2
  • Pin dependency phpunit/phpunit to v7.5.20 - autoclosed

    Pin dependency phpunit/phpunit to v7.5.20 - autoclosed

    Mend Renovate

    This PR contains the following updates:

    | Package | Type | Update | Change | |---|---|---|---| | phpunit/phpunit (source) | require-dev | pin | ~6.0 \|\| ~7.0 -> 7.5.20 |

    Add the preset :preserveSemverRanges to your config if you don't want to pin your dependencies.


    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

    Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, click this checkbox.

    This PR has been generated by Mend Renovate. View repository job log here.


    This change is Reviewable

    opened by renovate[bot] 1
  • Configure Renovate

    Configure Renovate

    Mend Renovate

    Welcome to Renovate! This is an onboarding PR to help you understand and configure settings before regular Pull Requests begin.

    🚦 To activate Renovate, merge this Pull Request. To disable Renovate, simply close this Pull Request unmerged.


    Detected Package Files

    • composer.json (composer)

    Configuration Summary

    Based on the default config's presets, Renovate will:

    • Start dependency updates only once this onboarding PR is merged
    • Enable Renovate Dependency Dashboard creation
    • If semantic commits detected, use semantic commit type fix for dependencies and chore for all others
    • Ignore node_modules, bower_components, vendor and various test/tests directories
    • Autodetect whether to pin dependencies or maintain ranges
    • Rate limit PR creation to a maximum of two per hour
    • Limit to maximum 10 open PRs at any time
    • Group known monorepo packages together
    • Use curated list of recommended non-monorepo package groupings
    • A collection of workarounds for known problems with packages

    🔡 Would you like to change the way Renovate is upgrading your dependencies? Simply edit the renovate.json in this branch with your custom config and the list of Pull Requests in the "What to Expect" section below will be updated the next time Renovate runs.


    What to Expect

    With your current configuration, Renovate will create 3 Pull Requests:

    Pin dependency phpunit/phpunit to v
    • Schedule: ["at any time"]
    • Branch name: renovate/pin-dependencies
    • Merge into: master
    • Pin phpunit/phpunit to 7.5.20
    Update dependency phpunit/phpunit to v9
    • Schedule: ["at any time"]
    • Branch name: renovate/phpunit-phpunit-9.x
    • Merge into: master
    • Upgrade phpunit/phpunit to 9.5.21
    Update dependency psr/simple-cache to v3
    • Schedule: ["at any time"]
    • Branch name: renovate/psr-simple-cache-3.x
    • Merge into: master
    • Upgrade psr/simple-cache to ~3.0

    🚸 Branch creation will be limited to maximum 2 per hour, so it doesn't swamp any CI resources or spam the project. See docs for prhourlylimit for details.


    ❓ Got questions? Check out Renovate's Docs, particularly the Getting Started section. If you need any further assistance then you can also request help here.


    This PR has been generated by Mend Renovate. View repository job log here.


    This change is Reviewable

    opened by renovate[bot] 1
  • opcache function call will cause warnings in hosting environments

    opcache function call will cause warnings in hosting environments

    For security reasons it's common to restrict the opcache API in shared webhosting environments.

    This is usually no problem, because applications have little reason to call into the opcache api directly. But in your library (which recently got added as a dependency to the serendipity blog software) this is the case, and it will cause warnings like:

    Warning: Zend OPcache API is restricted by "restrict_api" configuration directive in [path]/bundled-libs/voku/simple-cache/src/voku/cache/AdapterOpCache.php:32
    

    See here for a similar issue in wp super cache: https://github.com/Automattic/wp-super-cache/issues/536

    One workaround would be to prefix the \opcache_get_status() with @ to avoid the warning, i.e. change the code to:

                self::$hasCompileFileFunction = \function_exists('opcache_compile_file') && !empty(@Bilge @\opcache_get_status());
    
    opened by hannob 1
  • Tidy up Travis definition

    Tidy up Travis definition

    Binaries don't need to be explicitly run through the PHP interpreter because they're binaries. PHPUnit already looks in the working directory for phpunit.xml.

    opened by Bilge 1
  • Update dependency psr/simple-cache to v3

    Update dependency psr/simple-cache to v3

    Mend Renovate

    This PR contains the following updates:

    | Package | Type | Update | Change | |---|---|---|---| | psr/simple-cache | require | major | ~1.0 -> ~3.0 |


    Release Notes

    php-fig/simple-cache

    v3.0.0

    Compare Source

    • Adds return types

    See the meta doc, section Errata for more details: https://www.php-fig.org/psr/psr-16/meta/

    v2.0.0

    Compare Source

    • Adds parameter types
    • Makes CacheException extend \Throwable
    • Requires PHP 8

    See the meta doc, section Errata for more details: https://www.php-fig.org/psr/psr-16/meta/


    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

    Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.


    This change is Reviewable

    opened by renovate[bot] 1
  • Dependency Dashboard

    Dependency Dashboard

    This issue lists Renovate updates and detected dependencies. Read the Dependency Dashboard docs to learn more.

    Open

    These updates have all been created already. Click a checkbox below to force a retry/rebase of any.

    Detected dependencies

    composer
    composer.json
    • php >=7.0.0
    • psr/simple-cache ~1.0
    • phpunit/phpunit ~6.0 || ~7.0

    • [ ] Check this box to trigger a request for Renovate to run again on this repository
    opened by renovate[bot] 0
  • Update dependency phpunit/phpunit to v9

    Update dependency phpunit/phpunit to v9

    Mend Renovate

    This PR contains the following updates:

    | Package | Type | Update | Change | |---|---|---|---| | phpunit/phpunit (source) | require-dev | major | ~6.0 \|\| ~7.0 -> ~6.0 \|\| ~7.0 \|\| ~9.0 |


    Release Notes

    sebastianbergmann/phpunit

    v9.5.26

    Compare Source

    v9.5.25

    Compare Source

    v9.5.24

    Compare Source

    v9.5.23

    Compare Source

    v9.5.22

    Compare Source

    v9.5.21

    Compare Source

    v9.5.20

    Compare Source

    v9.5.19

    Compare Source

    v9.5.18

    Compare Source

    v9.5.17

    Compare Source

    v9.5.16

    Compare Source

    v9.5.14

    Compare Source

    v9.5.13

    Compare Source

    v9.5.12

    Compare Source

    v9.5.11

    Compare Source

    v9.5.10

    Compare Source

    v9.5.9

    Compare Source

    v9.5.8

    Compare Source

    v9.5.7

    Compare Source

    v9.5.6

    Compare Source

    v9.5.5

    Compare Source

    v9.5.4

    Compare Source

    v9.5.3

    Compare Source

    v9.5.2

    Compare Source

    v9.5.1

    Compare Source

    v9.5.0

    Compare Source

    v9.4.4

    Compare Source

    v9.4.3

    Compare Source

    v9.4.2

    Compare Source

    v9.4.1

    Compare Source

    v9.4.0

    Compare Source

    v9.3.11

    Compare Source

    v9.3.10

    Compare Source

    v9.3.9

    Compare Source

    v9.3.8

    Compare Source

    v9.3.7

    Compare Source

    v9.3.6

    Compare Source

    v9.3.5

    Compare Source

    v9.3.4

    Compare Source

    v9.3.3

    Compare Source

    v9.3.2

    Compare Source

    v9.3.1

    Compare Source

    v9.3.0

    Compare Source

    v9.2.6

    Compare Source

    v9.2.5

    Compare Source

    v9.2.4

    Compare Source

    v9.2.3

    Compare Source

    v9.2.2

    Compare Source

    v9.2.1

    Compare Source

    v9.2.0

    Compare Source

    v9.1.5

    Compare Source

    v9.1.4

    Compare Source

    v9.1.3

    Compare Source

    v9.1.2

    Compare Source

    v9.1.1

    Compare Source

    v9.1.0

    Compare Source

    v9.0.2

    Compare Source

    v9.0.1

    Compare Source

    v9.0.0

    Compare Source

    v8.5.31

    Compare Source

    v8.5.30

    Compare Source

    v8.5.29

    Compare Source

    v8.5.28

    Compare Source

    v8.5.27

    Compare Source

    v8.5.26

    Compare Source

    v8.5.25

    Compare Source

    v8.5.24

    Compare Source

    v8.5.23

    Compare Source

    v8.5.22

    Compare Source

    v8.5.21

    Compare Source

    v8.5.20

    Compare Source

    v8.5.19

    Compare Source

    v8.5.18

    Compare Source

    v8.5.17

    Compare Source

    v8.5.16

    Compare Source

    v8.5.15

    Compare Source

    v8.5.14

    Compare Source

    v8.5.13

    Compare Source

    v8.5.12

    Compare Source

    v8.5.11

    Compare Source

    v8.5.10

    Compare Source

    v8.5.9

    Compare Source

    v8.5.8

    Compare Source

    v8.5.7

    Compare Source

    v8.5.6

    Compare Source

    v8.5.5

    Compare Source

    v8.5.4

    Compare Source

    v8.5.3

    Compare Source

    v8.5.2

    Compare Source

    v8.5.1

    Compare Source

    v8.5.0

    Compare Source

    v8.4.3

    Compare Source

    v8.4.2

    Compare Source

    v8.4.1

    Compare Source

    v8.4.0

    Compare Source

    v8.3.5

    Compare Source

    v8.3.4

    Compare Source

    v8.3.3

    Compare Source

    v8.3.2

    Compare Source

    v8.3.1

    Compare Source

    v8.3.0

    Compare Source

    v8.2.5

    Compare Source

    v8.2.4

    Compare Source

    v8.2.3

    Compare Source

    v8.2.2

    Compare Source

    v8.2.1

    Compare Source

    v8.2.0

    Compare Source

    v8.1.6

    Compare Source

    v8.1.5

    Compare Source

    v8.1.4

    Compare Source

    v8.1.3

    Compare Source

    v8.1.2

    Compare Source

    v8.1.1

    Compare Source

    v8.1.0

    Compare Source

    v8.0.6

    Compare Source

    v8.0.5

    Compare Source

    v8.0.4

    Compare Source

    v8.0.3

    Compare Source

    v8.0.2

    Compare Source

    v8.0.1

    Compare Source

    v8.0.0

    Compare Source


    Configuration

    📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

    🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

    Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

    🔕 Ignore: Close this PR and you won't be reminded about this update again.


    • [ ] If you want to rebase/retry this PR, check this box

    This PR has been generated by Mend Renovate. View repository job log here.


    This change is Reviewable

    opened by renovate[bot] 1
  • Plesk disables opcache_get_cache() in PHP

    Plesk disables opcache_get_cache() in PHP

    Hi Lars

    Plesk changed its defaults to use Plesk 17.8.11 - PHP value "disable_functions" changed to default value "opcache_get_status" And Hosters tend do follow this approach. ​ /src/voku/cache/AdapterOpCache.php in Line 36 uses !empty(@\opcache_get_cache()) to check that op cache is enabled.

    PHP 7.4 is @silenced, but PHP 8 errors in Userland. This disabled method could be replaced by

    !empty(@\opcache_get_configuration())
    

    I assume we better have something like

    $opcache_get_configuration['directives']['opcache.enable'] === true
    

    to ensure opcache is really enabled.

    What do you think?

    opened by ophian 1
  • Upgrade to GitHub-native Dependabot

    Upgrade to GitHub-native Dependabot

    Dependabot Preview will be shut down on August 3rd, 2021. In order to keep getting Dependabot updates, please merge this PR and migrate to GitHub-native Dependabot before then.

    Dependabot has been fully integrated into GitHub, so you no longer have to install and manage a separate app. This pull request migrates your configuration from Dependabot.com to a config file, using the new syntax. When merged, we'll swap out dependabot-preview (me) for a new dependabot app, and you'll be all set!

    With this change, you'll now use the Dependabot page in GitHub, rather than the Dependabot dashboard, to monitor your version updates, and you'll configure Dependabot through the new config file rather than a UI.

    If you've got any questions or feedback for us, please let us know by creating an issue in the dependabot/dependabot-core repository.

    Learn more about migrating to GitHub-native Dependabot

    Please note that regular @dependabot commands do not work on this pull request.


    This change is Reviewable

    dependencies 
    opened by dependabot-preview[bot] 2
Owner
Lars Moelleken
Webdeveloper & Sysadmin | egrep '#php|#js|#html|#css|#sass'
Lars Moelleken
A thin PSR-6 cache wrapper with a generic interface to various caching backends emphasising cache tagging and indexing.

Apix Cache, cache-tagging for PHP Apix Cache is a generic and thin cache wrapper with a PSR-6 interface to various caching backends and emphasising ca

Apix 111 Nov 26, 2022
Simple and swift MongoDB abstraction.

Monga A simple and swift MongoDB abstraction layer for PHP 5.4+ What's this all about? An easy API to get connections, databases and collections. A fi

The League of Extraordinary Packages 330 Nov 28, 2022
The next-generation caching layer for PHP

The next-generation caching layer for PHP

CacheWerk 115 Dec 25, 2022
Simple artisan command to debug your redis cache. Requires PHP 8.1 & Laravel 9

?? php artisan cache:debug Simple artisan command to debug your redis cache ?? Installation You can install the package via composer: composer require

Juan Pablo Barreto 19 Sep 18, 2022
DataLoaderPhp is a generic utility to be used as part of your application's data fetching layer to provide a simplified and consistent API over various remote data sources such as databases or web services via batching and caching.

DataLoaderPHP is a generic utility to be used as part of your application's data fetching layer to provide a simplified and consistent API over various remote data sources such as databases or web services via batching and caching.

Webedia - Overblog 185 Nov 3, 2022
Simple cache

Simple cache

Róbert Kelčák 3 Dec 17, 2022
A simple cache library. Implements different adapters that you can use and change easily by a manager or similar.

Desarolla2 Cache A simple cache library, implementing the PSR-16 standard using immutable objects. Caching is typically used throughout an applicatito

Daniel González 129 Nov 20, 2022
A simple cache library. Implements different adapters that you can use and change easily by a manager or similar.

Desarolla2 Cache A simple cache library, implementing the PSR-16 standard using immutable objects. Caching is typically used throughout an applicatito

Daniel González 129 Nov 20, 2022
PHP cache library, with adapters for e.g. Memcached, Redis, Couchbase, APC(u), SQL and additional capabilities (e.g. transactions, stampede protection) built on top.

Donate/Support: Documentation: https://www.scrapbook.cash - API reference: https://docs.scrapbook.cash Table of contents Installation & usage Adapters

Matthias Mullie 295 Nov 28, 2022
LRU Cache implementation in PHP

PHP LRU Cache implementation Intro WTF is a LRU Cache? LRU stands for Least Recently Used. It's a type of cache that usually has a fixed capacity and

Rogério Vicente 61 Jun 23, 2022
Elephant - a highly performant PHP Cache Driver for Kirby 3

?? Kirby3 PHP Cache-Driver Elephant - a highly performant PHP Cache Driver for Kirby 3 Commerical Usage Support open source! This plugin is free but i

Bruno Meilick 11 Apr 6, 2022
PHP local cache

__ ____ _________ ______/ /_ ___ / __ \/ ___/ __ `/ ___/ __ \/ _ \ / /_/ / /__/ /_/ / /__/ / / / __/ / ._

Jayden Lie 48 Sep 9, 2022
A fast, lock-free, shared memory user data cache for PHP

Yac is a shared and lockless memory user data cache for PHP.

Xinchen Hui 815 Dec 18, 2022
PHP Cache Duration

PHP Cache Duration Introduction A readable and fluent way to generate PHP cache time. Built and written by Ajimoti Ibukun Quick Samples Instead of thi

null 27 Nov 8, 2022
Distributed PSR-16 cache implementation for PHP 6 that uses browser cookies to store data

cookiecache Cache beyond the edge with cookies! This library provides a distributed PSR-16 compatible cache implementation for PHP 6 that uses browser

Colin O'Dell 8 Apr 19, 2022
PHP cache implementation supporting memcached

php cache implementation (PSR-6 and PSR-16) Support for memcached and APCu is included. Memcached $memcached = new Memcached(); $memcached->addServer(

Michael Bretterklieber 1 Aug 11, 2022
The place to keep your cache.

Stash - A PHP Caching Library Stash makes it easy to speed up your code by caching the results of expensive functions or code. Certain actions, like d

Tedious Developments 944 Jan 4, 2023
Cache slam defense using a semaphore to prevent dogpile effect.

metaphore PHP cache slam defense using a semaphore to prevent dogpile effect (aka clobbering updates, stampending herd or Slashdot effect). Problem: t

Przemek Sobstel 102 Sep 28, 2022