Bulkhead.EventPublisher, Bulkhead.Metrics| Constructor and Description |
|---|
SemaphoreBulkhead(java.lang.String name)
Creates a bulkhead with a default config.
|
SemaphoreBulkhead(java.lang.String name,
BulkheadConfig bulkheadConfig)
Creates a bulkhead using a configuration supplied
|
SemaphoreBulkhead(java.lang.String name,
java.util.function.Supplier<BulkheadConfig> configSupplier)
Create a bulkhead using a configuration supplier
|
| Modifier and Type | Method and Description |
|---|---|
void |
changeConfig(BulkheadConfig newConfig)
Dynamic bulkhead configuration change.
|
BulkheadConfig |
getBulkheadConfig()
Returns the BulkheadConfig of this Bulkhead.
|
Bulkhead.EventPublisher |
getEventPublisher()
Returns an EventPublisher which subscribes to the reactive stream of BulkheadEvent and
can be used to register event consumers.
|
Bulkhead.Metrics |
getMetrics()
Get the Metrics of this Bulkhead.
|
java.lang.String |
getName()
Returns the name of this bulkhead.
|
boolean |
isCallPermitted()
Attempts to acquire a permit, which allows an call to be executed.
|
void |
onComplete()
Records a completed call.
|
java.lang.String |
toString() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitdecorateCallable, decorateCheckedConsumer, decorateCheckedFunction, decorateCheckedRunnable, decorateCheckedSupplier, decorateCompletionStage, decorateConsumer, decorateFunction, decorateRunnable, decorateSupplier, executeCallable, executeCheckedSupplier, executeCompletionStage, executeRunnable, executeSupplier, of, of, ofDefaultspublic SemaphoreBulkhead(java.lang.String name,
@Nullable
BulkheadConfig bulkheadConfig)
name - the name of this bulkheadbulkheadConfig - custom bulkhead configurationpublic SemaphoreBulkhead(java.lang.String name)
name - the name of this bulkheadpublic SemaphoreBulkhead(java.lang.String name,
java.util.function.Supplier<BulkheadConfig> configSupplier)
name - the name of this bulkheadconfigSupplier - BulkheadConfig supplierpublic void changeConfig(BulkheadConfig newConfig)
changeConfig in interface BulkheadnewConfig - new BulkheadConfigpublic boolean isCallPermitted()
isCallPermitted in interface Bulkheadpublic void onComplete()
onComplete in interface Bulkheadpublic java.lang.String getName()
public BulkheadConfig getBulkheadConfig()
getBulkheadConfig in interface Bulkheadpublic Bulkhead.Metrics getMetrics()
getMetrics in interface Bulkheadpublic Bulkhead.EventPublisher getEventPublisher()
getEventPublisher in interface Bulkheadpublic java.lang.String toString()
toString in class java.lang.Object