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] Automatic add pages to Queue after flush caches with cacheManager #869

Open
Patta opened this issue Dec 23, 2021 · 5 comments
Open
Labels

Comments

@Patta
Copy link
Contributor

Patta commented Dec 23, 2021

Is your feature request related to a problem? Please describe

It would be great if the feature "Automatic add pages to Queue" would also work after flush of caches with cacheManager.

For example, i have a finisher class for EXT:powermail which flush caches for specific pages after form submit with cacheManager->flushCachesByTags($cacheTags). The pages ($cacheTags) are currently not added automatically to the queue. Many thanks in advance.

Describe the solution you would like

No response

Describe alternatives you've considered

No response

Teachability, Documentation, Adoption, Migration Strategy

No response

@Patta Patta added the feature label Dec 23, 2021
@tomasnorre
Copy link
Owner

I know this issue is a quite old, but I have some questions.

When you say cache manager, what do you then mean? Do you mean a CacheManager extension?

@Patta
Copy link
Contributor Author

Patta commented May 22, 2024

@tomasnorre I have created a Gist with the example that should explain this: https://gist.github.com/Patta/688719f2f80f1d62909846a978d5e678

@tomasnorre
Copy link
Owner

Thank you so much. Think I get now what you mean.

If you are up for it, It would be happy to accept a PR adding this.
It will only be for the v12 version and forward though, features aren't backported to v11-releases.

@Patta
Copy link
Contributor Author

Patta commented May 23, 2024

Thank you for your feedback. I am currently not able to develop such a feature. I think there could be a new crawler event for

public function addFlushedPagesToCrawlerQueue(array $parameters, DataHandler $dataHandler): void
that could be triggered after cacheManager->flushCachesByTags in my custom powermail finisher.

@Patta
Copy link
Contributor Author

Patta commented May 23, 2024

Maybe it's out of scope, but it could be related or a new issue. The Page TSconfig command to clear page caches with specific cache tags is also not considered by addFlushedPagesToCrawlerQueue.

Example of Page TSconfig in a folder:

// only clear cache on change of pages which shows records from this folder
// root, news, news detail
TCEMAIN.clearCacheCmd = cacheTag:siteNews

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

No branches or pull requests

2 participants