Package com.yahoo.processing.handler
Class AbstractProcessingHandler<COMPONENT extends Processor>
java.lang.Object
com.yahoo.jdisc.AbstractResource
com.yahoo.jdisc.handler.AbstractRequestHandler
com.yahoo.container.jdisc.ThreadedRequestHandler
com.yahoo.container.jdisc.ThreadedHttpRequestHandler
com.yahoo.container.jdisc.LoggingRequestHandler
com.yahoo.processing.handler.AbstractProcessingHandler<COMPONENT>
- All Implemented Interfaces:
HttpRequestHandler,RequestHandler,SharedResource
- Direct Known Subclasses:
ProcessingHandler
public abstract class AbstractProcessingHandler<COMPONENT extends Processor>
extends LoggingRequestHandler
Superclass of handlers invoking some kind of processing chain.
COMPONENT: The type of the processing components of which this executes a chain
- Author:
- bratseth, Tony Vaagenes, Steinar Knutsen
-
Nested Class Summary
Nested classes/interfaces inherited from class com.yahoo.container.jdisc.LoggingRequestHandler
LoggingRequestHandler.ContextNested classes/interfaces inherited from class com.yahoo.container.jdisc.ThreadedHttpRequestHandler
ThreadedHttpRequestHandler.LazyContentChannelNested classes/interfaces inherited from interface com.yahoo.jdisc.SharedResource
SharedResource.Debug -
Field Summary
FieldsFields inherited from class com.yahoo.container.jdisc.ThreadedHttpRequestHandler
CONTENT_TYPE, logFields inherited from class com.yahoo.container.jdisc.ThreadedRequestHandler
metric, metricUtilFields inherited from interface com.yahoo.jdisc.SharedResource
DEBUG, SYSTEM_PROPERTY_NAME_DEBUG -
Constructor Summary
ConstructorsConstructorDescriptionAbstractProcessingHandler(ChainsConfig processingChainsConfig, com.yahoo.component.provider.ComponentRegistry<COMPONENT> chainedComponents, com.yahoo.component.provider.ComponentRegistry<Renderer> renderers, Executor executor, AccessLog ignored) AbstractProcessingHandler(ChainsConfig processingChainsConfig, com.yahoo.component.provider.ComponentRegistry<COMPONENT> chainedComponents, com.yahoo.component.provider.ComponentRegistry<Renderer> renderers, Executor executor, AccessLog ignored, Metric metric) AbstractProcessingHandler(ChainRegistry<COMPONENT> chainRegistry, com.yahoo.component.provider.ComponentRegistry<Renderer> renderers, Executor executor, AccessLog ignored) AbstractProcessingHandler(ChainRegistry<COMPONENT> chainRegistry, com.yahoo.component.provider.ComponentRegistry<Renderer> renderers, Executor executor, AccessLog ignored, Metric metric) -
Method Summary
Modifier and TypeMethodDescriptioncreateExecution(Chain<COMPONENT> chain, Request processingRequest) getRendererCopy(com.yahoo.component.ComponentSpecification spec) For internal use onlycom.yahoo.component.provider.ComponentRegistry<Renderer>handle(HttpRequest request) Throws UnsupportedOperationException: Call handle(request, channel instead)handle(HttpRequest request, ContentChannel channel) Override this rather than handle(request) to be able to write to the channel before returning from this method.Methods inherited from class com.yahoo.container.jdisc.LoggingRequestHandler
createLoggingCompletionHandler, testOnlyContextMethods inherited from class com.yahoo.container.jdisc.ThreadedHttpRequestHandler
addDateHeader, asHttpRequest, handleRequest, testContextMethods inherited from class com.yahoo.container.jdisc.ThreadedRequestHandler
executor, getRequestType, getTimeout, handleRequest, writeErrorResponseOnOverloadMethods inherited from class com.yahoo.jdisc.handler.AbstractRequestHandler
handleTimeoutMethods inherited from class com.yahoo.jdisc.AbstractResource
currentState, destroy, refer, refer, release, retainCountMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.yahoo.container.jdisc.HttpRequestHandler
requestHandlerSpecMethods inherited from interface com.yahoo.jdisc.handler.RequestHandler
handleRequest, handleTimeoutMethods inherited from interface com.yahoo.jdisc.SharedResource
refer, refer, release
-
Field Details
-
DEFAULT_RENDERER_ID
- See Also:
-
-
Constructor Details
-
AbstractProcessingHandler
-
AbstractProcessingHandler
public AbstractProcessingHandler(ChainRegistry<COMPONENT> chainRegistry, com.yahoo.component.provider.ComponentRegistry<Renderer> renderers, Executor executor, AccessLog ignored) -
AbstractProcessingHandler
public AbstractProcessingHandler(ChainsConfig processingChainsConfig, com.yahoo.component.provider.ComponentRegistry<COMPONENT> chainedComponents, com.yahoo.component.provider.ComponentRegistry<Renderer> renderers, Executor executor, AccessLog ignored) -
AbstractProcessingHandler
-
-
Method Details
-
handle
Throws UnsupportedOperationException: Call handle(request, channel instead)- Specified by:
handlein classThreadedHttpRequestHandler- Parameters:
request- incoming HTTP request- Returns:
- a valid HTTP response for presentation to the user
-
handle
Description copied from class:ThreadedHttpRequestHandlerOverride this rather than handle(request) to be able to write to the channel before returning from this method. This default implementation calls handle(request)- Overrides:
handlein classThreadedHttpRequestHandler
-
createExecution
-
getChainRegistry
-
getRenderers
-
getRendererCopy
For internal use only
-