Record Class InMemorySchedulerOptions
java.lang.Object
java.lang.Record
org.j7m.middleware.scheduler.InMemorySchedulerOptions
- Record Components:
schedulerId- scheduler idruntimeId- hosting runtime idregistryContext- registry contextclock- scheduler clocksecurity- security configuration used for authorization and resource policymaxTasks- maximum retained tasksmaxConcurrentExecutions- maximum concurrently executing tasksstreamBufferSize- bounded stream buffer sizemaxStreamItemBytes- maximum approximate stream item sizedefaultLeaseDuration- default lease duration
public record InMemorySchedulerOptions(String schedulerId, String runtimeId, String registryContext, Clock clock, org.j7m.middleware.security.api.SecurityConfiguration security, int maxTasks, int maxConcurrentExecutions, int streamBufferSize, int maxStreamItemBytes, Duration defaultLeaseDuration)
extends Record
Immutable options for
InMemoryWorkloadScheduler.-
Constructor Summary
ConstructorsConstructorDescriptionInMemorySchedulerOptions(String schedulerId, String runtimeId, String registryContext, Clock clock, org.j7m.middleware.security.api.SecurityConfiguration security, int maxTasks, int maxConcurrentExecutions, int streamBufferSize, int maxStreamItemBytes, Duration defaultLeaseDuration) Creates validated options. -
Method Summary
Modifier and TypeMethodDescriptionclock()Returns the value of theclockrecord component.Returns the value of thedefaultLeaseDurationrecord component.intReturns the finite payload limit applied when a task submission leavesTaskOptions.maxPayloadBytes()at zero.static InMemorySchedulerOptionsReturns conservative development defaults.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.intReturns the maximum aggregate UTF-8 byte length retained for fan-out and scatter-gather response values and failure metadata.intReturns the maximum aggregate UTF-8 byte length retained for checkpoint metadata.intReturns the value of themaxConcurrentExecutionsrecord component.intReturns the maximum number of fan-out or scatter-gather targets accepted in one request.intReturns the maximum number of metadata entries accepted by scheduler admission, progress, checkpoint, result, and fan-out paths.intReturns the maximum UTF-8 byte length accepted for one metadata key or value.intReturns the maximum UTF-8 byte length accepted for a progress message.intReturns the maximum number of successful or failed fan-out results retained in one response.intReturns the value of themaxStreamItemBytesrecord component.intmaxTasks()Returns the value of themaxTasksrecord component.Returns the value of theregistryContextrecord component.Returns the value of theruntimeIdrecord component.Returns the value of theschedulerIdrecord component.org.j7m.middleware.security.api.SecurityConfigurationsecurity()Returns the value of thesecurityrecord component.intReturns the value of thestreamBufferSizerecord component.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
InMemorySchedulerOptions
public InMemorySchedulerOptions(String schedulerId, String runtimeId, String registryContext, Clock clock, org.j7m.middleware.security.api.SecurityConfiguration security, int maxTasks, int maxConcurrentExecutions, int streamBufferSize, int maxStreamItemBytes, Duration defaultLeaseDuration) Creates validated options.
-
-
Method Details
-
defaults
Returns conservative development defaults.- Parameters:
schedulerId- scheduler idruntimeId- runtime id- Returns:
- options
-
maxMetadataEntries
public int maxMetadataEntries()Returns the maximum number of metadata entries accepted by scheduler admission, progress, checkpoint, result, and fan-out paths.- Returns:
- metadata entry limit
-
maxMetadataValueBytes
public int maxMetadataValueBytes()Returns the maximum UTF-8 byte length accepted for one metadata key or value.- Returns:
- per-string metadata byte limit
-
maxProgressMessageBytes
public int maxProgressMessageBytes()Returns the maximum UTF-8 byte length accepted for a progress message.- Returns:
- progress message byte limit
-
maxCheckpointMetadataBytes
public int maxCheckpointMetadataBytes()Returns the maximum aggregate UTF-8 byte length retained for checkpoint metadata.- Returns:
- checkpoint metadata byte limit
-
maxFanOutTargets
public int maxFanOutTargets()Returns the maximum number of fan-out or scatter-gather targets accepted in one request.- Returns:
- target count limit
-
maxRetainedFanOutResults
public int maxRetainedFanOutResults()Returns the maximum number of successful or failed fan-out results retained in one response.- Returns:
- retained result limit
-
maxAggregateResultBytes
public int maxAggregateResultBytes()Returns the maximum aggregate UTF-8 byte length retained for fan-out and scatter-gather response values and failure metadata.- Returns:
- aggregate result byte limit
-
defaultMaxPayloadBytes
public int defaultMaxPayloadBytes()Returns the finite payload limit applied when a task submission leavesTaskOptions.maxPayloadBytes()at zero.The API default remains source compatible with earlier callers, but scheduler admission treats zero as this bounded implementation default rather than as an unbounded payload allowance.
- Returns:
- default payload byte limit
-
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. -
schedulerId
Returns the value of theschedulerIdrecord component.- Returns:
- the value of the
schedulerIdrecord component
-
runtimeId
-
registryContext
Returns the value of theregistryContextrecord component.- Returns:
- the value of the
registryContextrecord component
-
clock
-
security
-
maxTasks
-
maxConcurrentExecutions
public int maxConcurrentExecutions()Returns the value of themaxConcurrentExecutionsrecord component.- Returns:
- the value of the
maxConcurrentExecutionsrecord component
-
streamBufferSize
public int streamBufferSize()Returns the value of thestreamBufferSizerecord component.- Returns:
- the value of the
streamBufferSizerecord component
-
maxStreamItemBytes
public int maxStreamItemBytes()Returns the value of themaxStreamItemBytesrecord component.- Returns:
- the value of the
maxStreamItemBytesrecord component
-
defaultLeaseDuration
Returns the value of thedefaultLeaseDurationrecord component.- Returns:
- the value of the
defaultLeaseDurationrecord component
-