There are a lot of session types in magento 2 . The ones I know of are listed below ;

1)  \Magento\Catalog\Model\Session //vendor/magento/module-catalog/Model/Session.php

2) \Magento\Newsletter\Model\Session //vendor/magento/module-newsletter/Model/Session.php

3) \Magento\Persistent\Model\Session //vendor/magento/module-persistent/Model/Session.php

4) \Magento\Customer\Model\Session //vendor/magento/module-customer/Model/Session.php

5) \Magento\Backend\Model\Session //vendor/magento/module-backend/Model/Session.php

6) \Magento\Checkout\Model\Session //vendor/magento/module-checkout/Model/Session.php

Can someone please tell me about lifetime, scope and general usage for these sessions, so I can know which session to use when?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.