public AbstractConnectionContext(AMQPConnectionCallback connectionCallback, String containerId, int idleTimeout, int maxFrameSize, int channelMax, Executor dispatchExecutor, ScheduledExecutorService scheduledPool) { this.connectionCallback = connectionCallback; this.containerId = (containerId != null) ? containerId : UUID.randomUUID().toString(); connectionProperties.put(Symbol.valueOf("product"), "apache-activemq-artemis"); connectionProperties.put(Symbol.valueOf("version"), VersionLoader.getVersion().getFullVersion()); this.scheduledPool = scheduledPool; connectionCallback.setConnection(this); this.handler = ProtonHandler.Factory.create(dispatchExecutor); Transport transport = handler.getTransport(); transport.setEmitFlowEventOnSend(false); if (idleTimeout > 0) { transport.setIdleTimeout(idleTimeout); } transport.setChannelMax(channelMax); transport.setMaxFrameSize(maxFrameSize); handler.addEventHandler(listener); }
transport.setMaxFrameSize(maxFrameSize); transport.setOutboundFrameSizeLimit(maxFrameSize); if (!isIncomingConnection && saslClientFactory != null) {
transport.setMaxFrameSize(maxFrameSize); transport.setOutboundFrameSizeLimit(maxFrameSize); if (!isIncomingConnection && saslClientFactory != null) {
protonTransport.setMaxFrameSize(getMaxFrameSize()); protonTransport.setOutboundFrameSizeLimit(getMaxFrameSize());
protonTransport.setMaxFrameSize(getMaxFrameSize()); protonTransport.setOutboundFrameSizeLimit(getMaxFrameSize());
protonTransport.setIdleTimeout(getIdleTimeout()); protonTransport.setMaxFrameSize(getMaxFrameSize()); protonTransport.setChannelMax(getChannelMax()); protonTransport.setEmitFlowEventOnSend(false);
public AmqpConnection(AmqpTransport transport, BrokerService brokerService) { this.amqpTransport = transport; AmqpInactivityMonitor monitor = transport.getInactivityMonitor(); if (monitor != null) { monitor.setAmqpTransport(amqpTransport); } this.amqpWireFormat = transport.getWireFormat(); this.brokerService = brokerService; // the configured maxFrameSize on the URI. int maxFrameSize = amqpWireFormat.getMaxAmqpFrameSize(); if (maxFrameSize > AmqpWireFormat.NO_AMQP_MAX_FRAME_SIZE) { this.protonTransport.setMaxFrameSize(maxFrameSize); try { this.protonTransport.setOutboundFrameSizeLimit(maxFrameSize); } catch (Throwable e) { // Ignore if older proton-j was injected. } } this.protonTransport.bind(this.protonConnection); this.protonTransport.setChannelMax(CHANNEL_MAX); this.protonTransport.setEmitFlowEventOnSend(false); this.protonConnection.collect(eventCollector); updateTracer(); }
trans.setMaxFrameSize(maxFrameSizeOption);
public AmqpConnection(AmqpTransport transport, BrokerService brokerService) { this.amqpTransport = transport; AmqpInactivityMonitor monitor = transport.getInactivityMonitor(); if (monitor != null) { monitor.setAmqpTransport(amqpTransport); } this.amqpWireFormat = transport.getWireFormat(); this.brokerService = brokerService; // the configured maxFrameSize on the URI. int maxFrameSize = amqpWireFormat.getMaxAmqpFrameSize(); if (maxFrameSize > AmqpWireFormat.NO_AMQP_MAX_FRAME_SIZE) { this.protonTransport.setMaxFrameSize(maxFrameSize); try { this.protonTransport.setOutboundFrameSizeLimit(maxFrameSize); } catch (Throwable e) { // Ignore if older proton-j was injected. } } this.protonTransport.bind(this.protonConnection); this.protonTransport.setChannelMax(CHANNEL_MAX); this.protonTransport.setEmitFlowEventOnSend(false); this.protonConnection.collect(eventCollector); updateTracer(); }
ProtonTransport(Connection connection, Vertx vertx, NetClient netClient, NetSocket socket, ProtonSaslAuthenticator authenticator, ProtonTransportOptions options) { this.connection = connection; this.vertx = vertx; this.netClient = netClient; this.socket = socket; int maxFrameSize = options.getMaxFrameSize() == 0 ? DEFAULT_MAX_FRAME_SIZE : options.getMaxFrameSize(); transport.setMaxFrameSize(maxFrameSize); transport.setOutboundFrameSizeLimit(maxFrameSize); transport.setEmitFlowEventOnSend(false); // TODO: make configurable transport.setIdleTimeout(2 * options.getHeartbeat()); ((TransportInternal) transport).setUseReadOnlyOutputBuffer(false); if (authenticator != null) { authenticator.init(this.socket, (ProtonConnection) this.connection.getContext(), transport); } this.authenticator = authenticator; transport.bind(connection); connection.collect(collector); socket.endHandler(this::handleSocketEnd); socket.handler(this::handleSocketBuffer); }
transport.setMaxFrameSize(maxFrameSizeOption);