{"record":{"id":"694d720eba331c20","repo":"apache/seatunnel","slug":"api-01","errorCode":"API-01","errorMessage":"PluginName: %s, Message: not support batch job mode","messagePattern":"PluginName: (.+?), Message: not support batch job mode","errorType":"error_code","errorClass":"RabbitmqConnectorException","httpStatus":null,"severity":"error","filePath":"seatunnel-connectors-v2/connector-rabbitmq/src/main/java/org/apache/seatunnel/connectors/seatunnel/rabbitmq/source/RabbitmqSource.java","lineNumber":103,"sourceCode":"\n                this.catalogTables.add(table);\n                this.queueToTableMap.put(queueName, table);\n            }\n        } else if (hasSchema) {\n            CatalogTable table = CatalogTableUtil.buildWithConfig(config);\n            String queueName = config.get(RabbitmqBaseOptions.QUEUE_NAME);\n            if (queueName == null) {\n                queueName = rabbitmqConfig.getQueueName();\n            }\n            this.catalogTables.add(table);\n            this.queueToTableMap.put(queueName, table);\n        }\n    }\n\n    @Override\n    public Boundedness getBoundedness() {\n        if (jobContext != null && !JobMode.STREAMING.equals(jobContext.getJobMode())) {\n            throw new RabbitmqConnectorException(\n                    SeaTunnelAPIErrorCode.CONFIG_VALIDATION_FAILED,\n                    String.format(\n                            \"PluginName: %s, Message: not support batch job mode\",\n                            getPluginName()));\n        }\n        return rabbitmqConfig.isForE2ETesting() ? Boundedness.BOUNDED : Boundedness.UNBOUNDED;\n    }\n\n    @Override\n    public String getPluginName() {\n        return \"RabbitMQ\";\n    }\n\n    @Override\n    public List<CatalogTable> getProducedCatalogTables() {\n        return catalogTables;\n    }\n","sourceCodeStart":85,"sourceCodeEnd":121,"githubUrl":"https://github.com/apache/seatunnel/blob/cf67b549a7a6c35fa0beb12d83c62892427ea919/seatunnel-connectors-v2/connector-rabbitmq/src/main/java/org/apache/seatunnel/connectors/seatunnel/rabbitmq/source/RabbitmqSource.java#L85-L121","documentation":"RabbitmqSource.getBoundedness throws RabbitmqConnectorException(CONFIG_VALIDATION_FAILED) when the job mode is not STREAMING. The RabbitMQ source is streaming-only; it rejects batch jobs by checking jobContext.getJobMode() during boundedness resolution.","triggerScenarios":"Submitting a SeaTunnel job with mode = BATCH (or default batch mode) that uses the RabbitMQ source; getBoundedness is called during job planning by the enumerator/validation logic.","commonSituations":"User runs `seatunnel.sh --config job.conf -e local` without `job.mode = \"streaming\"`; template configs default to batch; scheduled batch pipeline reused with RabbitMQ source added later.","solutions":["Set `job.mode = \"streaming\"` in the env block of the job config","If a bounded test run is needed, use the connector's E2E-testing bounded option instead of batch mode","Switch to a connector that supports batch mode if a one-shot read is required"],"exampleFix":"// before\nenv {\n  job.mode = \"BATCH\"\n}\nsource { RabbitMQ { ... } }\n// after\nenv {\n  job.mode = \"STREAMING\"\n}\nsource { RabbitMQ { ... } }","handlingStrategy":"validation","validationCode":"String mode = jobConfig.getOrDefault(\"job.mode\", \"batch\");\nif (!\"streaming\".equalsIgnoreCase(mode)) {\n  throw new IllegalArgumentException(\"RabbitMQ source requires job.mode = streaming\");\n}","typeGuard":null,"tryCatchPattern":"try {\n  Boundedness b = source.getBoundedness();\n} catch (RabbitmqConnectorException e) {\n  if (e.getMessage() != null && e.getMessage().contains(\"not support batch job mode\")) {\n    System.err.println(\"Set job.mode = STREAMING in the env block\");\n  } else {\n    throw e;\n  }\n}","preventionTips":["Always set `job.mode = \"streaming\"` in env when using the RabbitMQ source","Remember `-e local` runs default batch unless job.mode overrides it","Use the E2E bounded option only for test scenarios"],"tags":["rabbitmq","job-mode","boundedness","validation"],"backgroundTag":"unsupported-operation","analyzedSha":"cf67b549a7a6c35fa0beb12d83c62892427ea919","analyzedAt":"2026-09-10T21:44:55.265Z","contentChangedAt":"2026-09-10T21:44:55.265Z","schemaVersion":2},"datasetVersion":"2026-09-23T08:17:48.524Z"}