class ClientDeserializeCtx[Rep] extends (Array[Byte]) ⇒ ReqRep
Used by Thrift and ThriftMux Client to facilitate giving the Finagle stack access to various data that are computed outside of Finagle's stack.
This includes:
- the deserialized forms of Thrift requests and responses.
- the name of the rpc.
- the elapsed time to serialize the request.
- the elapsed time to deserialize the response.
While this is thread-safe, it should only be used for the life of a single request/response pair.
When using Scrooge for code
generation, a proper ClientDeserializeCtx will be available
to code via Contexts.local(ClientDeserializeCtx.Key).
- Note
this class has evolved and it's name is now a bit too specific for its more expanded role.
- Alphabetic
- By Inheritance
- ClientDeserializeCtx
- Function1
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
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
-
def
andThen[A](g: (ReqRep) ⇒ A): (Array[Byte]) ⇒ A
- Definition Classes
- Function1
- Annotations
- @unspecialized()
-
def
apply(responseBytes: Array[Byte]): ReqRep
- Definition Classes
- ClientDeserializeCtx → Function1
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
def
compose[A](g: (A) ⇒ Array[Byte]): (A) ⇒ ReqRep
- Definition Classes
- Function1
- Annotations
- @unspecialized()
-
def
deserializationTime: Long
Gets how long, in nanoseconds, it took for the client to deserialize the response from Thrift format.
Gets how long, in nanoseconds, it took for the client to deserialize the response from Thrift format.
Negative values indicate that this was not recorded and as such, should be ignored.
-
def
deserialize(responseBytes: Array[Byte]): Try[Rep]
Deserialize the given bytes.
Deserialize the given bytes.
Ensures that deserialization will only happen once for non fan-out responses regardless of future inputs. If different bytes are seen on future calls, this will still return the first deserialized result.
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @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
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- val request: Any
-
def
rpcName: Option[String]
Gets the rpc method's name, if set.
-
def
rpcName(name: String): Unit
Sets the name of the the rpc method.
-
def
serializationTime: Long
Gets how long, in nanoseconds, it took for the client to serialize the request into Thrift format.
Gets how long, in nanoseconds, it took for the client to serialize the request into Thrift format.
Negative values indicate that this was not recorded and as such, should be ignored.
-
def
serializationTime(nanos: Long): Unit
Sets how long, in nanoseconds, it took for the client to serialize the request into Thrift format.
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- Function1 → AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()