Skip to content
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

feat(api,proxy): Add events for server registration/un-registration #1050

Open
wants to merge 5 commits into
base: dev/3.0.0
Choose a base branch
from

Conversation

254nm
Copy link

@254nm 254nm commented Aug 1, 2023

These events are useful in the case of running velocity inside a k3s cluster.

These events are useful in the case of running velocity inside a k3s cluster.
import com.velocitypowered.api.proxy.server.ServerInfo;

/**
* This event is fired by the proxy after a new backend server is registered
Copy link
Sponsor Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should probably explain a bit more of what "registered" means

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

"registered" means adding a new backend server to the proxy dynamically at runtime.

Will this do?

Copy link
Sponsor Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe add a

@see ProxyServer.html#registerServer(com.velocitypowered.api.proxy.server.ServerInfo)

obviously format it right for the javadoc

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will do

import com.velocitypowered.api.proxy.server.ServerInfo;

/**
* This event is fired by the proxy before a backend server is unregistered
Copy link
Sponsor Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ditto

/**
* This event is fired by the proxy before a backend server is unregistered
*/
public class ServerUnRegisteredEvent {
Copy link
Sponsor Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not a fan of this name personally, specifically the "UnRegistered" part

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you have any suggestions for what the name should be?

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.

None yet

4 participants