Record Class UpgradeOptions
java.lang.Object
java.lang.Record
org.j7m.middleware.deployer.api.UpgradeOptions
- Record Components:
strategy- upgrade strategyrollingBatchSize- number of local bindings to replace per rolling stepcanaryInvocations- number of deterministic canary test invocationscanarySuccessThreshold- required canary successes before promotionretainPrevious- whether previous version may remain available for rollback
-
Constructor Summary
ConstructorsConstructorDescriptionUpgradeOptions(String strategy) Compatibility constructor using conservative defaults.UpgradeOptions(String strategy, int rollingBatchSize, int canaryInvocations, int canarySuccessThreshold, boolean retainPrevious) Creates immutable upgrade options. -
Method Summary
Modifier and TypeMethodDescriptionstatic UpgradeOptionsCreates blue-green upgrade options.static UpgradeOptionsCreates deterministic canary-baseline upgrade options.intReturns the value of thecanaryInvocationsrecord component.intReturns the value of thecanarySuccessThresholdrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.booleanReturns the value of theretainPreviousrecord component.static UpgradeOptionsrolling()Creates rolling upgrade options.intReturns the value of therollingBatchSizerecord component.static UpgradeOptionsReturns stop-start upgrade options.strategy()Returns the value of thestrategyrecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
UpgradeOptions
public UpgradeOptions(String strategy, int rollingBatchSize, int canaryInvocations, int canarySuccessThreshold, boolean retainPrevious) Creates immutable upgrade options. -
UpgradeOptions
Compatibility constructor using conservative defaults.- Parameters:
strategy- upgrade strategy
-
-
Method Details
-
stopStart
Returns stop-start upgrade options.- Returns:
- stop-start options
-
rolling
Creates rolling upgrade options.- Returns:
- rolling upgrade options
-
blueGreen
Creates blue-green upgrade options.- Returns:
- blue-green upgrade options
-
canaryBaseline
Creates deterministic canary-baseline upgrade options.- Returns:
- canary-baseline options
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
strategy
-
rollingBatchSize
public int rollingBatchSize()Returns the value of therollingBatchSizerecord component.- Returns:
- the value of the
rollingBatchSizerecord component
-
canaryInvocations
public int canaryInvocations()Returns the value of thecanaryInvocationsrecord component.- Returns:
- the value of the
canaryInvocationsrecord component
-
canarySuccessThreshold
public int canarySuccessThreshold()Returns the value of thecanarySuccessThresholdrecord component.- Returns:
- the value of the
canarySuccessThresholdrecord component
-
retainPrevious
public boolean retainPrevious()Returns the value of theretainPreviousrecord component.- Returns:
- the value of the
retainPreviousrecord component
-