| | |
| | | import org.opends.server.core.AbandonOperationBasis; |
| | | import org.opends.server.core.AddOperationBasis; |
| | | import org.opends.server.core.BindOperationBasis; |
| | | import org.opends.server.core.BoundedWorkQueueStrategy; |
| | | import org.opends.server.core.CompareOperationBasis; |
| | | import org.opends.server.core.DeleteOperationBasis; |
| | | import org.opends.server.core.ExtendedOperationBasis; |
| | |
| | | import org.opends.server.core.QueueingStrategy; |
| | | import org.opends.server.core.SearchOperationBasis; |
| | | import org.opends.server.core.UnbindOperationBasis; |
| | | import org.opends.server.core.WorkQueueStrategy; |
| | | import org.opends.server.loggers.debug.DebugTracer; |
| | | import org.opends.server.types.AuthenticationInfo; |
| | | import org.opends.server.types.ByteString; |
| | |
| | | private AtomicInteger nextMessageID = new AtomicInteger(0); |
| | | |
| | | /** The queueing strategy used for this connection. */ |
| | | private QueueingStrategy queueingStrategy = new WorkQueueStrategy(); |
| | | private final QueueingStrategy queueingStrategy; |
| | | |
| | | /** |
| | | * Whether this connection has been closed by calling {@link #close()} or |
| | |
| | | public SdkConnectionAdapter(HTTPClientConnection clientConnection) |
| | | { |
| | | this.clientConnection = clientConnection; |
| | | this.queueingStrategy = |
| | | new BoundedWorkQueueStrategy(clientConnection.getConnectionHandler() |
| | | .getCurrentConfig().getMaxConcurrentOpsPerConnection()); |
| | | } |
| | | |
| | | @SuppressWarnings({ "rawtypes", "unchecked" }) |
| | |
| | | return enqueueOperation(operation, resultHandler); |
| | | } |
| | | |
| | | /** |
| | | * Return the queueing strategy used by this connection. |
| | | * |
| | | * @return The queueing strategy used by this connection |
| | | */ |
| | | public QueueingStrategy getQueueingStrategy() |
| | | { |
| | | return queueingStrategy; |
| | | } |
| | | |
| | | /** {@inheritDoc} */ |
| | | @Override |
| | | public boolean isClosed() |