{"record":{"id":"ca09cce63ffe9437","repo":"aeron-io/aeron","slug":"invalid-retransmit-receiver-window-multiple-rrwm","errorCode":null,"errorMessage":"Invalid retransmit receiver window multiple: {rrwm}","messagePattern":"Invalid retransmit receiver window multiple: (.+?)","errorType":"exception","errorClass":"IllegalArgumentException","httpStatus":null,"severity":"error","filePath":"aeron-driver/src/main/java/io/aeron/driver/FlowControl.java","lineNumber":78,"sourceCode":"     *\n     * @param udpChannel for the stream.\n     * @param defaultRetransmitReceiverWindowMultiple window multiple to use when one is not set in the URI.\n     * @return receiver window multiple.\n     */\n    static int retransmitReceiverWindowMultiple(\n        final UdpChannel udpChannel, final int defaultRetransmitReceiverWindowMultiple)\n    {\n        final String fcValue = udpChannel.channelUri().get(CommonContext.FLOW_CONTROL_PARAM_NAME);\n        if (fcValue != null)\n        {\n            for (final String arg : fcValue.split(\",\"))\n            {\n                if (arg.startsWith(\"rrwm:\"))\n                {\n                    final int rrwm = Integer.parseInt(arg.substring(\"rrwm:\".length()));\n                    if (rrwm <= 0)\n                    {\n                        throw new IllegalArgumentException(\"Invalid retransmit receiver window multiple: \" + rrwm);\n                    }\n                    return rrwm;\n                }\n            }\n        }\n        return defaultRetransmitReceiverWindowMultiple;\n    }\n\n    /**\n     * Update the sender flow control strategy based on a status message from the receiver.\n     *\n     * @param flyweight           over the status message received.\n     * @param receiverAddress     of the receiver.\n     * @param senderLimit         the current sender position limit.\n     * @param initialTermId       for the term buffers.\n     * @param positionBitsToShift in use for the length of each term buffer.\n     * @param timeNs              current time (in nanoseconds).\n     * @return the new position limit to be employed by the sender.","sourceCodeStart":60,"sourceCodeEnd":96,"githubUrl":"https://github.com/aeron-io/aeron/blob/6d60124e15e35c11b49ba2e3c2c2858a09a18803/aeron-driver/src/main/java/io/aeron/driver/FlowControl.java#L60-L96","documentation":"Thrown when parsing flow-control options: the rrwm (retransmit receiver window multiple) argument is present but its value is <= 0. rrwm must be a positive integer controlling how many receiver window lengths a retransmit may span, so zero or negative values are rejected as invalid.","triggerScenarios":"Configuring flow control via channel URI or context option with 'rrwm:0' or a negative value, e.g. aeron.channel.enable_RETRANSMIT info in the FC/ICC option string parsed by FlowControl.parse recipe.","commonSituations":"Typo where a default/0 value was intended to mean 'disabled'; computing the multiple programmatically with an uninitialized variable; misunderstanding that rrwm must be >= 1.","solutions":["Set rrwm to a positive integer (e.g. rrwm:1 or higher) in the option string.","Remove the rrwm: term entirely to use the default retransmit receiver window multiple.","Validate the configured value in code before building the channel URI.","Clamp computed values: Math.max(1, configuredMultiple)."],"exampleFix":"// before\nString options = \"tag=_,fc=tagged,rrwm:0\"; // invalid\n// after\nString options = \"tag=_,fc=tagged,rrwm:2\"; // positive multiple, or drop rrwm to use default","handlingStrategy":"validation","validationCode":"int rrwm = parseRrwm(options);\nif (options.contains(\"rrwm:\") && rrwm <= 0) { throw new IllegalArgumentException(\"rrwm must be > 0, got: \" + rrwm); }","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Never emit 'rrwm:0'; omit the term to use defaults","Clamp programmatic values with Math.max(1, value)","Unit-test flow-control option string builders"],"tags":["aeron","config","flow-control","validation"],"backgroundTag":"invalid-config-value","analyzedSha":"6d60124e15e35c11b49ba2e3c2c2858a09a18803","analyzedAt":"2026-09-12T11:17:07.683Z","contentChangedAt":"2026-09-12T11:17:07.683Z","schemaVersion":2},"datasetVersion":"2026-09-16T04:17:20.429Z"}