Holographic Displays

Holographic Displays

3M Downloads

Lag with EntityNMSWitherSkull.getEntityID()

Eufranio opened this issue ยท 16 comments

commented

This method dropped my server to about 3 TPS, you can see the WarmRoast report here. Using Thermos 1.7.10 build 58 and HolographicDisplays v2.2.3.

commented

Just cleaned my server and it had 70k horses and 70k wither skulls, I suspect to be HolographicDisplays:

[04:46:23 INFO]: Removed 140941 entities. ( 6 x Botania.botania:spark ,  4 x Zombie ,  6 x Thaumcraft.Wisp ,  1 x Arrow ,  3 x Thaumcraft.GiantBrainyZombie ,  9 x MinecartChest ,  4 x witchery.hellhound ,  3 x Skeleton ,  5 x Creeper ,  7 x Blaze ,  49 x Item ,  70308 x EntityHorse ,  1 x Spider ,  13 x TConstruct.Bolt ,  47 x Natura.Imp ,  1 x WitherBoss ,  7 x Thaumcraft.AspectOrb ,  17 x witchery.goblin ,  18 x XPOrb ,  9 x Cow ,  1 x Thaumcraft.Golem ,  3 x Forestry.butterflyGE ,  13 x Chicken ,  70307 x WitherSkull ,  3 x Natura.FlameSpider ,  42 x Sheep ,  28 x PigZombie ,  19 x Pig ,  1 x DraconicEvolution.CustomArrow ,  1 x Bat ,  1 x Witch ,  4 x null )
commented

The problem is not that method, the problem is that somehow you have 70k holograms. The method just happens to be the most expensive call for hologram entities.

You probably have a plugin constantly spawning holograms through Holographic Displays.

commented

I dont have any other hologram plugins, or plugins that uses Holograms.

commented

I'm pretty sure you do, I should probably add a command to check what plugin is responsible for that. However, can you check if the count is zero when the server starts and gradually increases?

commented

The could is high even on startup. I deleted the database file and it works now, but eventually increases the holograms anyway.

commented

What was the content of that file? Were there 70k holograms?

commented

Nope. My guess is that, in some loop, holograms were re and re-created. The file was right with the right holograms, after removing it, I guess the "duplicated" holograms weren't created again, not sure...

commented

The commit will not fix the issue, you have to search the cause of the 70k holograms that were spawned.

commented

And how can I do it? I see nothing pointing to things other than the lag caused by the holograms...

commented

You can:

  • check if any of your plugins uses holograms (maybe it's not mentioned in the documentation, try opening plugin.yml inside the jar file and search for HolographicDisplays)
  • remove other plugins until the issue is resolved, but since you told it only happened once you wouldn't be able to tell if it's resolved or not
commented

I have only a few plugins, and they don't use Holograms at all, and the issue will randomly happen, only once the Holograms (entities) started with the server. Most times they will gradually increase as long as the server is running. An restart fixes the problem, but sometimes we can't restart the server 4+ times per day, players will get mad...

commented

It must be one of those plugins, it's not a common problem (in fact, it's the first time I hear it). Try on a test server with only Holographic Displays, and then gradually add all the other plugins until the issue appears.

commented

I'm closing this issue, since I'm not able to reproduce it. The plugin doesn't randomly create holograms. Also, I've improved the performance of that method by ~8 times.

commented

When did you?

commented

Sorry, I forgot to link the commit: 20acd2f I did a quick benchmark before and after the change.

commented

Hmm, hope it will fix my issue ๐Ÿ˜ƒ