RFC Title
To be Reviewed By:
Authors: Dale Emery (demery@pivotal.io)
Status: Draft
Superseded by: N/A
Related: N/A
Problem
Geode currently does not offer a public way to add endpoints to its HTTP server. A developer wishing to serve additional HTTP content must either use internal Geode APIs to add to Geode's server or create a separate server.
For example, Geode collects metrics in a meter registry, but does not publish them. A developer may wish to publish those metrics via HTTP, using a PrometheusMeterRegistry or similar.
Solution
Give HttpService a public interface for adding endpoints, and make the instance publicly accessible.
Changes and Additions to Public Interfaces
Create a public interface with methods like:
- addHandler(String endpointContext, Handler endpointHandler) to add a simple Jetty handler to the server.
- addWebApp(String appContext, Path warFilePath) to add a war-based servlet.
Let HttpService implement this public interface to add the specified endpoints to its Jetty Server.
Make that object available via a new or existing public interface.
Performance Impact
Do you anticipate the proposed changes to impact performance in any way? Are there plans to measure and/or mitigate the impact?
Backwards Compatibility and Upgrade Path
Will the regular rolling upgrade process work with these changes?
How do the proposed changes impact backwards-compatibility? Are message or file formats changing?
Is there a need for a deprecation process to provide an upgrade path to users who will need to adjust their applications?
Prior Art
What would be the alternatives to the proposed solution? What would happen if we don’t solve the problem? Why should this proposal be preferred?
FAQ
Answers to questions you’ve commonly been asked after requesting comments for this proposal.
Errata
What are minor adjustments that had to be made to the proposal since it was approved?