Package org.forgerock.openig.http
Class BaseAdminHttpApplication
java.lang.Object
org.forgerock.openig.http.BaseAdminHttpApplication
- All Implemented Interfaces:
DescribedHttpApplication
,HttpApplication
,AdminHttpApplication
Configuration class for the Identity Gateway Administration.
-
Constructor Summary
ConstructorDescriptionBaseAdminHttpApplication
(String adminPrefix, JsonValue config, Environment environment, RunMode mode, boolean serveDeprecatedPrometheusEndpoint, org.forgerock.config.resolvers.PropertyResolver propertyResolver, org.forgerock.monitoring.api.instrument.MeterRegistry meterRegistry, StartupMetrics parentStartupMetrics, HttpClientProvider httpClientProvider, WebSocketClientProvider webSocketClientProvider, Clock clock, IgTicker ticker, AsyncSessionManager sessionManager, ProductInfo productInfo) Construct aBaseAdminHttpApplication
. -
Method Summary
Modifier and TypeMethodDescriptionNeeded to enforce generation of CREST APIs.Returns the API endpoint registry.getHeap()
Returns the heap based on the contents of the admin configuration.Returns the router that represents the /openig namespace (or whatever path/prefix value that was configured).start()
Gets the rootHandler
that will handle all HTTP requests.void
stop()
Called when HTTP application is shutdown.
-
Constructor Details
-
BaseAdminHttpApplication
public BaseAdminHttpApplication(String adminPrefix, JsonValue config, Environment environment, RunMode mode, boolean serveDeprecatedPrometheusEndpoint, org.forgerock.config.resolvers.PropertyResolver propertyResolver, org.forgerock.monitoring.api.instrument.MeterRegistry meterRegistry, StartupMetrics parentStartupMetrics, HttpClientProvider httpClientProvider, WebSocketClientProvider webSocketClientProvider, Clock clock, IgTicker ticker, AsyncSessionManager sessionManager, ProductInfo productInfo) throws IOException, HttpApplicationException Construct aBaseAdminHttpApplication
.- Parameters:
adminPrefix
- the prefix to use in the URL to access the admin endpointsconfig
- the admin configurationenvironment
- the IG environmentmode
- IG run modeserveDeprecatedPrometheusEndpoint
- set totrue
to enable the deprecated Prometheus endpointpropertyResolver
- root property resolvermeterRegistry
- the meter registryparentStartupMetrics
- the parentStartupMetrics
httpClientProvider
- The provider of HttpClientwebSocketClientProvider
- The WebSocket Client Providerclock
- The clock to useticker
- The ticker to usesessionManager
- The session manager to useproductInfo
- The product information- Throws:
IOException
- when initialization failedHttpApplicationException
- when initialization failed
-
-
Method Details
-
start
Description copied from interface:HttpApplication
Gets the rootHandler
that will handle all HTTP requests.The
Handler
returned from this method MUST be a singleton.- Specified by:
start
in interfaceHttpApplication
- Returns:
- The
Handler
to handle HTTP requests. - Throws:
HttpApplicationException
- If there is a problem constructing the root applicationHandler
.
-
getBufferFactory
Description copied from interface:HttpApplication
Gets theFactory
that will create temporary storageBuffer
s to handle the processing of requests.May return
null
indicating that the container should provide a default buffer factory.- Specified by:
getBufferFactory
in interfaceHttpApplication
- Returns:
- A
Buffer
Factory
ornull
.
-
stop
public void stop()Description copied from interface:HttpApplication
Called when HTTP application is shutdown.Implementation should use this method to clear up all remaining resources.
- Specified by:
stop
in interfaceHttpApplication
-
getEndpointRegistry
Description copied from interface:AdminHttpApplication
Returns the API endpoint registry.- Specified by:
getEndpointRegistry
in interfaceAdminHttpApplication
- Returns:
- the API endpoint registry
-
getOpenIGRouter
Description copied from interface:AdminHttpApplication
Returns the router that represents the /openig namespace (or whatever path/prefix value that was configured).- Specified by:
getOpenIGRouter
in interfaceAdminHttpApplication
- Returns:
- the router that represents the /openig namespace
-
getHeap
Description copied from interface:AdminHttpApplication
Returns the heap based on the contents of the admin configuration.- Specified by:
getHeap
in interfaceAdminHttpApplication
- Returns:
- the heap based on the contents of the admin configuration.
-
getApiProducer
Needed to enforce generation of CREST APIs.- Specified by:
getApiProducer
in interfaceDescribedHttpApplication
- Returns:
- a swagger api producer.
-