Class JettyHTTPDestination
- java.lang.Object
-
- org.apache.cxf.transport.AbstractObservable
-
- org.apache.cxf.transport.AbstractDestination
-
- org.apache.cxf.transport.AbstractMultiplexDestination
-
- org.apache.cxf.transport.http.AbstractHTTPDestination
-
- org.apache.cxf.transport.servlet.ServletDestination
-
- org.apache.cxf.transport.http_jetty.JettyHTTPDestination
-
- All Implemented Interfaces:
Configurable,Assertor,Destination,DestinationWithEndpoint,MultiplexDestination,Observable,ServletConfigAware
- Direct Known Subclasses:
AtmosphereWebSocketJettyDestination,Jetty10WebSocketDestination
public class JettyHTTPDestination extends ServletDestination
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.cxf.transport.http.AbstractHTTPDestination
AbstractHTTPDestination.BackChannelConduit, AbstractHTTPDestination.PrincipalAuthorizationPolicy
-
Nested classes/interfaces inherited from class org.apache.cxf.transport.AbstractDestination
AbstractDestination.AbstractBackChannelConduit
-
-
Field Summary
Fields Modifier and Type Field Description protected JettyHTTPServerEngineengineprotected JettyHTTPHandlerhandlerprotected ClassLoaderloaderprotected URLnurlprotected JettyHTTPServerEngineFactoryserverEngineFactoryprotected javax.servlet.ServletContextservletContext-
Fields inherited from class org.apache.cxf.transport.http.AbstractHTTPDestination
bus, certConstraints, contextMatchStrategy, cproviderFactory, CXF_ASYNC_CONTEXT, CXF_CONTINUATION_MESSAGE, decodeBasicAuthWithIso8859, enableWebSocket, fixedParameterOrder, HTTP_CONFIG, HTTP_CONTEXT, HTTP_CONTEXT_MATCH_STRATEGY, HTTP_REQUEST, HTTP_RESPONSE, isServlet3, multiplexWithAddress, path, registry, REQUEST_REDIRECTED, RESPONSE_COMMITED, RESPONSE_HEADERS_COPIED, serverPolicy, SERVICE_REDIRECTION
-
Fields inherited from class org.apache.cxf.transport.AbstractDestination
endpointInfo, reference
-
Fields inherited from class org.apache.cxf.transport.AbstractObservable
incomingObserver
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedJettyHTTPDestination(Bus bus, DestinationRegistry registry, EndpointInfo ei, URL nurl, JettyHTTPServerEngineFactory serverEngineFactory)JettyHTTPDestination(Bus bus, DestinationRegistry registry, EndpointInfo ei, JettyHTTPServerEngineFactory serverEngineFactory)Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected voidactivate()Activate receipt of incoming messages.protected JettyHTTPHandlercreateJettyHTTPHandler(JettyHTTPDestination jhd, boolean cmExact)protected voiddeactivate()Deactivate receipt of incoming messages.protected voiddoService(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp)protected voiddoService(javax.servlet.ServletContext context, javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp)voidfinalizeConfig()This method is used to finalize the configuration after the configuration items have been set.protected OutputStreamflushHeaders(Message outMessage, boolean getStream)protected StringgetAddress(EndpointInfo endpointInfo)protected StringgetBasePathForFullAddress(String addr)ServerEnginegetEngine()protected LoggergetLogger()protected voidinvokeComplete(javax.servlet.ServletContext context, javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp, Message m)protected voidretrieveEngine()Post-configure retreival of server engine.protected MessageretrieveFromContinuation(javax.servlet.http.HttpServletRequest req)voidsetServletContext(javax.servlet.ServletContext sc)-
Methods inherited from class org.apache.cxf.transport.servlet.ServletDestination
getBasePath
-
Methods inherited from class org.apache.cxf.transport.http.AbstractHTTPDestination
assertMessage, canAssert, contextMatchOnExact, flushHeaders, getAddressValue, getAddressValue, getAddressWithId, getBeanName, getBus, getContextMatchStrategy, getId, getInbuiltBackChannel, getPath, getServer, invoke, isFixedParameterOrder, isMultiplexWithAddress, isOneWay, releaseRegistry, retrieveFromServlet3Async, setContextMatchStrategy, setFixedParameterOrder, setMultiplexWithAddress, setServer, setupContinuation, setupMessage, shutdown
-
Methods inherited from class org.apache.cxf.transport.AbstractDestination
getAddress, getBackChannel, getEndpointInfo
-
Methods inherited from class org.apache.cxf.transport.AbstractObservable
getMessageObserver, getTargetReference, getTargetReference, setMessageObserver
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.cxf.transport.Destination
getAddress, getBackChannel, getMessageObserver
-
Methods inherited from interface org.apache.cxf.transport.Observable
setMessageObserver
-
Methods inherited from interface org.apache.cxf.transport.servlet.ServletConfigAware
onServletConfigAvailable
-
-
-
-
Field Detail
-
engine
protected JettyHTTPServerEngine engine
-
serverEngineFactory
protected JettyHTTPServerEngineFactory serverEngineFactory
-
handler
protected JettyHTTPHandler handler
-
servletContext
protected javax.servlet.ServletContext servletContext
-
nurl
protected URL nurl
-
loader
protected ClassLoader loader
-
-
Constructor Detail
-
JettyHTTPDestination
public JettyHTTPDestination(Bus bus, DestinationRegistry registry, EndpointInfo ei, JettyHTTPServerEngineFactory serverEngineFactory) throws IOException
Constructor- Parameters:
bus- the associated Busregistry- the associated destinationRegistryei- the endpoint info of the destinationserverEngineFactory- the serverEngineFactory which could be used to create ServerEngine- Throws:
IOException
-
JettyHTTPDestination
protected JettyHTTPDestination(Bus bus, DestinationRegistry registry, EndpointInfo ei, URL nurl, JettyHTTPServerEngineFactory serverEngineFactory) throws IOException
- Throws:
IOException
-
-
Method Detail
-
getLogger
protected Logger getLogger()
- Overrides:
getLoggerin classServletDestination- Returns:
- the logger to use
-
setServletContext
public void setServletContext(javax.servlet.ServletContext sc)
-
retrieveEngine
protected void retrieveEngine() throws GeneralSecurityException, IOExceptionPost-configure retreival of server engine.- Throws:
GeneralSecurityExceptionIOException
-
finalizeConfig
public void finalizeConfig()
This method is used to finalize the configuration after the configuration items have been set.- Overrides:
finalizeConfigin classAbstractHTTPDestination
-
getAddress
protected String getAddress(EndpointInfo endpointInfo)
-
activate
protected void activate()
Activate receipt of incoming messages.- Overrides:
activatein classAbstractHTTPDestination
-
createJettyHTTPHandler
protected JettyHTTPHandler createJettyHTTPHandler(JettyHTTPDestination jhd, boolean cmExact)
-
deactivate
protected void deactivate()
Deactivate receipt of incoming messages.- Overrides:
deactivatein classAbstractHTTPDestination
-
doService
protected void doService(javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) throws IOException- Throws:
IOException
-
doService
protected void doService(javax.servlet.ServletContext context, javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp) throws IOException- Throws:
IOException
-
invokeComplete
protected void invokeComplete(javax.servlet.ServletContext context, javax.servlet.http.HttpServletRequest req, javax.servlet.http.HttpServletResponse resp, Message m) throws IOException- Overrides:
invokeCompletein classAbstractHTTPDestination- Throws:
IOException
-
flushHeaders
protected OutputStream flushHeaders(Message outMessage, boolean getStream) throws IOException
- Overrides:
flushHeadersin classAbstractHTTPDestination- Throws:
IOException
-
getEngine
public ServerEngine getEngine()
-
retrieveFromContinuation
protected Message retrieveFromContinuation(javax.servlet.http.HttpServletRequest req)
- Overrides:
retrieveFromContinuationin classAbstractHTTPDestination
-
-