@FunctionalInterface public interface LeaseStrategy
Lease
after a failure.Modifier and Type | Method and Description |
---|---|
static LeaseStrategy |
dropOnError()
Predefined strategy to drop leases on error.
|
static LeaseStrategy |
retainOnError()
Predefined strategy to retain leases on error.
|
static LeaseStrategy |
retainOnIoError()
Predefined strategy to retain leases on I/O errors.
|
boolean |
shouldDrop(Throwable error)
Return true to drop the lease after
error happened. |
boolean shouldDrop(Throwable error)
error
happened.
false to retain the lease.error
- the error that occurred.error
happened.
false to retain the lease.static LeaseStrategy dropOnError()
static LeaseStrategy retainOnError()
static LeaseStrategy retainOnIoError()
Copyright © 2016–2024 Pivotal Software, Inc.. All rights reserved.