open class CordaRPCClientConfiguration
Can be used to configure the RPC client connection.
CordaRPCClientConfiguration(connectionMaxRetryInterval: Duration = 3.minutes, minimumServerProtocolVersion: Int = PLATFORM_VERSION, trackRpcCallSites: Boolean = java.lang.Boolean.getBoolean("net.corda.client.rpc.trackRpcCallSites"), reapInterval: Duration = 1.seconds, observationExecutorPoolSize: Int = 4, connectionRetryInterval: Duration = 5.seconds, connectionRetryIntervalMultiplier: Double = 1.5, maxReconnectAttempts: Int = unlimitedReconnectAttempts, maxFileSize: Int = 10485760, deduplicationCacheExpiry: Duration = 1.days)
Can be used to configure the RPC client connection. |
open val connectionMaxRetryInterval: Duration
The maximum retry interval for re-connections. The client will retry connections if the host is lost with ever increasing spacing until the max is reached. The default is 3 minutes. |
|
open val connectionRetryInterval: Duration
The base retry interval for reconnection attempts. The default is 5 seconds. |
|
open val connectionRetryIntervalMultiplier: Double
The retry interval multiplier for exponential backoff. The default is 1.5 |
|
open val deduplicationCacheExpiry: Duration
The cache expiry of a deduplication watermark per client. Default is 1 day. |
|
open val maxFileSize: Int
Maximum size of RPC responses, in bytes. Default is 10mb. |
|
open val maxReconnectAttempts: Int
Maximum reconnect attempts on failover or disconnection. Any negative value would mean that there will be an infinite number of reconnect attempts. |
|
open val minimumServerProtocolVersion: Int
The minimum protocol version required from the server. This is equivalent to the node's platform version number. If this minimum version is not met, an exception will be thrown at startup. If you use features introduced in a later version, you can bump this to match the platform version you need and get an early check that runs before you do anything. |
|
open val observationExecutorPoolSize: Int
The number of threads to use for observations for executing Observable.onNext. This only has any effect if observableExecutor is null (which is the default). The default is 4. |
|
open val reapInterval: Duration
The interval of unused observable reaping. Leaked Observables (unused ones) are detected using weak references and are cleaned up in batches in this interval. If set too large it will waste server side resources for this duration. If set too low it wastes client side cycles. The default is to check once per second. |
|
open val trackRpcCallSites: Boolean
If set to true the client will track RPC call sites (default is false). If an error occurs subsequently during the RPC or in a returned Observable stream the stack trace of the originating RPC will be shown as well. Note that constructing call stacks is a moderately expensive operation. |
operator fun |
|
open fun equals(other: Any?): Boolean |
|
open fun hashCode(): Int |
|
open fun toString(): String |
val DEFAULT: CordaRPCClientConfiguration
Provides an instance of this class with the parameters set to our recommended defaults. |
fun Any.contextLogger(): <ERROR CLASS>
When called from a companion object, returns the logger for the enclosing class. |