Package com.arpnetworking.http
Class Routes
java.lang.Object
com.arpnetworking.http.Routes
- All Implemented Interfaces:
Serializable
,org.apache.pekko.japi.Function<org.apache.pekko.http.javadsl.model.HttpRequest,
,CompletionStage<org.apache.pekko.http.javadsl.model.HttpResponse>> org.apache.pekko.japi.function.Function<org.apache.pekko.http.javadsl.model.HttpRequest,
CompletionStage<org.apache.pekko.http.javadsl.model.HttpResponse>>
public final class Routes
extends Object
implements org.apache.pekko.japi.function.Function<org.apache.pekko.http.javadsl.model.HttpRequest,CompletionStage<org.apache.pekko.http.javadsl.model.HttpResponse>>, org.apache.pekko.japi.Function<org.apache.pekko.http.javadsl.model.HttpRequest,CompletionStage<org.apache.pekko.http.javadsl.model.HttpResponse>>
Http server routes.
- Author:
- Ville Koskela (ville dot koskela at inscopemetrics dot io)
- See Also:
-
Constructor Summary
ConstructorDescriptionRoutes
(org.apache.pekko.actor.ActorSystem actorSystem, com.arpnetworking.metrics.incubator.PeriodicMetrics metrics, String healthCheckPath, String statusPath, com.google.common.collect.ImmutableList<SupplementalRoutes> supplementalRoutes) Public constructor. -
Method Summary
Modifier and TypeMethodDescriptionCompletionStage<org.apache.pekko.http.javadsl.model.HttpResponse>
apply
(org.apache.pekko.http.javadsl.model.HttpRequest request)
-
Constructor Details
-
Routes
public Routes(org.apache.pekko.actor.ActorSystem actorSystem, com.arpnetworking.metrics.incubator.PeriodicMetrics metrics, String healthCheckPath, String statusPath, com.google.common.collect.ImmutableList<SupplementalRoutes> supplementalRoutes) Public constructor.- Parameters:
actorSystem
- Instance ofActorSystem
.metrics
- Instance ofPeriodicMetrics
.healthCheckPath
- The path for the health check.statusPath
- The path for the status.supplementalRoutes
- List of supplemental routes in priority order.
-
-
Method Details
-
apply
public CompletionStage<org.apache.pekko.http.javadsl.model.HttpResponse> apply(org.apache.pekko.http.javadsl.model.HttpRequest request) - Specified by:
apply
in interfaceorg.apache.pekko.japi.Function<org.apache.pekko.http.javadsl.model.HttpRequest,
CompletionStage<org.apache.pekko.http.javadsl.model.HttpResponse>> - Specified by:
apply
in interfaceorg.apache.pekko.japi.function.Function<org.apache.pekko.http.javadsl.model.HttpRequest,
CompletionStage<org.apache.pekko.http.javadsl.model.HttpResponse>>
-