public ReceiveCompletionProcessor(ZerioConfiguration configuration, RioCompletionQueue receivingCompletionQueue, ISessionManager sessionManager, RequestProcessingEngine requestProcessingEngine) { _configuration = configuration; _receivingCompletionQueue = receivingCompletionQueue; _sessionManager = sessionManager; _requestProcessingEngine = requestProcessingEngine; }
public SessionManager(ZerioConfiguration configuration, CompletionQueues completionQueues) { _configuration = configuration; _completionQueues = completionQueues; CreateSessions(); }
public SendCompletionProcessor(ZerioConfiguration configuration, RioCompletionQueue sendCompletionQueue) { _configuration = configuration; _sendCompletionQueue = sendCompletionQueue; _completionResults = new RIO_RESULT[configuration.MaxSendCompletionResults]; _completionResultsHandle = GCHandle.Alloc(_completionResults, GCHandleType.Pinned); _completionResultsPointer = (RIO_RESULT *)_completionResultsHandle.AddrOfPinnedObject().ToPointer(); }
public Session(int sessionId, ZerioConfiguration configuration, CompletionQueues completionQueues) { Id = sessionId; _configuration = configuration; _completionQueues = completionQueues; _receivingBuffer = new UnmanagedRioBuffer <RioBufferSegment>(configuration.ReceivingBufferCount, _configuration.ReceivingBufferLength); _messageFramer = new MessageFramer(configuration.FramingBufferLength); _messageFramer.MessageFramed += OnMessageFramed; }
public RequestProcessingEngine(ZerioConfiguration configuration, RioCompletionQueue sendingCompletionQueue, ISessionManager sessionManager) { _configuration = configuration; var ringBufferSize = ZerioConfiguration.GetNextPowerOfTwo(_configuration.SendingBufferCount + _configuration.ReceivingBufferCount * _configuration.SessionCount); _unmanagedRioBuffer = new UnmanagedRioBuffer <RequestEntry>(ringBufferSize, _configuration.SendingBufferLength); _disruptor = CreateDisruptor(sendingCompletionQueue, sessionManager); _ringBuffer = _disruptor.RingBuffer; }
public CompletionQueues(ZerioConfiguration configuration) { SendingQueue = new RioCompletionQueue((configuration.MaxSendCompletionResults + configuration.MaxReceiveCompletionResults) * configuration.SessionCount); ReceivingQueue = new RioCompletionQueue((configuration.MaxSendCompletionResults + configuration.MaxReceiveCompletionResults) * configuration.SessionCount); }