Contextual value represents bulkhead name
Contextual value represents bulkhead name
Contextual value represents event create time
Contextual value represents event create time
(bulkhead name)
(bulkhead name config)
Create a thread pool bulkhead with a name
and a default or custom configurations.
The name
argument is only used to register this newly created thread pool bulkhead
to a ThreadPoolBulkheadRegistry. If you don't want to bind this bulkhead with
a ThreadPoolBulkheadRegistry, the name
argument is ignored.
Please refer to thread-pool-bulkhead-config
for allowed key value pairs
within the bulkhead configurations map.
If you want to register this thread pool bulkhead to a ThreadPoolBulkheadRegistry,
you need to put :registry key with a ThreadPoolBulkheadRegistry in the config
argument. If you do not provide any other configurations, the newly created
bulkhead will inherit bulkhead configurations from this
provided ThreadPoolBulkheadRegistry
Example:
(bulkhead my-bulkhead {:registry my-registry})
If you want to register this thread pool bulkhead to a ThreadPoolBulkheadRegistry
and you want to use new bulkhead configurations to overwrite the configurations
inherited from the registered ThreadPoolBulkheadRegistry,
you need not only provide the :registry key with the ThreadPoolBulkheadRegistry in config
argument but also provide other bulkhead configurations you'd like to overwrite.
Example:
(bulkhead my-bulkhead {:registry my-registry
:max-wait-millis 50})
If you only want to create a bulkhead and not register it to any
ThreadPoolBulkheadRegistry, you just need to provide bulkhead configurations in config
argument. The name
argument is ignored.
Create a thread pool bulkhead with a `name` and a default or custom configurations. The `name` argument is only used to register this newly created thread pool bulkhead to a ThreadPoolBulkheadRegistry. If you don't want to bind this bulkhead with a ThreadPoolBulkheadRegistry, the `name` argument is ignored. Please refer to `thread-pool-bulkhead-config` for allowed key value pairs within the bulkhead configurations map. If you want to register this thread pool bulkhead to a ThreadPoolBulkheadRegistry, you need to put :registry key with a ThreadPoolBulkheadRegistry in the `config` argument. If you do not provide any other configurations, the newly created bulkhead will inherit bulkhead configurations from this provided ThreadPoolBulkheadRegistry Example: (bulkhead my-bulkhead {:registry my-registry}) If you want to register this thread pool bulkhead to a ThreadPoolBulkheadRegistry and you want to use new bulkhead configurations to overwrite the configurations inherited from the registered ThreadPoolBulkheadRegistry, you need not only provide the :registry key with the ThreadPoolBulkheadRegistry in `config` argument but also provide other bulkhead configurations you'd like to overwrite. Example: (bulkhead my-bulkhead {:registry my-registry :max-wait-millis 50}) If you only want to create a bulkhead and not register it to any ThreadPoolBulkheadRegistry, you just need to provide bulkhead configurations in `config` argument. The `name` argument is ignored.
(config bulkhead)
Get the Metrics of this Bulkhead
Get the Metrics of this Bulkhead
(defbulkhead name)
(defbulkhead name config)
Define a thread pool bulkhead under name
with a default or custom configurations.
Please refer to thread-pool-bulkhead-config
for allowed key value pairs
within the bulkhead configuration.
If you want to register this bulkhead to a ThreadPoolBulkheadRegistry,
you need to put :registry key with a ThreadPoolBulkheadRegistry in the config
argument. If you do not provide any other configurations, the newly created
bulkhead will inherit bulkhead configurations from this
provided ThreadPoolBulkheadRegistry
Example:
(defbulkhead my-bulkhead {:registry my-registry})
If you want to register this bulkhead to a ThreadPoolBulkheadRegistry
and you want to use new bulkhead configurations to overwrite the configurations
inherited from the registered ThreadPoolBulkheadRegistry,
you need not only provide the :registry key with the ThreadPoolBulkheadRegistry in config
argument but also provide other bulkhead configurations you'd like to overwrite.
Example:
(defbulkhead my-bulkhead {:registry my-registry
:max-wait-millis 50})
If you only want to create a bulkhead and not register it to any
ThreadPoolBulkheadRegistry, you just need to provide bulkhead configuration in config
argument without :registry keyword.
Define a thread pool bulkhead under `name` with a default or custom configurations. Please refer to `thread-pool-bulkhead-config` for allowed key value pairs within the bulkhead configuration. If you want to register this bulkhead to a ThreadPoolBulkheadRegistry, you need to put :registry key with a ThreadPoolBulkheadRegistry in the `config` argument. If you do not provide any other configurations, the newly created bulkhead will inherit bulkhead configurations from this provided ThreadPoolBulkheadRegistry Example: (defbulkhead my-bulkhead {:registry my-registry}) If you want to register this bulkhead to a ThreadPoolBulkheadRegistry and you want to use new bulkhead configurations to overwrite the configurations inherited from the registered ThreadPoolBulkheadRegistry, you need not only provide the :registry key with the ThreadPoolBulkheadRegistry in `config` argument but also provide other bulkhead configurations you'd like to overwrite. Example: (defbulkhead my-bulkhead {:registry my-registry :max-wait-millis 50}) If you only want to create a bulkhead and not register it to any ThreadPoolBulkheadRegistry, you just need to provide bulkhead configuration in `config` argument without :registry keyword.
(defregistry name)
(defregistry name config)
Define a ThreadPoolBulkheadRegistry under name
with a default or custom
thread pool bulkhead configuration.
Please refer to thread-pool-bulkhead-config
for allowed key value pairs
within the configuration map.
Define a ThreadPoolBulkheadRegistry under `name` with a default or custom thread pool bulkhead configuration. Please refer to `thread-pool-bulkhead-config` for allowed key value pairs within the configuration map.
(get-all-thread-pool-bulkheads registry)
Get all thread pool bulkhead registered to this thread pool bulkhead registry instance
Get all thread pool bulkhead registered to this thread pool bulkhead registry instance
(metrics bulkhead)
Get the ThreadPoolBulkheadConfig of this Bulkhead
Get the ThreadPoolBulkheadConfig of this Bulkhead
(name bulkhead)
Get the name of this Bulkhead
Get the name of this Bulkhead
(registry-with-config config)
Create a ThreadPoolBulkheadRegistry with a configurations map.
Please refer to thread-pool-bulkhead-config
for allowed key value pairs
within the configuration map.
Create a ThreadPoolBulkheadRegistry with a configurations map. Please refer to `thread-pool-bulkhead-config` for allowed key value pairs within the configuration map.
(set-on-call-finished-event-consumer! bulkhead consumer-fn)
(set-on-call-permitted-event-consumer! bulkhead consumer-fn)
set a consumer to consume on-call-permitted
event which emitted when request permitted by bulkhead.
consumer-fn
accepts a function which takes no arguments.
Please note that in consumer-fn
you can get the bulkhead name and the creation time of the
consumed event by accessing *bulkhead-name*
and *creation-time*
under this namespace.
set a consumer to consume `on-call-permitted` event which emitted when request permitted by bulkhead. `consumer-fn` accepts a function which takes no arguments. Please note that in `consumer-fn` you can get the bulkhead name and the creation time of the consumed event by accessing `*bulkhead-name*` and `*creation-time*` under this namespace.
(set-on-call-rejected-event-consumer! bulkhead consumer-fn)
(submit-callable bulkhead callable)
Submits a value-returning task for execution and returns a Future representing the pending results of the task.
Submits a value-returning task for execution and returns a Future representing the pending results of the task.
(submit-runnable bulkhead runnable)
Submits a task for execution.
Submits a task for execution.
(thread-pool-bulkhead-config opts)
Create a ThreadPoolBulkheadConfig.
Allowed options are:
:max-thread-pool-size Configures the max thread pool size.
:core-thread-pool-size Configures the core thread pool size.
:queue-capacity Configures the capacity of the queue.
:keep-alive-millis When the number of threads is greater than the core, this is the maximum time in milliseconds that excess idle threads will wait for new tasks before terminating.
:writable-stack-trace-enabled Enables writable stack traces. When set to false, Exception#getStackTrace() returns a zero length array. This may be used to reduce log spam when the circuit breaker is open as the cause of the exceptions is already known (the circuit breaker is short-circuiting calls).
Create a ThreadPoolBulkheadConfig. Allowed options are: * :max-thread-pool-size Configures the max thread pool size. * :core-thread-pool-size Configures the core thread pool size. * :queue-capacity Configures the capacity of the queue. * :keep-alive-millis When the number of threads is greater than the core, this is the maximum time in milliseconds that excess idle threads will wait for new tasks before terminating. * :writable-stack-trace-enabled Enables writable stack traces. When set to false, Exception#getStackTrace() returns a zero length array. This may be used to reduce log spam when the circuit breaker is open as the cause of the exceptions is already known (the circuit breaker is short-circuiting calls).
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close