Code Monkey home page Code Monkey logo

Comments (8)

Maks3w avatar Maks3w commented on June 14, 2024

If no BC break exists I think we can modify APC class for make internal calls to APCU.

At a second step we could rename the class with the correct "APCU" name and deprecate the old name. However there is no real wins of this so this could be do later.

from zend-cache.

remicollet avatar remicollet commented on June 14, 2024

If no BC break exists I think we can modify APC class for make internal calls to APCU.

I have to code ready on my computer, I'm waiting to ba able to run the test suite, before submitting a PR
https://github.com/remicollet/zend-cache/commits/issue-apcu

from zend-cache.

marc-mabe avatar marc-mabe commented on June 14, 2024

@remicollet @Maks3w I would prefer to add an Apcu adapter and make the Apc adapter as deprecated as I noticed that HHVM only supports the old APC methods.

I already worked on an Apcu adapter but currently I get some strange failures on travis that I don't get on my local machine.
-> https://github.com/marc-mabe/zend-cache/tree/feature/23/src/Storage/Adapter
-> https://travis-ci.org/marc-mabe/zend-cache/builds/90415153

from zend-cache.

marc-mabe avatar marc-mabe commented on June 14, 2024

Link to the other discussion : #23

from zend-cache.

remicollet avatar remicollet commented on June 14, 2024

I would prefer to add an Apcu adapter

I understand, even if I will prefer something transparent for users...

from zend-cache.

marc-mabe avatar marc-mabe commented on June 14, 2024

To summarize as I understand:

  • The Apc adapter was originally developed to be a wrapper for the APC extension
  • Later it was going to be also a wrapper for others that support the same interface as the APC extension (APCu and HHVM)
  • HHVM has (or had) a small difference in it metadata reporting - see https://github.com/zendframework/zend-cache/blob/master/src/Storage/Adapter/Apc.php#L717
  • APCu fully supports the APC interface but only if compiled with APC compatibility
  • The APCu extension has a small incompatibility in it's interface if compiled with or without APC compatibility as it's using the same class APCIterator but with different arguments

So for me it would be 100% transparent introducing a new Apcu adapter wrapping only the new APCu extension and leaving the Apc extension as is But mark it as deprecated to inform that this adapter could be dropped in the future but not before there exists an alternative for the minimum PHP version + HHVM.

So the only question I have should the new Apcu adapter support the APCu extension including the APCIterator inconsistency or not. Currently I think it needs to be supported to make the switch to APCu simpler.

from zend-cache.

Maks3w avatar Maks3w commented on June 14, 2024

I whink there are possible two choices:

  • Wait until HHVM adopt apcu_ methods.
  • Continue and to have both adapters. I think in this case APC should extend from the new APCu

from zend-cache.

marc-mabe avatar marc-mabe commented on June 14, 2024

closed by 2cd809d

from zend-cache.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.