apache/seatunnel · warning

Reader {} is not registered. Pending splits {} are not assig

Error message

Reader {} is not registered. Pending splits {} are not assigned.

What it means

IoTDBv2SourceSplitEnumerator.addSplitsBack logs this warning when splits are returned from a reader whose subtask ID is not in context.registeredReaders(); the enumerator keeps them pending and skips immediate assignment. It protects against assigning to readers the coordinator doesn't know about during failover or restore races.

Source

Thrown at seatunnel-connectors-v2/connector-iotdb-v2/src/main/java/org/apache/seatunnel/connectors/seatunnel/iotdbv2/source/IoTDBv2SourceSplitEnumerator.java:195

                query = query + " and ( " + sqlCondition + " ) ";
            }
            if (!Strings.isNullOrEmpty(sqlAlign)) {
                query = query + " align by " + sqlAlign;
            }
            iotDBSourceSplits.add(new IoTDBv2SourceSplit(String.valueOf(query.hashCode()), query));
        }
        return iotDBSourceSplits;
    }

    @Override
    public void addSplitsBack(List<IoTDBv2SourceSplit> splits, int subtaskId) {
        log.debug("Add back splits {} to IoTDBSourceSplitEnumerator.", splits);
        if (!splits.isEmpty()) {
            addPendingSplit(splits, subtaskId);
            if (context.registeredReaders().contains(subtaskId)) {
                assignSplit(Collections.singletonList(subtaskId));
            } else {
                log.warn(
                        "Reader {} is not registered. Pending splits {} are not assigned.",
                        subtaskId,
                        splits);
            }
        }
    }

    @Override
    public int currentUnassignedSplitSize() {
        return pendingSplit.size();
    }

    @Override
    public void registerReader(int subtaskId) {
        log.debug("Register reader {} to IoTDBSourceSplitEnumerator.", subtaskId);
        if (!pendingSplit.isEmpty()) {
            assignSplit(Collections.singletonList(subtaskId));
        }

View on GitHub (pinned to cf67b549a7)

Solutions

  1. No immediate action — splits are pending and assigned after reader registration
  2. Check logs that the reader successfully registers after restart; restart the job if it stays stuck
  3. Stabilize the cluster to avoid repeated reader failovers
  4. Confirm no custom code bypasses the standard reader registration handshake
Defensive patterns

Strategy: fallback

Prevention

When it happens

Trigger: addSplitsBack called for subtaskId before that reader (re)registers with the SourceSplitCoordinator — typical during reader failure recovery or checkpoint restore.

Common situations: Node failure during IoTDB v2 (session-based) reads; job restart from checkpoint with enumerator recovering splits first; slow reader startup relative to coordinator recovery.

Understand the failure class

Background: "Invalid state transition" errors: "status must be X, actually Y", "already rejected/charging/uninstalled", "cannot ... while running" — what they mean when a library rejects your call — this error's family across 31 libraries.

Related errors


AI-assisted analysis of apache/seatunnel@cf67b549a7 (2026-09-10). Data as JSON: /api/errors/0d3f4dc8e9f8aef0. Report an issue: GitHub.