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

Refactor: Move original ServiceStatus interface methods to a new interface #575

Open
Tracked by #147
AlfredoG87 opened this issue Feb 4, 2025 · 0 comments
Open
Tracked by #147
Labels
Block Node Issues/PR related to the Block Node.

Comments

@AlfredoG87
Copy link
Contributor

AlfredoG87 commented Feb 4, 2025

Problem

ServiceStatus was originally created to support internal status of the web server, now is being used to also communicate system BN data within different parts of the system, potentially in the future growing some more when the ServerStatus API gets implemented. api.

Solution

We should create a new interface (perhaps called WebServerStatus) with an implementation class to house the original methods specific to the health of the webserver itself:

    boolean isRunning();
    void stopRunning(final String className);
    void setWebServer(@NonNull final WebServer webServer);
    void stopWebServer(final String className);
  • This core set of methods will always be available in the server
  • The ServerStatus API may not be something that's available on start up based on how the container image is built
  • Strongly consider migrating the ServerStatus API interfaces and implementation classes into their own package as a first step toward modularity

Alternatives

No response

@mattp-swirldslabs mattp-swirldslabs added the Block Node Issues/PR related to the Block Node. label Feb 4, 2025
@mattp-swirldslabs mattp-swirldslabs changed the title Split ServiceStatus interface in 2 Refactor: Split ServiceStatus interface in 2 Feb 4, 2025
@mattp-swirldslabs mattp-swirldslabs changed the title Refactor: Split ServiceStatus interface in 2 Refactor: Move original ServiceStatus interface methods to a new interface Feb 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Block Node Issues/PR related to the Block Node.
Projects
None yet
Development

No branches or pull requests

2 participants