Support

Admin Tools

#31645 Security Exceptions Log - Killed by "All"

Posted in ‘Admin Tools for Joomla! 4 & 5’
This is a public ticket

Everybody will be able to see its contents. Do not include usernames, passwords or any other sensitive information.

Environment Information

Joomla! version
n/a
PHP version
n/a
Admin Tools version
n/a

Latest post by nicholas on Tuesday, 20 August 2019 02:04 CDT

lausianne
Hi,

I have a bit more that 15000 entries in the log, now I'd like to clean up and remove all of them. Setting the list to 100 entries, I'd have to delete 150 pages. So I went for "All", and the page crashes before anything is deleted. ("Crash": sth. funny happens, maybe nothing, mostly it jumps back to the Joomla Control panel. Anyway, I cannot even reset to 100 now.

So I have 2 suggestions:
- Add additional numbers to the list, e.g.: 1000, 2000, 5000
- Add a button: Delete All

Thanks

Regards,
Ralf


EDIT: Eventually I was able to access the info page again: PHP 7.1.31, Admin Tools 5.3.3

nicholas
Akeeba Staff
Manager
The list limits are provided by Joomla itself. Do note that it doesn't make sense adding list limits as high as you wish. Not only this many records have to be loaded to PHP memory, they also have to be rendered into HTML (also in PHP memory) before being sent to the browser. According to my experience, a site with the typical 128MB limit on PHP memory can render around 250 to 400 records before PHP runs out of memory.

But this is irrelevant. A solution to that has existed for the better part of the last decade. Go to Extensions, Plugins. Edit "System - Admin Tools". Set "Maximum security exceptions log entries" to the number of records you want to keep (recommended: 1000). Give it a day of normal site operation.

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

lausianne
Hi Nicolas,

Thanks for your reply.

My limit is in fact 128MB. I should increase that. Anyway, Joomla lets me set the default list limit to 500. That would still be 30 pages, currently, but that's already more manageable. When I have the choice, I can figure out what works on my installation.

"Maximum security exceptions log entries" is very useful, thanks. It's probably more than a decade ago that I studied the docs ...

> Give it a day of normal site operation.
You mean just set and wait and it will remove 14 out of my 15k entries automatically? (set to 1k now)
I'll wait and see.

Thanks again.

Cheers,
Ralf

EDIT: worked, only 1000 left after a short while

nicholas
Akeeba Staff
Manager
Remember that 500 article titles are very different than 500 security exceptions, reasons, IP addresses and associated information that needs to be loaded, processed and rendered into HTML. Moreover, do keep in mind that we write our software to satisfy the overwhelming majority of uses cases, not just your case which happens to be the easiest one (128MB PHP memory, light site without tons of plugins that gobble up RAM, Joomla's debug mode disabled). I can tell you for a fact that on my very light test site with Joomla's debug mode enabled I can't display over 400 or so security exceptions and I definitely cannot display 500 articles. Do remember that limits can be changed using the limit query string parameter in the URL (that's how I tested it). Also note that my dev site is actually pretty lightweight compared to virtually every client site I had to work on. So, a limit over 100 is completely out of the question.

However, as I already made it clear, it's irrelevant because 500 items on a page (or even 100 come to think of it) is completely pointless. You are not expected to delete old log entries by hand, that would be absurd. You can not process a list that's 500 entries long either. Anything above 20 to 50 entries (depending on the list) is beyond human cognitive abilities.

Now, I understand why you argue about this, thinking that Joomla had a point for putting a limit of 500. Actually, no, they don't and it doesn't even work even on my very lightweight dev site. So why did they do that? Joomla has taken the architecturally wrong approach of putting this kind of massive and inoperable limits on its lists to handle batch processing. However, they only did that because they are incapable of doing basic software architecture and / or use common sense. The problem they're trying to solve is that given a set of filters you have hundreds or even thousands of articles you need to batch process (e.g. move between categories, assign a language, delete...). The correct and smart approach would be to add a checkbox in the batch processing dialog in the spirit of "Apply to all items matching the filter". It's something that literally every major e-mail client has implemented about 15 or so years ago.

So, to sum it up. Large limits are wrong and don't work. Joomla did something stupid. I won't implement someone else's stupid approach to an architecturally incorrect solution. I have a smarter, architecturally correct solution in Admin Tools that predates Joomla's stupid approach. I will stick with my solution as it causes no problems ;)

Nicholas K. Dionysopoulos

Lead Developer and Director

πŸ‡¬πŸ‡·Greek: native πŸ‡¬πŸ‡§English: excellent πŸ‡«πŸ‡·French: basic β€’ πŸ• My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!

Support Information

Working hours: We are open Monday to Friday, 9am to 7pm Cyprus timezone (EET / EEST). Support is provided by the same developers writing the software, all of which live in Europe. You can still file tickets outside of our working hours, but we cannot respond to them until we're back at the office.

Support policy: We would like to kindly inform you that when using our support you have already agreed to the Support Policy which is part of our Terms of Service. Thank you for your understanding and for helping us help you!