MyEssentials / MyTown2

Version 2 of MyTown - A Minecraft Server Protection Mod
The Unlicense
35 stars 22 forks source link

Permission Check Load #460

Open cjm721 opened 8 years ago

cjm721 commented 8 years ago

Using the bukkit permission config.

Does "mytown.bypass.flag.enter" need to be checked every tick while a person is inside a town even when not moving?

MuresanSergiu commented 8 years ago

Probably not. I'll see what I can do. Does it cause a lot of lag?

cjm721 commented 8 years ago

Currently no, but I do know from experience if you have to many requests hitting a permissions plugin and that causes another highly used node to be pushed out you are going to cause a lot of reads while that plugin is trying to find out if user has that permission which will cause the server to wait on that tick till complete. The chance of this happening are entirely based on the permission plugin you are using. Some will make sure that neither exit cache but there are other smaller plugins that do not have as good caching systems/functions.

Since this permission is also for a bypass most users will not have it. This means for any permissions plugin which supports wild card you will be adding 4 nodes to most users and 1-3 users for people who do have that permission.

Also there are permission plugins that reset their cache every so often in case of a back-end update and on that tick is going to cause a lot of reads.