object impl
- Source
- BrokerConnection.scala
- Alphabetic
- By Inheritance
- impl
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @IntrinsicCandidate() @native()
- def collectChunks(in: ByteVector, msgSz: Option[Int]): (ByteVector, Option[Int], Chunk[ByteVector])
Collects chunks of messages received.
Collects chunks of messages received. Each chunk is forming whole message, that means this looks for the first 4 bytes, that indicates message size, then this take up to that size to produce single ByteVector of message content, and emits that content it term of Segment. Note that Segment may be empty or may contain multiple characters
- def decodeReceived[F[_]](openRequests: Ref[F, Map[Int, RequestMessage]])(implicit arg0: RaiseThrowable[F]): Pipe[F, ByteVector, ResponseMessage]
Decodes message received.
Decodes message received. Due to kafka protocol not having response type encoded in protocol itself, we need to consult correlation id, that is read first from the message to identify response type.
If request is found for given message, this will remove that request from supplied map and will deserialize message according the request type.
If request cannot be found, this fails, as well as when message cannot be decoded.
- openRequests
Ref of current open requests.
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- def hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @IntrinsicCandidate() @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @IntrinsicCandidate() @native()
- def receiveChunks[F[_]](implicit arg0: RaiseThrowable[F]): Pipe[F, Byte, ByteVector]
Collects bytes as they arrive producing chunks of ByteVector This reads 32 bits size first, then it reads up to that size of message data emitting single ByteVector.
Collects bytes as they arrive producing chunks of ByteVector This reads 32 bits size first, then it reads up to that size of message data emitting single ByteVector.
This combinator respects chunks. So if there was more chunks collected in single go, they all are emitted in chunk.
- def receiveMessages[F[_]](openRequests: Ref[F, Map[Int, RequestMessage]])(implicit arg0: Async[F]): Pipe[F, Byte, ResponseMessage]
- def sendMessages[F[_]](openRequests: Ref[F, Map[Int, RequestMessage]], sendOne: (Chunk[Byte]) => F[Unit])(implicit arg0: Applicative[F], arg1: RaiseThrowable[F]): Pipe[F, RequestMessage, Nothing]
Pipe that will send one message with
sendOne
shile updating theopenRequests
.Pipe that will send one message with
sendOne
shile updating theopenRequests
. TheopenRequests
or not updated for ProduceRequests that do not expect confirmation from kafka - final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- AnyRef → Any
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])