aeron-io/aeron · error · IllegalArgumentException

Invalid retransmit receiver window multiple

Error message

Invalid retransmit receiver window multiple: {rrwm}

What it means

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.

Solutions

  1. Set rrwm to a positive integer (e.g. rrwm:1 or higher) in the option string.
  2. Remove the rrwm: term entirely to use the default retransmit receiver window multiple.
  3. Validate the configured value in code before building the channel URI.
  4. Clamp computed values: Math.max(1, configuredMultiple).

Example fix

// before
String options = "tag=_,fc=tagged,rrwm:0"; // invalid
// after
String options = "tag=_,fc=tagged,rrwm:2"; // positive multiple, or drop rrwm to use default
Defensive patterns

Strategy: validation

Validate before calling

int rrwm = parseRrwm(options);
if (options.contains("rrwm:") && rrwm <= 0) { throw new IllegalArgumentException("rrwm must be > 0, got: " + rrwm); }

Prevention

When it happens

Trigger: 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.

Common situations: 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.

Understand the failure class

Background: "Invalid value" and "allowed values are" config errors: what your library rejected and how to fix it — this error's family across 41 libraries.

Related errors


AI-assisted analysis of aeron-io/aeron@6d60124e15 (2026-09-12). Data as JSON: /api/errors/ca09cce63ffe9437. Report an issue: GitHub.

Appendix: source

Thrown at aeron-driver/src/main/java/io/aeron/driver/FlowControl.java:78

     *
     * @param udpChannel for the stream.
     * @param defaultRetransmitReceiverWindowMultiple window multiple to use when one is not set in the URI.
     * @return receiver window multiple.
     */
    static int retransmitReceiverWindowMultiple(
        final UdpChannel udpChannel, final int defaultRetransmitReceiverWindowMultiple)
    {
        final String fcValue = udpChannel.channelUri().get(CommonContext.FLOW_CONTROL_PARAM_NAME);
        if (fcValue != null)
        {
            for (final String arg : fcValue.split(","))
            {
                if (arg.startsWith("rrwm:"))
                {
                    final int rrwm = Integer.parseInt(arg.substring("rrwm:".length()));
                    if (rrwm <= 0)
                    {
                        throw new IllegalArgumentException("Invalid retransmit receiver window multiple: " + rrwm);
                    }
                    return rrwm;
                }
            }
        }
        return defaultRetransmitReceiverWindowMultiple;
    }

    /**
     * Update the sender flow control strategy based on a status message from the receiver.
     *
     * @param flyweight           over the status message received.
     * @param receiverAddress     of the receiver.
     * @param senderLimit         the current sender position limit.
     * @param initialTermId       for the term buffers.
     * @param positionBitsToShift in use for the length of each term buffer.
     * @param timeNs              current time (in nanoseconds).
     * @return the new position limit to be employed by the sender.

View on GitHub (pinned to 6d60124e15)