-
-
Notifications
You must be signed in to change notification settings - Fork 2.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Paper Plugins, Bootstrappers, Loaders and More? #8108
Conversation
Although I like the library loading feature, I've heard it's against Maven Central's TOS. I believe Paper should adhere to that in order to avoid potential issues down the line. It's also important to factor in that lots of servers are floating around, hopefully they aren't already putting too much strain on Central. For now, I am quite certain only a small amount of plugins use library-loading, so the damage shouldn't be too bad, I assume. |
the library loader is fine, bar the fact that it's pointed directly to central, ideally what we do is just flip it over to our own repo at some point, just some pending stuff in the works, etc |
While I'm fully aware of how non-trivial it is, having checks on all the adventure-deprecated methods ( |
Looks awesome Owen! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A first quick glance, i can't really help you with configurate
test-plugin/src/main/java/io/papermc/paper/testplugin/PreTestPlugin.java
Outdated
Show resolved
Hide resolved
Plugin Loaders public class TestPluginLoader implements PluginLoader {
@Override
public void classloader(PluginClasspathBuilder classpathBuilder) {
classpathBuilder.addLibrary(new JarLibrary(Path.of("bob.jar")));
MavenLibraryResolver resolver = new MavenLibraryResolver();
resolver.addDependency(new Dependency(new DefaultArtifact("com.owen1212055:particlehelper:1.0.0-SNAPSHOT"), null));
resolver.addRepository(new RemoteRepository.Builder("bytecode", "default", "https://repo.bytecode.space/repository/maven-public/").build());
resolver.setFilter(new DependencyFilter() {
@Override
public boolean accept(DependencyNode node, List<DependencyNode> parents) {
return true;
}
});
classpathBuilder.addLibrary(resolver);
}
} Plugin loaders allow you to configure certain things about your plugin before it is created at all. In this case, a new robust way of adding libraries to your plugin! This allows you to add jars/dependencies before your plugin is created, making it a bit nicer for plugins that may require a lot of complex library logic. Plugin Initializers have also been renamed to PluginBootstrappers.
|
I don't think linking to our own site like this is "advertising". We can choose to link Hanagar or not, personally I think it's a good idea, but a config option for this seems like totally unnecessary bloat. |
I would definitely say that promoting another product/service (no matter how strongly related to the manufacturer) is advertisement. |
In the literal sense sure, hence the quotes in my comment, but using that word to describe this is somewhat disingenuous in my opinion and implies unfair comparisons. You could also argue /ver is advertising our downloads site. Additionally there is the precedent of Bukkit, Spigot, and Paper linking to their various sites such as forums, discord, irc, etc. in their config files. |
I think in the config files makes sense, or maybe if there's 0 plugins installed, but, otherwise, chat is a limited space and it just feels like extra pointless fluff which should be on the "getting started" guide |
It's a hover text, not a chat message, which I would agree would be too much. Again I don't feel super strongly for or against linking Hangar here, just pointing out the "advertising" point is not really relevant to that decision in my mind. |
I've implemented dependency loading, would appreciate if anyone would like to look over that. There are now two "plugin loaders", legacy and modern. Modern plugin loading (default) does not allow infinite dependency loops, as this caused issues in the past. If infinite dependency loops are detected the servers shuts down. Optionally, this can be switched by using the LEGACY plugin loader in paper global config (misc.plugin-loading-strategy) Please feel free to test if plugins correctly load in order. |
The test plugin has been relocated to This can be reverted, but currently applies for:
|
I'm going to mark this as ready for review, most of the larger requirements have been resolved. The api support has been finished, and PluginLoader has been deprecated. |
I like the improved plugin thing, tho it feels a bit much... Maybe keep it closer to the original but like this?
Then have hover text displaying plugin info and what plugin type it is. Just an idea tho. Also regarding the yaml file: Example I had imagined: 2022-08-05.17-55-03.mp4 |
@Owen1212055 Congratulations! I hope you will continue to drive this project onward! 🥳 |
This seems to break the async chat listener priorities, I got multiple reports regarding this such as kangarko/ChatControl-Red#2306 |
Priorities have 0 bearing on this system outside of plugins load order,
that would generally suggest that plugins which are fragile to the load
order are in the mix, which is one of those long term bukkit issues
…On Thu, 9 Mar 2023, 10:14 Matej Pacan, ***@***.***> wrote:
This seems to break the async chat listener priorities, I got multiple
reports regarding this such as kangarko/ChatControl-Red#2306
<kangarko/ChatControl-Red#2306>
—
Reply to this email directly, view it on GitHub
<#8108 (comment)>, or
unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAJMAZGX4JC32AGLYCMW4LTW3GURZANCNFSM5232E54Q>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
"Schematic versioning" is not a real thing. The intended versioning scheme is "semantic versioning". Introduced in PaperMC#8108.
"Schematic versioning" is not a real thing. The intended versioning scheme is "semantic versioning". Introduced in #8108.
"Schematic versioning" is not a real thing. The intended versioning scheme is "semantic versioning". Introduced in PaperMC#8108.
This implements paper plugins, which can be created by
paper-plugin.yml
in your plugin resources.At runtime, they are all in the end the same "JavaPlugins". However, in the future, it is possible that this can be expanded.
Note: You can have both paper plugin and spigot plugin ymls and paper will prioritize the paper yml. The goal is to also have paper and spigot plugins work fine together (because again, they are the same at run time).
This was opened to collect a lot of feedback
Difference between paper plugins:
bootstrapper
field, allowing code to be executed even before a Minecraft server is created!Resolves:
#5992
#7961
#7955
Final testing process
Hoping to target this release to allow for future API to move forward. Please test this on your servers to ensure that all spigot plugins work.
Paper plugins will be experimental.
Download the paperclip jar for this pull request: paper-8108.zip