mirror of
https://github.com/Znote/ZnoteAAC.git
synced 2025-06-15 17:24:29 +02:00
Log IP performance issue workaround.
1000 latest records should suffice for the system to function properly. An OT server had issues when ip logger saved over 250 000 IPs (probably some sort of ddos attack), which got loaded into memory in each page render.
This commit is contained in:
parent
ee6841a12e
commit
6c036b0a1b
@ -132,7 +132,7 @@ function setCache($time) {
|
||||
|
||||
// Get visitor basic data
|
||||
function znote_visitors_get_data() {
|
||||
return mysql_select_multi("SELECT `ip`, `value` FROM `znote_visitors`");
|
||||
return mysql_select_multi("SELECT `ip`, `value` FROM `znote_visitors` ORDER BY `id` DESC LIMIT 1000;");
|
||||
}
|
||||
|
||||
// Set visitor basic data
|
||||
|
Loading…
x
Reference in New Issue
Block a user