Coder Social home page Coder Social logo

Comments (12)

makasim avatar makasim commented on July 26, 2024

Is this working without Module Cache?

from payummodule.

nickurt avatar nickurt commented on July 26, 2024

With 'module_map_cache_enabled' enabled it works, but not with 'config_cache_enabled'.

from payummodule.

makasim avatar makasim commented on July 26, 2024

I am not sure where the bag comes from... you can try to move the logic of storage and payment creation to the services and use in config only service names. Hope it helps.

from payummodule.

makasim avatar makasim commented on July 26, 2024

Cuz as I see it tries to cache the config, and serialize it. The Storage is not designed to be serialized.

from payummodule.

nickurt avatar nickurt commented on July 26, 2024

When I add the factories tot the config file, I still got the error ...

'factories' => array(
        'payum' => 'Payum\PayumModule\Registry\RegistryFactory',
        'payum.options' => 'Payum\PayumModule\Options\PayumOptionsFactory',
        'payum.security.token_storage' => 'Payum\PayumModule\Security\TokenStorageFactory',
        'payum.security.http_request_verifier' => 'Payum\PayumModule\Security\HttpRequestVerifierFactory',
),

I followed this configuration steps

from payummodule.

makasim avatar makasim commented on July 26, 2024

you have to add factories for storage and payment, objects created in the config. The idea is not have a config with simple types, strings, scalars, arrays but not objects. So it could be easy serialized and cached

from payummodule.

nickurt avatar nickurt commented on July 26, 2024

I understand that, so there is no example/possibility to have 'factory classes' and not 'factory closures' in the config file?

from payummodule.

makasim avatar makasim commented on July 26, 2024

if you configure it will work, the payum support such use case, but yes there is not an example how to setup.... should be easy though.

from payummodule.

makasim avatar makasim commented on July 26, 2024

something like this, add a factory (you can also use a closure):

'factories' => array(
    'payment.paypal_express_checkout' => 'Acme\AcmePaymentModule\PaypalPaymentFactory',
    'payment.token_storage' => 'Acme\AcmePaymentModule\TokenStorageFactory',
    'payment.details_storage' => 'Acme\AcmePaymentModule\DetailsStorageFactory',
),

and add it to payum config:

return array(
    'payum' => array(
        'token_storage' => 'payment.token_storage',
        'payments' => array(
            'paypal' => 'payment.paypal_express_checkout',
        ),
        'storages' => array(
            'Payments\Model\PaymentDetails' => 'payment.details_storage',
        ),
    ),
);

from payummodule.

makasim avatar makasim commented on July 26, 2024

Not sure about token_storage, if it does not it has to be fixed.

from payummodule.

nickurt avatar nickurt commented on July 26, 2024

You have to change the 'createService' functions, for now, I will disabled it and I hope it will be solved in the future.

from payummodule.

nickurt avatar nickurt commented on July 26, 2024

Since I've been moved to SpeckPaypal and created a wip/demo app of it, this can be closed.

from payummodule.

Related Issues (12)

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.