LagPlugin
Yes, it works with 1.8!
Description
The LagPlugin is a simple plugin that allows you to monitor your servers memory consumption (Only of the Memory available to Java) quickly and efficently, using Java's built in Runtime class. Typing in /lag will show you a comprehendable two percentages, one of the free memory, one of the used memory. If you notice that your server is lagging a bit, then quickly type in /gc, and using Java's default garbage collector, your servers memory consumption will decrease. As an added bonus in V1.6, items will be removed from your server if they are "alive" for more than the preconfigured time alotted in your configuration file (This is toggleable)(Only in V1.6B). If your servers memory consumption reaches greater than 85%, a warning is sent out to all OP's that the server may need a cleanup. This plugin is designed to be efficent, and simple to use for server's with low memory or servers attempting to keep that Vanilla Minecraft feel. As of 1.2 BETA, DMM (Dynamic Memory Management) has been added in, and is toggleable through a new configuration file! PS: If updating from V1.4 to V1.5 or higher, please DELETE your config, and allow the plugin to regenerate its configuration files.
Commands
- /lag: Shows the Lag Consumption in an easy to understand percentage
- /gc: Runs Java's Garbage Cleanup services to free up some memory
Arguments
- /lag dynamic: Toggle DMM (Dynamic Memory Management) in game (V1.3)
- /lag lightning: Toggle anti-lightning (V1.5)
Permissions
- /lag: lag.lag
- /gc: lag.gc
Videos
MerijnRaaij made this video! Check it out!
Images
/lag:
/gc:
Configuration
Suggestions
Put your mark on LagPlugin! Please help me with some feature suggestions! Go to the forums and reply to this thread!
中国人路过..
@deleted_9991157
Thank you for your compliments Braytography, and I agree with you 100%, which is why the newer versions of LagPlugin include an easy to use configuration file, simply turn off the unwanted services. I do recommend usage of a newer version of LagPlugin, simply for stability, and compatibility. In newer versions the code is cleaner too, and as for new features the only planned one I have is a verbose output option for debugging. Thank you for your input, and I hope you take using a newer version of LagPlugin into consideration, please just ask if you have any other questions!
@thequestingbeast
Thank you for all of your support and suggestions. Honestly I just haven't actually implemented the permissions yet, I guess I just forgot to. Should be a quick and easy fix, Ill have it out in my next Beta, or even Release if all goes well.
EDIT: Same goes with the information readout.
@Einstein12345
Personally I think you are doing an awesome job and I wouldn't really worry about the two config items as long as they are explained well (and you have.)
Also, thank you for taking care of the console spam, I knew it was probably just an accident.
Some other suggestions, since I have been working with your plugin a bit, and being an obsessive lag hater. ~ Ticks Per Sec ~ Actual amount of Memory Used and Available, not just percentages ~ perm node so staff and use command without being op
These are only suggestions as your plugin is a wonderful addition as it is.
@thequestingbeast
The tracking of individual items shouldnt hurt more than it helps, based on the time set in clearitemsinterval:# This value specifies the amount of time before LagPlugin runs its check, and sees the length of time something has been dropped in the world. Basically to tell it to wipe any items that have been dropped for 1 minute, from the time they were dropped, setting the clearitemsinterval value to 1 means LagPlugin will check the value that represents the length that object has been "alive" or dropped for, and compare it to the value of clearitemsduration. clearitemsduration is the amount of time (Estimate) that the object is allowed to stay "alive", or be dropped for. The value of clearitemsinterval will determine whether or not this feature will hurt the servers lag. It's based upon a Timer. This Tiimer uses the value of clearitemsinterval*60000 (To make it into minutes) for its own interval. The Timer then runs a certain block of code, in this case the block of code to check how long each item in the world has been there for, and delete objects as necessary. The clearitemsduration value is an estimate due to the random time that a User may drop an item. If the LagPlugin is told to check (cleariteminterval) every 30 minutes, and the object is dropped 15 minutes before the check, then the object will not be considered to have been alive for the specified time. This means the object will not be deleted until the next check, where it will have been alive for 45 minutes. This is a bug I am currently working on, as of yet I'm not sure how to fix this, but trust me im doing my best. Thank you for all your help, you really have helped, and any other suggestions or concerns you have, please just ask.
EDIT: I fixed the console spam in a newly uploaded file. Sorry about that! I had it like that for testing purposes for me.
@morrango
My world is big enough that people pass in and out and don't hang around long enough to despawn things.
@Einstein12345
I am still learning what causes and how to deal with lagg, but wouldn't that constant tracking of individual items hurt more than help? I was thinking a wipe so every half hour or something configurable the whole world would be wiped.
Its very console spammy since it lets it know everytime something is dropped... all dem chicken eggs.
I have downloaded and looked at the config of the 1.6B. I don't understand what each of these do exactly:
clearitemsduration:1 clearitemsinterval:1
Now I would assume that duration is the length of time that the clock runs before the item disappears, but what does interval do? Or am I mistaken entirely?
Thank you for your hard work in making my server better. It means a lot to have someone care.
@thequestingbeast
Thank you for your suggestion, I do take suggestions, and would ask that any would openly posted. I was thinking of this in my next update, but with a little tweak. I was thinking I could try monitoring when the item was dropped, and using a configurable time amount, delete that item when the time is up. So if someone dropped an Item, say one minute later that item would be deleted. Any other comments on this idea will be appreciated, I need some good information and feedback on the plugin so I can further help my clients lag problems.
@thequestingbeast
This could be done every time a chunk unloads.
I am unsure if you are up for suggestions, but if you are, here is one. I would love to see attached to this a way to wipe... scheduled or not... floating entities in the whole world at once. Not animals or mobs. Just the dropped items that players leave floating.
@Einstein12345
yay thx
@MerijnRaaij
Thank you very much! I'm adding it to the description right now!
@Einstein12345
here is the link http://youtu.be/12cw0LXzXUw
@MerijnRaaij
Thanks, ill check it then!
@Einstein12345
yes it is online tomarrow on 4 hour pm dutch time.
Channal: www.youtube.com/diamondcookieyt
@MerijnRaaij Thank you MerijnRaaij for the support! Can you post a link to the video so I can use it on the page?
I am going to make a video of your plugin it is soo simple but very effective and essential on a good server
Awesome plugin. +1