Conversation
|
Before marking this as ready for review I wanted to discuss the 3 topics mentioned in the tasks list, so any discussion regarding these would be greatly appreciated. |
|
i believe an empty string would be the best way to go about disabling it, same as it is done in other softwares |
I completely agree, that's what my head initially went to. Wasn't sure if there was a different practice in toml as I've not worked with it before :) I'll adjust that one |
|
I also noticed that in most places in the config object it seems like the nullable annotation is not used so I'll remove it unless suggested otherwise for |
technically the name is not nullable, as it is an empty string (and should be checked against being empty, not null) in the |
That's true, currently it was requiring being set to null to disable it, I'll make these changes now. I am also going to opt for |
proxy/src/main/java/com/velocitypowered/proxy/plugin/VelocityPluginManager.java
Show resolved
Hide resolved
proxy/src/main/java/com/velocitypowered/proxy/plugin/VelocityPluginManager.java
Outdated
Show resolved
Hide resolved
proxy/src/main/java/com/velocitypowered/proxy/config/VelocityConfiguration.java
Show resolved
Hide resolved
proxy/src/main/java/com/velocitypowered/proxy/config/VelocityConfiguration.java
Show resolved
Hide resolved
proxy/src/main/java/com/velocitypowered/proxy/plugin/VelocityPluginManager.java
Outdated
Show resolved
Hide resolved
|
I think Velocity's update folder should mirror the Paper update folder's name (update without a dot prefix). |
The dot prefix acts as a way of keeping the folder at the top of the directory list and separates it from being mixed in with the plugin folders. I personally think it makes the update folder much more accessible and easy to use, which is why I set it as the default. I would go as far to say that Paper could also benefit from changing the default to include the prefix.
I personally think a config option is nice to have for people who prefer different formats or languages. It could use a system properpty but I don't really think this being a config option has any drawbacks
I am happy to change this if needed |
That makes sense, thank you for explaining.
I don't get how different languages/formats matter here. For the average admin it is that folder and the folder being standardized also simplifies debugging for other people.
Ofc it is not needed, IMO it's better to use the NOI though, as that is the more modern and cleaner solution. |
That's fair and very true. I guess it's almost like if Paper added a config option for
Was just having a look through the changes in this PR and the only places I am using |
|
Well IMO we don't need to disable the update folder if we just don't auto create it, no? |
I based the need to disable off of this discussion in the other pr regarding this topic |
Well then I think we might want a config section to disable it for individual plugins, but it also more seems like something for plugin authors to handle. If they are truly malicious they can do anything and if not then users should either raise an issue or search for an alternative. Also this should only become an issue after this feature is introduced, no? |
In that case, I think sticking to just an empty string to disable is probably suitable enough as it doesn't require any extra options. |
The goal of this PR was to make progress on a plugin update folder for Velocity.
Tasks:
VelocityConfiguration#getUpdateFolderNamecloses #809
based on #842