{"record":{"id":"cc6217685b00c3d3","repo":"apache/pulsar","slug":"replicator-not-found","errorCode":null,"errorMessage":"Replicator not found","messagePattern":"Replicator not found","errorType":"http","errorClass":"RestException","httpStatus":404,"severity":"error","filePath":"pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/PersistentTopicsBase.java","lineNumber":4766,"sourceCode":"                                if (ex != null || createdSubscription == null) {\n                                    throw new RestException(Status.NOT_FOUND,\n                                            getSubNotFoundErrorMessage(topicName.toString(), subName));\n                                }\n                                return createdSubscription;\n                            });\n                });\n    }\n\n    /**\n     * Get the Replicator object reference from the Topic reference.\n     */\n    private PersistentReplicator getReplicatorReference(String replName, PersistentTopic topic) {\n        try {\n            String remoteCluster = PersistentReplicator.getRemoteCluster(replName);\n            PersistentReplicator repl = (PersistentReplicator) topic.getPersistentReplicator(remoteCluster);\n            return checkNotNull(repl);\n        } catch (Exception e) {\n            throw new RestException(Status.NOT_FOUND, \"Replicator not found\");\n        }\n    }\n\n    // as described at : (PR: #836) CPP-client old client lib should not be allowed to connect on partitioned-topic.\n    // So, all requests from old-cpp-client (< v1.21) must be rejected.\n    // Pulsar client-java lib always passes user-agent as X-Java-$version.\n    // However, cpp-client older than v1.20 (PR #765) never used to pass it.\n    // So, request without user-agent and Pulsar-CPP-vX (X < 1.21) must be rejected\n    protected CompletableFuture<Void> internalValidateClientVersionAsync() {\n        if (!pulsar().getConfiguration().isClientLibraryVersionCheckEnabled()) {\n            return CompletableFuture.completedFuture(null);\n        }\n        final String userAgent = httpRequest.getHeader(\"User-Agent\");\n        if (StringUtils.isBlank(userAgent)) {\n            return FutureUtil.failedFuture(new RestException(Status.METHOD_NOT_ALLOWED,\n                    \"Client lib is not compatible to\"\n                            + \" access partitioned metadata: version in user-agent is not present\"));\n        }","sourceCodeStart":4748,"sourceCodeEnd":4784,"githubUrl":"https://github.com/apache/pulsar/blob/820761864ed8e2a7d2e52dd9763ad2ae117c1395/pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/PersistentTopicsBase.java#L4748-L4784","documentation":"Admin API sentinel used when a topic's replicator lookup fails: getReplicatorReference throws (or returns null triggering this error) because no replicator with the given remote cluster name exists on the persistent topic — typically the cluster was never configured as a replication cluster for the namespace, or the replicator was deleted.","triggerScenarios":"Thrown at pulsar-broker/src/main/java/org/apache/pulsar/broker/admin/impl/PersistentTopicsBase.java:4766 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Verify the cluster is in the namespace's replicationClusters","Check the replication producer/replicator state in topic stats before operating on it"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"820761864ed8e2a7d2e52dd9763ad2ae117c1395","analyzedAt":"2026-09-06T00:14:20.138Z","contentChangedAt":"2026-09-06T00:14:20.138Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}