Game Query Cache
Is your feature request related to a problem? Please describe.
Now SourceBans++ queries all servers again and again when we open SB page.
Describe the solution you'd like
I suggest add the query cache. Data may sometimes differ from real data, but the server will deal less with processing SB++ requests. I see two ways for implementing cache:
- When user requests SB++ page, web checks the relevance of cached data, and if data is too old (saved 30 seconds ago, by example), he requests data again and saves in cache.
- Plugin sometimes sends data to DB manually (player list (with SteamIDs: this can also solve a problem with
statusparsing when we add a ban or comm ban fromServerspage), current map, hostname, max players slots, etc.).
This will be one of them first features that will be worked on after SourceBans++ 1.7.0 releases as a stable version.
I think caching in the webpanel should be enough. Server Queries (responsible for loading more casual data e.g map, hostname, simple player data) could be cached quite agressive (multiple minutes). RCON commands on the other hand mostly serve to deliver misson critical data (e.g when you want to kick a player) so I wouldn't cache that data to agressive (maybe a few seconds not much longer)