IntellectualSites / Plot2Dynmap

PlotSquared dynmap addon
Apache License 2.0
8 stars 6 forks source link

Use non persistent markers for dynmap #140

Open GNUGradyn opened 1 year ago

GNUGradyn commented 1 year ago

Server Implementation

Paper

Server Version

1.19.3

Describe the bug

Plots2Dynmap creates a TON of dynmap markers. This is fine, but they should be created as non-persistent. Otherwise it will create a TON of persistent markers and clog up the database/file.

If dynmap is in file tree mode this may go unnoticed, but will wreck havoc in SQL mode. This is because Dynmap stores persistent markers as a single gigantic JSON object. This is not ideal (which I have reported here https://github.com/webbukkit/dynmap/issues/3954), but should not be a problem here since the markers have no reason to be persistent in this case anyway. image

The result of this is every time the markers are updated, it hangs the entire dynmap sql server for a while since it has to update this gigantic string. This results in dynmap sporadically being completely nonfunctional at best and never functional at worst. image

To Reproduce

  1. Install Plots2Dynmap (Preferrably with a large world)
  2. Configure dynmap to use SQL (I used MySQL but im sure you'd get the same result with sqlite)
  3. perform a dynmap fullrender
  4. Watch as the row in dynmap.MarkerFiles grows to an insane size, as all of the markers are being created as persistent

Expected behaviour

Markers are created as non-persistent and therefore do not explode the database

Screenshots / Videos

No response

Error log (if applicable)

No response

Plot Debugpaste

https://athion.net/ISPaster/paste/view/40ff9624b74145d6a3d3b409198c9ff2

Plot2Dynmap Version

6.0.3

Checklist

Anything else?

Server is 1.19.4 but that was not an option in the drop down