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

Head script caching issue #2282

Open
lscorcia opened this issue Aug 14, 2023 · 3 comments
Open

Head script caching issue #2282

lscorcia opened this issue Aug 14, 2023 · 3 comments

Comments

@lscorcia
Copy link

Hi, we are using Fabrik to display some tables on a public-facing website. We noticed that when bots come index our site, the number of sessions ballons (not a Fabrik issue), but we also noticed that those sessions tend to become larger and larger, up to several megabytes, effectively DDOSsing our session storage.
We decoded a few of those session vars and we noticed that the bulk of their size is due to the Fabrik head script cache, i.e.:

https://github.com/Fabrik/fabrik/blob/master/plugins/system/fabrik/fabrik.php#L217-L251

The issue is that there is no upper bound on the number of URLs whose scripts will be cached. Ideally, one should keep just a handful of cache entries around in session, the latest 10 or 20 would be plenty, but in our codebase we easily reach 900+ URLs per session!

The problem is heavily visible when bots show up as they do not throttle their requests like a human would do and can easily submit thousands of requests in a single session.

Any idea about how to fix this problem?
Thanks in advance

@trob
Copy link

trob commented Aug 14, 2023

This is Fabrik 3 for Joomla!3 which will reach its end-of-life in 3 days.

@lscorcia
Copy link
Author

Yep, I know. Unfortunately we'll have to keep Joomla 3 for the foreseeable future (not my choice). Would Fabrik for J!4 be affected by this issue as of now?

@trob
Copy link

trob commented Aug 15, 2023

I can't see any code change in F4 in this case

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