{"record":{"id":"1b2d4e56b88ea7bd","repo":"aeron-io/aeron","slug":"untetheredrestingtimeoutns-untetheredrestingtimeoutns","errorCode":null,"errorMessage":"untetheredRestingTimeoutNs=${untetheredRestingTimeoutNs} <= timerIntervalNs=${timerIntervalNs}","messagePattern":"untetheredRestingTimeoutNs=(.+?) <= timerIntervalNs=(.+?)","errorType":"validation","errorClass":"ConfigurationException","httpStatus":null,"severity":"error","filePath":"aeron-driver/src/main/java/io/aeron/driver/Configuration.java","lineNumber":2635,"sourceCode":"     * @param timerIntervalNs                interval at which the driver will check timeouts.\n     * @throws ConfigurationException if the values are not valid.\n     */\n    public static void validateUntetheredTimeouts(\n        final long untetheredWindowLimitTimeoutNs,\n        final long untetheredLingerTimeoutNs,\n        final long untetheredRestingTimeoutNs,\n        final long timerIntervalNs)\n    {\n        if (untetheredWindowLimitTimeoutNs <= timerIntervalNs)\n        {\n            throw new ConfigurationException(\n                \"untetheredWindowLimitTimeoutNs=\" + untetheredWindowLimitTimeoutNs +\n                \" <= timerIntervalNs=\" + timerIntervalNs);\n        }\n\n        if (untetheredRestingTimeoutNs <= timerIntervalNs)\n        {\n            throw new ConfigurationException(\n                \"untetheredRestingTimeoutNs=\" + untetheredRestingTimeoutNs +\n                \" <= timerIntervalNs=\" + timerIntervalNs);\n        }\n\n        if (Aeron.NULL_VALUE != untetheredLingerTimeoutNs && untetheredLingerTimeoutNs <= timerIntervalNs)\n        {\n            throw new ConfigurationException(\n                \"untetheredLingerTimeoutNs=\" + untetheredLingerTimeoutNs +\n                    \" <= timerIntervalNs=\" + timerIntervalNs);\n        }\n    }\n\n    /**\n     * Create a source identity for a given source address.\n     *\n     * @param srcAddress to be used for the identity.\n     * @return a source identity string for a given address.\n     */","sourceCodeStart":2617,"sourceCodeEnd":2653,"githubUrl":"https://github.com/aeron-io/aeron/blob/6d60124e15e35c11b49ba2e3c2c2858a09a18803/aeron-driver/src/main/java/io/aeron/driver/Configuration.java#L2617-L2653","documentation":"Configuration.validateUntetheredTimeouts also requires the untethered resting timeout to be strictly greater than the driver timer interval, ensuring the resting state of an untethered subscription is evaluated on a sane timescale. A ConfigurationException is thrown when untetheredRestingTimeoutNs <= timerIntervalNs.","triggerScenarios":"Calling validateUntetheredTimeouts with aeron.untethered.resting.timeout <= aeron.timer.interval, e.g. restingTimeout=200ms with timerInterval=1s.","commonSituations":"Tuning resting timeout very low for quick reactivation of untethered subscriptions; timer interval raised for CPU savings; config assembled from mixed sources.","solutions":["Raise aeron.untethered.resting.timeout so it is strictly greater than aeron.timer.interval","Or decrease aeron.timer.interval","Verify ordering: timerInterval < windowLimitTimeout, timerInterval < restingTimeout, and (if set) timerInterval < lingerTimeout"],"exampleFix":"// before\nctx.timerIntervalNs(TimeUnit.SECONDS.toNanos(1));\nctx.untetheredRestingTimeoutNs(TimeUnit.MILLISECONDS.toNanos(200));\n// after\nctx.timerIntervalNs(TimeUnit.SECONDS.toNanos(1));\nctx.untetheredRestingTimeoutNs(TimeUnit.SECONDS.toNanos(10)); // > timerInterval","handlingStrategy":"validation","validationCode":"long timer = TimeUnit.MILLISECONDS.toNanos(100);\nlong resting = TimeUnit.SECONDS.toNanos(10);\nif (resting <= timer) throw new IllegalStateException(\"untetheredRestingTimeout must be > timerInterval\");\nio.aeron.driver.Configuration.validateUntetheredTimeouts(windowLimitTimeout, resting, lingerTimeout, timer);","typeGuard":null,"tryCatchPattern":"try {\n    ctx.conclude();\n} catch (ConfigurationException e) {\n    if (e.getMessage().contains(\"untetheredRestingTimeoutNs\")) {\n        ctx.untetheredRestingTimeoutNs(ctx.timerIntervalNs() * 100);\n        ctx.conclude();\n    } else { throw e; }\n}","preventionTips":["Keep resting timeout much larger than the timer interval (default is ~ seconds vs ~100ms ticks)","Re-validate all untethered timeouts as a set after any change","Add a startup self-check that concludes DriverContext in a test with production properties"],"tags":["aeron","configuration","timeout","untethered-subscription"],"backgroundTag":"conflicting-config-options","analyzedSha":"6d60124e15e35c11b49ba2e3c2c2858a09a18803","analyzedAt":"2026-09-12T11:17:07.683Z","contentChangedAt":"2026-09-12T11:17:07.683Z","schemaVersion":2},"datasetVersion":"2026-09-19T12:17:13.211Z"}