summaryrefslogtreecommitdiffstats
path: root/application
diff options
context:
space:
mode:
authorBjørn Christian Seime <bjorncs@vespa.ai>2023-11-17 16:53:36 +0100
committerBjørn Christian Seime <bjorncs@vespa.ai>2023-11-17 16:53:36 +0100
commit2b9917fe639f2bd27fecf3fd4a7d6b0ca0d3382b (patch)
tree17ddf9f6febbf9354d023a68eeb74123e6c523f6 /application
parent3031e5a425e54cb7a4754a8a47c7a4a9508b1f5c (diff)
Add getter for request handler registry
Diffstat (limited to 'application')
-rw-r--r--application/abi-spec.json1
-rw-r--r--application/src/main/java/com/yahoo/application/container/JDisc.java3
2 files changed, 4 insertions, 0 deletions
diff --git a/application/abi-spec.json b/application/abi-spec.json
index 95a9d2a524a..efc362766d0 100644
--- a/application/abi-spec.json
+++ b/application/abi-spec.json
@@ -324,6 +324,7 @@
"public com.yahoo.application.container.Processing processing()",
"public com.yahoo.application.container.DocumentProcessing documentProcessing()",
"public com.yahoo.component.provider.ComponentRegistry components()",
+ "public com.yahoo.component.provider.ComponentRegistry handlers()",
"public com.yahoo.application.container.handler.Response handleRequest(com.yahoo.application.container.handler.Request)",
"public void close()"
],
diff --git a/application/src/main/java/com/yahoo/application/container/JDisc.java b/application/src/main/java/com/yahoo/application/container/JDisc.java
index 162a5f343a1..3223c8d31c9 100644
--- a/application/src/main/java/com/yahoo/application/container/JDisc.java
+++ b/application/src/main/java/com/yahoo/application/container/JDisc.java
@@ -169,6 +169,9 @@ public final class JDisc implements AutoCloseable {
return container.getComponentRegistry();
}
+ /** @return registry of all request handlers configured */
+ public ComponentRegistry<RequestHandler> handlers() { return container.getRequestHandlerRegistry(); }
+
/**
* Handles the given {@link com.yahoo.application.container.handler.Request} by passing it to the {@link RequestHandler}
* that is bound to the request's URI.