Record Class ManagedProbeSettings
java.lang.Object
java.lang.Record
org.j7m.middleware.application.components.ManagedProbeSettings
- Record Components:
maximumConcurrent- physically running callbacks,1..64maximumRegistrations- monitored activations,1..1024interval- sampling delay, positive and at most one minutebudget- per-activation inspection wait, positive and at most one minutefreshness- observation validity, one millisecond through one minute
public record ManagedProbeSettings(int maximumConcurrent, int maximumRegistrations, Duration interval, Duration budget, Duration freshness)
extends Record
Trusted host configuration for automatic managed probes; never application-selected policy.
Bounds apply to one manager's physical workers and activation registrations. Sampling uses a
shared monotonic per-activation budget, and export readiness must expire after freshness.
-
Constructor Summary
ConstructorsConstructorDescriptionManagedProbeSettings(int maximumConcurrent, int maximumRegistrations, Duration interval, Duration budget, Duration freshness) Validates finite capacities and intervals without starting workers. -
Method Summary
Modifier and TypeMethodDescriptionbudget()Returns the value of thebudgetrecord component.static ManagedProbeSettingsdefaults()Returns the bounded development profile: four workers,64 activations,100ms sampling/wait, and two-second observation validity.final booleanIndicates whether some other object is "equal to" this one.Returns the value of thefreshnessrecord component.final inthashCode()Returns a hash code value for this object.interval()Returns the value of theintervalrecord component.intReturns the value of themaximumConcurrentrecord component.intReturns the value of themaximumRegistrationsrecord component.Creates a new owned monitor honoring these settings; the caller owns its cleanup.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ManagedProbeSettings
public ManagedProbeSettings(int maximumConcurrent, int maximumRegistrations, Duration interval, Duration budget, Duration freshness) Validates finite capacities and intervals without starting workers.- Parameters:
maximumConcurrent- physical callback boundmaximumRegistrations- activation registration boundinterval- sampling delaybudget- total inspection waitfreshness- observation validity- Throws:
IllegalArgumentException- for an out-of-range valueNullPointerException- for a null duration
-
-
Method Details
-
defaults
Returns the bounded development profile: four workers,64 activations,100ms sampling/wait, and two-second observation validity. Hosts can install a different validated profile.- Returns:
- immutable default host settings
-
newMonitor
Creates a new owned monitor honoring these settings; the caller owns its cleanup.- Returns:
- new monitor with no registered applications
-
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. -
maximumConcurrent
public int maximumConcurrent()Returns the value of themaximumConcurrentrecord component.- Returns:
- the value of the
maximumConcurrentrecord component
-
maximumRegistrations
public int maximumRegistrations()Returns the value of themaximumRegistrationsrecord component.- Returns:
- the value of the
maximumRegistrationsrecord component
-
interval
-
budget
-
freshness
-