Class AutoNIOSSLTransportServer
- java.lang.Object
-
- org.apache.activemq.util.ServiceSupport
-
- org.apache.activemq.transport.TransportServerSupport
-
- org.apache.activemq.transport.TransportServerThreadSupport
-
- org.apache.activemq.transport.tcp.TcpTransportServer
-
- org.apache.activemq.transport.auto.AutoTcpTransportServer
-
- org.apache.activemq.transport.auto.nio.AutoNIOSSLTransportServer
-
- All Implemented Interfaces:
Runnable,Service,TransportServer,ServiceListener
public class AutoNIOSSLTransportServer extends AutoTcpTransportServer
Licensed to the Apache Software Foundation (ASF) under one or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.activemq.transport.auto.AutoTcpTransportServer
AutoTcpTransportServer.ProtocolInfo
-
Nested classes/interfaces inherited from class org.apache.activemq.transport.tcp.TcpTransportServer
TcpTransportServer.TransportInfo
-
-
Field Summary
-
Fields inherited from class org.apache.activemq.transport.auto.AutoTcpTransportServer
autoTransportOptions, brokerService, enabledProtocols, maxConnectionThreadPoolSize, newConnectionExecutor, protocolDetectionExecutor, protocolDetectionTimeOut, protocolVerifiers, wireFormatOptions
-
Fields inherited from class org.apache.activemq.transport.tcp.TcpTransportServer
allowLinkStealing, backlog, connectionTimeout, currentTransportCount, dynamicManagement, jmxPort, logWriterName, maximumConnections, maxInactivityDuration, maxInactivityDurationInitalDelay, minmumWireFormatVersion, selector, serverSocket, serverSocketFactory, socketBufferSize, socketHandlerThread, socketQueue, soTimeout, startLogging, trace, transportFactory, useQueueForAccept, verifyHostName, wireFormatFactory
-
Fields inherited from class org.apache.activemq.transport.TransportServerSupport
transportOptions
-
-
Constructor Summary
Constructors Constructor Description AutoNIOSSLTransportServer(SSLContext context, TcpTransportFactory transportFactory, URI location, ServerSocketFactory serverSocketFactory, BrokerService brokerService, Set<String> enabledProtocols)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected TcpTransportServer.TransportInfoconfigureTransport(TcpTransportServer server, Socket socket)protected TcpTransportcreateTransport(Socket socket, WireFormat format)Allow derived classes to override the Transport implementation that this transport server creates.protected TransportcreateTransport(Socket socket, WireFormat format, SSLEngine engine, TcpTransport.InitBuffer initBuffer, ByteBuffer inputBuffer, TcpTransportFactory detectedFactory)booleanisNeedClientAuth()booleanisSslServer()For TransportServers that provide SSL connections to their connected peers they should return true here if and only if they populate the ConnectionInfo command presented to the Broker with the peers certificate chain so that the broker knows it can use that information to authenticate the connected peer.booleanisWantClientAuth()voidsetNeedClientAuth(boolean value)voidsetWantClientAuth(boolean value)-
Methods inherited from class org.apache.activemq.transport.auto.AutoTcpTransportServer
append, createTransport, detectProtocol, doStop, findTransportFactory, findWireFormatFactory, getMaxConnectionThreadPoolSize, handleSocket, initOpenWireProtocolVerifier, initProtocolVerifiers, isAllProtocols, setAutoTransportOptions, setEnabledProtocols, setMaxConnectionThreadPoolSize, setProtocolDetectionTimeOut, setWireFormatFactory, setWireFormatOptions, waitForProtocolDetectionFinish
-
Methods inherited from class org.apache.activemq.transport.tcp.TcpTransportServer
bind, doHandleSocket, doStart, getBacklog, getConnectionTimeout, getCurrentTransportCount, getJmxPort, getLogWriterName, getMaximumConnections, getMaxInactivityDuration, getMaxInactivityDurationInitalDelay, getMinmumWireFormatVersion, getSocketAddress, getSocketBufferSize, getSoTimeout, getWireFormatFactory, isAllowLinkStealing, isDynamicManagement, isStartLogging, isTrace, isUseQueueForAccept, resolveHostName, run, setAllowLinkStealing, setBacklog, setBrokerInfo, setConnectionTimeout, setDynamicManagement, setJmxPort, setLogWriterName, setMaximumConnections, setMaxInactivityDuration, setMaxInactivityDurationInitalDelay, setMinmumWireFormatVersion, setSocketBufferSize, setSoTimeout, setStartLogging, setTrace, setUseQueueForAccept, started, stopped, toString
-
Methods inherited from class org.apache.activemq.transport.TransportServerThreadSupport
getStackSize, isDaemon, isJoinOnStop, setDaemon, setJoinOnStop, setStackSize
-
Methods inherited from class org.apache.activemq.transport.TransportServerSupport
getAcceptListener, getBindLocation, getConnectURI, onAcceptError, setAcceptListener, setBindLocation, setConnectURI, setTransportOption
-
Methods inherited from class org.apache.activemq.util.ServiceSupport
addServiceListener, dispose, isStarted, isStopped, isStopping, postStop, preStart, removeServiceListener, start, stop
-
-
-
-
Constructor Detail
-
AutoNIOSSLTransportServer
public AutoNIOSSLTransportServer(SSLContext context, TcpTransportFactory transportFactory, URI location, ServerSocketFactory serverSocketFactory, BrokerService brokerService, Set<String> enabledProtocols) throws IOException, URISyntaxException
- Throws:
IOExceptionURISyntaxException
-
-
Method Detail
-
createTransport
protected Transport createTransport(Socket socket, WireFormat format, SSLEngine engine, TcpTransport.InitBuffer initBuffer, ByteBuffer inputBuffer, TcpTransportFactory detectedFactory) throws IOException
- Throws:
IOException
-
createTransport
protected TcpTransport createTransport(Socket socket, WireFormat format) throws IOException
Description copied from class:TcpTransportServerAllow derived classes to override the Transport implementation that this transport server creates.- Overrides:
createTransportin classTcpTransportServer- Returns:
- a new Transport instance.
- Throws:
IOException
-
isSslServer
public boolean isSslServer()
Description copied from interface:TransportServerFor TransportServers that provide SSL connections to their connected peers they should return true here if and only if they populate the ConnectionInfo command presented to the Broker with the peers certificate chain so that the broker knows it can use that information to authenticate the connected peer.- Specified by:
isSslServerin interfaceTransportServer- Overrides:
isSslServerin classTcpTransportServer- Returns:
- true if this transport server provides SSL level security over its connections.
-
isNeedClientAuth
public boolean isNeedClientAuth()
-
setNeedClientAuth
public void setNeedClientAuth(boolean value)
-
isWantClientAuth
public boolean isWantClientAuth()
-
setWantClientAuth
public void setWantClientAuth(boolean value)
-
configureTransport
protected TcpTransportServer.TransportInfo configureTransport(TcpTransportServer server, Socket socket) throws Exception
- Overrides:
configureTransportin classAutoTcpTransportServer- Throws:
Exception
-
-