use of org.apache.activemq.command.ConnectionInfo in project activemq-artemis by apache.
the class ConnectionInfoTest method createObject.
@Override
public Object createObject() throws Exception {
ConnectionInfo info = new ConnectionInfo();
populateObject(info);
return info;
}
use of org.apache.activemq.command.ConnectionInfo in project activemq-artemis by apache.
the class JaasDualAuthenticationBrokerTest method setUp.
@Override
protected void setUp() throws Exception {
receiveBroker = new StubBroker();
authBroker = new JaasDualAuthenticationBroker(receiveBroker, "activemq-domain", "activemq-ssl-domain");
connectionContext = new ConnectionContext();
SSLServerSocket sslServerSocket = new StubSSLServerSocket();
StubSSLSocketFactory socketFactory = new StubSSLSocketFactory(sslServerSocket);
try {
sslTransportServer = new SslTransportServer(null, new URI("ssl://localhost:61616?needClientAuth=true"), socketFactory);
} catch (Exception e) {
fail("Unable to create SslTransportServer.");
}
sslTransportServer.setNeedClientAuth(true);
sslTransportServer.bind();
try {
nonSslTransportServer = new TcpTransportServer(null, new URI("tcp://localhost:61613"), socketFactory);
} catch (Exception e) {
fail("Unable to create TcpTransportServer.");
}
connectionInfo = new ConnectionInfo();
createLoginConfig();
}
use of org.apache.activemq.command.ConnectionInfo in project activemq-artemis by apache.
the class JaasCertificateAuthenticationBrokerTest method setUp.
@Override
protected void setUp() throws Exception {
receiveBroker = new StubBroker();
authBroker = new JaasCertificateAuthenticationBroker(receiveBroker, "");
connectionContext = new ConnectionContext();
connectionInfo = new ConnectionInfo();
connectionInfo.setTransportContext(new StubX509Certificate[] {});
}
use of org.apache.activemq.command.ConnectionInfo in project activemq-artemis by apache.
the class ConnectionInfoTest method createObject.
@Override
public Object createObject() throws Exception {
ConnectionInfo info = new ConnectionInfo();
populateObject(info);
return info;
}
use of org.apache.activemq.command.ConnectionInfo in project activemq-artemis by apache.
the class ConnectionInfoTest method populateObject.
@Override
protected void populateObject(Object object) throws Exception {
super.populateObject(object);
ConnectionInfo info = (ConnectionInfo) object;
info.setConnectionId(createConnectionId("ConnectionId:1"));
info.setClientId("ClientId:2");
info.setPassword("Password:3");
info.setUserName("UserName:4");
{
BrokerId[] value = new BrokerId[2];
for (int i = 0; i < 2; i++) {
value[i] = createBrokerId("BrokerPath:5");
}
info.setBrokerPath(value);
}
info.setBrokerMasterConnector(true);
info.setManageable(false);
info.setClientMaster(true);
}
Aggregations