Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: opcache_evict #234

Open
if-kenn opened this issue Aug 29, 2018 · 1 comment
Open

Feature request: opcache_evict #234

if-kenn opened this issue Aug 29, 2018 · 1 comment

Comments

@if-kenn
Copy link

if-kenn commented Aug 29, 2018

With the use of frameworks like Symphony, and the use of composer, many PHP apps are literally more than 10,000 php files like Drupal 8 which is based on Symphony.

I understand that OpCache does not want to implement any kind of automatic eviction algorithms. That said, adding a function like:

bool opcache_invalidate ( string $script )

Would allow eviction to be self-managed. There might be some architectural reason something like this does not already exist, but if there is not I would very much like to be able to throw scripts out of cache to make room for more recently used scripts.

Thanks for consideration.

@nikic
Copy link
Contributor

nikic commented Aug 29, 2018

This is technically impossible within the current architecture. The only way to actually free up space (in a way that allows it to be reused) is through an opcache restart.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants