Performance hit with WorldGuard.
LadyCailinBot opened this issue ยท 8 comments
WORLDGUARD-3039 - Reported by rtcabooservb
WorldGuard 5.9.1 (dev build 1296) seems to be affecting performance a bit on 1.7.9.
Timings:
http://aikar.co/timings.php?url=7280176%2F
Config:
http://paste.ubuntu.com/7280196/
Is there any way to improve the WorldGuard PlayerJoinEvent performance impact?
Comment by wizjany
it's probably due to UUID lookups since we haven't migrated yet. you can either deal with it for now or downgrade bukkit.
edit: it's still extremely small by the looks of your timings though, not sure why you think it's a huge performance hit...and it only will happen when a lookup needs to be performed, which was only a few hundred times over the course of >20 minutes
Comment by Phoenix_IV
[http://forums.bukkit.org/threads/psa-the-switch-to-uuids-potential-plugin-server-breakage.250915/ EvilSeph said:]
'''Our Current Migration Plan, for reference:'''
Minecraft 1.7.6+
UUID lookup will become the most efficient lookup method: check if UUID matches stored player data on disk
Name lookup will then become the least efficient lookup method
Lookups by name will be pretty inefficient for 1.7.9
So the problem here would be that WG is '''not''' using UUID lookups (aka a reverse lookup is triggered when getting a player by name). @sk
Comment by wizjany
not so much just name lookup, which is cached, but first login name lookup, which requires the server to ask mojang for the translation.
this is just a theory though, i haven't actually looked at the code
Comment by Phoenix_IV
Lookup was changed in CraftBukkit 1.7.8 - [https://github.com/Bukkit/CraftBukkit/commit/3762cc269480697083ad9f6bbed99a0551f17979#diff-404511debe6c1c161a52e57263e17b64L1260 See change on GitHub]
Ticket depends on WORLDGUARD-3030.
The problem should vanish with an UUID update and cannot be resolved separately.
Comment by sk89q
Lookups for names is inefficient if ''the player isn't logged in'', but AFAIK, WorldGuard does zero name lookup because most of WG's code predates OfflinePlayer, so I'm not sure why it would be blocking the server.
I presume that a name is available by PlayerJoinEvent because the server will have needed to authenticate the player and get their name.
Comment by Dark_Arc
My best guess would be the 2 group lookups performed there.