Holographic Displays

Holographic Displays

3M Downloads

HolographicDisplays lags

BestMark opened this issue ยท 16 comments

commented

Hello,

Recently, with the increase of online on my server, the TPS dropped heavily, and server began to freeze every minute (average online 240-270).
So, I did the JFR and I saw that the reason of the lags is HolographicDisplays.
2018-08-22 15 04 13
Also I use Paper 1.12.2 (latest build)

Please, fix it as soon as possible, because I can't find a replacement for your wonderful plugin.

commented

That function is called frequently, but it shouldn't cause lag. I don't know much about that tool, but you should look at timings, rather than call counts, it probably takes just a few nanoseconds to execute.

Is there any other plugin creating lots of holograms?

Are you using Java 9+? I will improve that part of code for Java 9+ soon.

Side note, I need to add an option to disable this overhead: the reason I added it was to align holograms lines precisely, when teleported frequently. But if they aren't teleported frequently (like a chat bubble over a player's head) it's not needed.

commented

@filoghost the issue is reflection, it is super slow in this scenario.

commented

Thank you for your answer.

Is there any other plugin creating lots of holograms?

No, I have only one plugin that uses HolographicDisplays (it's code), but it doesn't create a lot of holograms.
But there is one more plugin that creates a lot of holograms (chat bubble over a player's head) and it exactly uses own API, not HolographicDisplays.

Are you using Java 9+?

No, I'm using Java 10 only on my computer to view JFR. On my Linux server, where located Minecraft servers, I use JDK 8u181.

Tomorrow I will do timings and send here.

commented

Is the issue in my plugins? Chat Bubbles or the first plugin, which code I sent?

commented

no the issue happens on java 9+ only, use java 8 as an hotfix.

commented

As I said, I use Java 8. Issue happens on Java 8 server.

commented

uh sorry misread your post

commented

OK, I hope author will fix this bug. I think it's important for many servers using this plugin.
As a workaround for me, I created another Paper server, because one server can't withstand such a load.

commented

Ok, I will try

commented

Hello,
Should I wait for the fix? On my server it is impossible to play (4 TPS) because of the load from your plugin.

commented

@BestMark it has been fixed, please try again with the latest dev build

commented

As I already said, problem resolves when I delete HolographicDisplays. Timings are useless in this case.

commented

If you need, I can send you JFR file with your plugin and without it.

commented

@sgdc3, update didn't help to resolve this lags.
2018-08-31 13 10 20
When I installed HolographicDisplays, server became to freeze every 15-20 seconds.

commented

Please get the timings instead of method calls count. Also try removing the plugin to see if the lag goes away.

The freeze is odd, because that method is called frequently, and the server should lag constantly if that is the cause (instead of just freezing every 15-20 seconds).

commented

A new build is out, with the option to disable this part of code that may be slowing your server. Please try it, a new config.yml node will appear: "precise-hologram-teleport" (set it to false)