promotional bannermobile promotional banner

PluginCatcher

Developer tool for catching mistakes

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.

The PluginCatcher Team

profile avatar
  • 18
    Projects
  • 3.0M
    Downloads

More from m_baxterView all

  • EssentialsX project image

    EssentialsX

    • 2.4M
    • Bukkit Plugins

    The modern Essentials suite for Spigot and Paper.

    • 2.4M
    • May 31, 2026
    • Bukkit Plugins
    • +4
  • Vanish No Packet project image

    Vanish No Packet

    • 910.8K
    • Bukkit Plugins

    Hide from your players! Invisibility for the distinguished gentleman.

    • 910.8K
    • February 24, 2022
    • Bukkit Plugins
    • +2
  • Chester project image

    Chester

    • 14.9K
    • Bukkit Plugins

    Logs all messages, and when Chester is mentioned, he replies with a logged message.

    • 14.9K
    • September 19, 2016
    • Bukkit Plugins
  • CraftIRC project image

    CraftIRC

    • 46.3K
    • Bukkit Plugins

    IRC for Minecraft!

    • 46.3K
    • March 2, 2016
    • Bukkit Plugins
    • +2
  • EssentialsX project image

    EssentialsX

    • 2.4M
    • Bukkit Plugins

    The modern Essentials suite for Spigot and Paper.

    • 2.4M
    • May 31, 2026
    • Bukkit Plugins
    • +4
  • Vanish No Packet project image

    Vanish No Packet

    • 910.8K
    • Bukkit Plugins

    Hide from your players! Invisibility for the distinguished gentleman.

    • 910.8K
    • February 24, 2022
    • Bukkit Plugins
    • +2
  • Chester project image

    Chester

    • 14.9K
    • Bukkit Plugins

    Logs all messages, and when Chester is mentioned, he replies with a logged message.

    • 14.9K
    • September 19, 2016
    • Bukkit Plugins
  • CraftIRC project image

    CraftIRC

    • 46.3K
    • Bukkit Plugins

    IRC for Minecraft!

    • 46.3K
    • March 2, 2016
    • Bukkit Plugins
    • +2