PluginCatcher

Note: This plugin is not a magic solution to problems.

PluginCatcher

PluginCatcher is a development tool for detecting potential plugin-based causes of server crashes. It is a complex plugin which will cause a slight performance hit on your server while it is active, in order to detect risky behavior by plugins. Currently it primarily detects situations that can lead to ConcurrentModificationException. It is important to note that this plugin cannot detect all scenarios leading to such crashes, but can certainly catch a large number.

Server Owners

Unless you know exactly what this does and why you're here, turn around now. Or contact mbaxter with your crash reports and he'll tell you if this will work.

Developers

Hey, you! Want to detect potential causes of CMEs in your plugins? Awesome! Let's get to work

What can cause CMEs?

The Minecraft server handles nearly all functionality on one thread, what we'll call the main thread. As such, most of its methods (and through that, most Bukkit API) are not designed to handle calls from other threads. Asynchronous calls made while the server is iterating or otherwise interacting with internal Collections which are not thread-safe have the potential to cause a CME. A big place where this comes up is plugin developers calling Bukkit API methods from the AsyncPlayerChatEvent.

Commands

There aren't any! Hah!

Permissions

None! Gotcha!

Configuration

There is one important config value, called onlydangerous. By default true, this setting determines what types of issues are reported. The default setting will only report potential server-killing CME causers. If you set it to false, it will do that plus detect other potentially bad async calls that could cause other issues on your own async thread.

The other config value is meow. If true, cat!

Data Output Location

The plugin outputs all of this info to its plugin folder in a file named async.log. It will log one line to console when it detects issues and logs them. If it stays empty, there hasn't been a potential problem yet. Nice work!

What does it output?

PluginCatcher attempts to figure out what plugin made the risky call by checking the stacktrace lines against plugins' loaded classes. If it finds a match (or matches) it records that plugin and version to the log. Otherwise it reports it as unknown source. Plugin guessing is presented purely for convenience. Never assume a listed plugin is the definite source.

Next, it prints the stacktrace, so you can see what plugin made the call, where it was made, etc. This is where you fix your code to not make that call async.

Facts

Date created
Mar 16, 2013
Category
Last update
May 11, 2014
Development stage
Release
License
Apache License version 2.0
Curse link
PluginCatcher
Downloads
4,179
Recent files
  • R: v1.7.9 for CB 1.7.9-R0.1 May 11, 2014
  • R: v1.7.5 for CB 1.7.2-R0.3 Apr 06, 2014
  • R: v1.7.1 for CB 1.7.2-R0.2 Jan 19, 2014
  • R: v1.7.0 for CB 1.7.2-R0.2 Dec 21, 2013
  • R: v1.6.4 for CB 1.6.4-R1.0 Sep 28, 2013

Authors