Module org.glassfish.grizzly
Class TCPNIOAsyncQueueWriter
java.lang.Object
org.glassfish.grizzly.AbstractWriter<SocketAddress>
org.glassfish.grizzly.nio.AbstractNIOAsyncQueueWriter
org.glassfish.grizzly.nio.transport.TCPNIOAsyncQueueWriter
- All Implemented Interfaces:
AsyncQueue,AsyncQueueWriter<SocketAddress>,Writer<SocketAddress>
The TCP transport
AsyncQueueWriter implementation, based on the Java NIO- Author:
- Alexey Stashok
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.glassfish.grizzly.asyncqueue.AsyncQueue
AsyncQueue.AsyncResultNested classes/interfaces inherited from interface org.glassfish.grizzly.Writer
Writer.Reentrant -
Field Summary
Fields inherited from class org.glassfish.grizzly.nio.AbstractNIOAsyncQueueWriter
maxPendingBytes, maxWriteReentrants, transportFields inherited from interface org.glassfish.grizzly.asyncqueue.AsyncQueue
EXPECTING_MORE_OPTIONFields inherited from interface org.glassfish.grizzly.asyncqueue.AsyncQueueWriter
AUTO_SIZE, UNLIMITED_SIZE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected AsyncWriteQueueRecordaggregate(TaskQueue<AsyncWriteQueueRecord> writeTaskQueue) Aggregates records in a queue to be written as one chunk.protected voidonReadyToWrite(NIOConnection connection) protected RecordWriteResultwrite0(NIOConnection connection, AsyncWriteQueueRecord queueRecord) protected longwrite0(NIOConnection connection, WritableMessage message, WriteResult<WritableMessage, SocketAddress> currentResult) Methods inherited from class org.glassfish.grizzly.nio.AbstractNIOAsyncQueueWriter
canWrite, canWrite, close, createRecord, getMaxPendingBytesPerConnection, isAllowDirectWrite, isReady, notifyWritePossible, notifyWritePossible, onClose, onWriteFailure, processAsync, setAllowDirectWrite, setMaxPendingBytesPerConnection, write, write, writeMethods inherited from class org.glassfish.grizzly.AbstractWriter
write, write, write, write
-
Constructor Details
-
TCPNIOAsyncQueueWriter
-
-
Method Details
-
write0
protected RecordWriteResult write0(NIOConnection connection, AsyncWriteQueueRecord queueRecord) throws IOException - Specified by:
write0in classAbstractNIOAsyncQueueWriter- Throws:
IOException
-
write0
protected long write0(NIOConnection connection, WritableMessage message, WriteResult<WritableMessage, SocketAddress> currentResult) throws IOException- Throws:
IOException
-
onReadyToWrite
- Specified by:
onReadyToWritein classAbstractNIOAsyncQueueWriter- Throws:
IOException
-
aggregate
Aggregates records in a queue to be written as one chunk.- Overrides:
aggregatein classAbstractNIOAsyncQueueWriter
-