Skip to content

Conversation

A248
Copy link

@A248 A248 commented Aug 21, 2023

Coming up on the 3-year anniversary of the stale BungeeCord PR SpigotMC/BungeeCord#2945, I decided to re-implement the solutions with some enhancements and PR them to Waterfall instead.

Compared to the old PR, PluginManager's commandMap is now a concurrent map. Synchronization is limited to mutative operations, which supports non-blocking command execution and tab completion. Moreover, using the concurrent map maintains thread safety while allowing us to preserve the longstanding bug in PluginManager whereby plugins can mutate the return value of getCommands. A separate PR could address that bug if desired, but such is outside the scope of this one.

Retrieving plugin instances continues to be synchronized, but only where necessary; by assumption plugins do not load other plugins in onLoad.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant