{"record":{"id":"ad5d9e665a2ffe99","repo":"apache/pulsar","slug":"this-broker-is-not-configured-with-transactioncoor","errorCode":null,"errorMessage":"This Broker is not configured with transactionCoordinatorEnabled=true.","messagePattern":"This Broker is not configured with transactionCoordinatorEnabled=true\\.","errorType":"http","errorClass":"RestException","httpStatus":503,"severity":"error","filePath":"pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/TransactionsBase.java","lineNumber":523,"sourceCode":"            CompletableFuture<Optional<Topic>> topicFuture = pulsar().getBrokerService()\n                    .getTopics().get(topicName.toString());\n            if (topicFuture == null) {\n                return FutureUtil.failedFuture(new RestException(NOT_FOUND,\n                        String.format(\"Topic not found %s\", topicName.toString())));\n            }\n            return topicFuture.thenCompose(optionalTopic -> {\n                if (!optionalTopic.isPresent()) {\n                    return FutureUtil.failedFuture(new RestException(NOT_FOUND,\n                            String.format(\"Topic not found %s\", topicName.toString())));\n                }\n                return CompletableFuture.completedFuture((PersistentTopic) optionalTopic.get());\n            });\n        });\n    }\n\n    protected void checkTransactionCoordinatorEnabled() {\n        if (!pulsar().getConfig().isTransactionCoordinatorEnabled()) {\n           throw new RestException(SERVICE_UNAVAILABLE,\n                    \"This Broker is not configured with transactionCoordinatorEnabled=true.\");\n        }\n    }\n\n    protected void validateTopicName(String tenant, String namespace, String encodedTopic) {\n        String topic = Codec.decode(encodedTopic);\n        try {\n            this.namespaceName = NamespaceName.get(tenant, namespace);\n            this.topicName = TopicName.get(TopicDomain.persistent.toString(), namespaceName, topic);\n        } catch (IllegalArgumentException e) {\n            log.warn()\n                    .attr(\"domain\", domain())\n                    .attr(\"tenant\", tenant)\n                    .attr(\"namespace\", namespace)\n                    .attr(\"topic\", topic)\n                    .exception(e)\n                    .log(\"Failed to validate topic name\");\n            throw new RestException(Response.Status.PRECONDITION_FAILED, \"Topic name is not valid\");","sourceCodeStart":505,"sourceCodeEnd":541,"githubUrl":"https://github.com/apache/pulsar/blob/820761864ed8e2a7d2e52dd9763ad2ae117c1395/pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/TransactionsBase.java#L505-L541","documentation":"HTTP 503 SERVICE_UNAVAILABLE from checkTransactionCoordinatorEnabled: the broker is not configured with transactionCoordinatorEnabled=true, so all transaction coordinator admin endpoints refuse to operate. It is a configuration guard, not a transient outage.","triggerScenarios":"Calling any TransactionsBase admin endpoint (e.g. /admin/v3/transaction/coordinatorScaleCoordinator/{replicas}, coordinator stats) on a broker where transactionCoordinatorEnabled is false (the default).","commonSituations":"Enabling transactions only on clients but forgetting broker config; hitting the wrong broker in a mixed cluster where only some brokers enable transactions; upgrading an environment and transactions config not carried over.","solutions":["Set transactionCoordinatorEnabled=true in broker.conf (or via environment variable PULSAR_PREFIX_transactionCoordinatorEnabled for k8s) and restart the broker.","Confirm the request targets a broker/cluster with transactions enabled; check GET /admin/v2/brokers/configuration.","If transactions are not needed, stop calling the transaction coordinator admin endpoints."],"exampleFix":"// broker.conf before\n# transactionCoordinatorEnabled not set (defaults to false)\n// after\ntransactionCoordinatorEnabled=true","handlingStrategy":"validation","validationCode":"// Check broker config before using transaction admin APIs\nboolean txEnabled = admin.brokers().getRuntimeConfigurations().entrySet().stream()\n    .anyMatch(e -> e.getKey().equals(\"transactionCoordinatorEnabled\")\n        && Boolean.parseBoolean(String.valueOf(e.getValue())));\nif (!txEnabled) {\n    throw new IllegalStateException(\"Broker must set transactionCoordinatorEnabled=true\");\n}","typeGuard":null,"tryCatchPattern":"try {\n    admin.transactions().scaleTransactionCoordinators(replicas);\n} catch (PulsarAdminException e) {\n    if (e.getStatusCode() == 503) {\n        throw new IllegalStateException(\"Enable transactionCoordinatorEnabled=true on the broker\", e);\n    }\n    throw e;\n}","preventionTips":["Set transactionCoordinatorEnabled=true in broker.conf wherever transactions are used.","Keep broker configs consistent across the cluster to avoid hitting non-transactional brokers.","Verify via GET /admin/v2/brokers/configuration before calling transaction endpoints.","Enable transaction-related config for k8s via PULSAR_PREFIX_ environment variables."],"tags":["configuration","transactions","rest-api","broker"],"backgroundTag":"feature-not-enabled-config","analyzedSha":"820761864ed8e2a7d2e52dd9763ad2ae117c1395","analyzedAt":"2026-09-06T00:14:20.138Z","contentChangedAt":"2026-09-06T00:14:20.138Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}