{"record":{"id":"fce1683c13239542","repo":"alibaba/canal","slug":"pulsar-consumer-subscriptname-required","errorCode":null,"errorMessage":"Pulsar Consumer subscriptName required","messagePattern":"Pulsar Consumer subscriptName required","errorType":"exception","errorClass":"RuntimeException","httpStatus":null,"severity":"error","filePath":"client/src/main/java/com/alibaba/otter/canal/client/pulsarmq/PulsarMQCanalConnector.java","lineNumber":150,"sourceCode":"     * @param subscriptName 订阅和客户端名称，同一个订阅名视为同一个消费实例\n     * @date 2021/9/18 08:54\n     * @author chad\n     * @since 1 by chad at 2021/9/18 完善\n     */\n    public PulsarMQCanalConnector(boolean isFlatMessage, String serviceUrl, String roleToken, String topic,\n                                  String subscriptName){\n        this(isFlatMessage, serviceUrl, roleToken, topic, subscriptName, null);\n    }\n\n    public PulsarMQCanalConnector(boolean isFlatMessage, String serviceUrl, String roleToken, String topic,\n                                  String subscriptName, String listenerName){\n        this.isFlatMessage = isFlatMessage;\n        this.serviceUrl = serviceUrl;\n        this.roleToken = roleToken;\n        this.topic = topic;\n        this.subscriptName = subscriptName;\n        if (StringUtils.isEmpty(this.subscriptName)) {\n            throw new RuntimeException(\"Pulsar Consumer subscriptName required\");\n        }\n        this.listenerName = listenerName;\n    }\n\n    /**\n     * 完全自定义的消费实例参数\n     *\n     * @date 2021/9/18 10:20\n     * @author chad\n     * @since 1 by chad at 2021/9/18 完善\n     */\n    public PulsarMQCanalConnector(boolean isFlatMessage, String serviceUrl, String roleToken, String topic,\n                                  String subscriptName, int batchSize, int getBatchTimeoutSeconds,\n                                  int batchProcessTimeoutSeconds, int redeliveryDelaySeconds, int ackTimeoutSeconds,\n                                  boolean isRetry, boolean isRetryDLQUpperCase, int maxRedeliveryCount){\n        this(isFlatMessage,\n            serviceUrl,\n            roleToken,","sourceCodeStart":132,"sourceCodeEnd":168,"githubUrl":"https://github.com/alibaba/canal/blob/87be50e87686a3e8af08c368d0e1ffd1f59eb04a/client/src/main/java/com/alibaba/otter/canal/client/pulsarmq/PulsarMQCanalConnector.java#L132-L168","documentation":"Error \"Pulsar Consumer subscriptName required\" thrown in alibaba/canal.","triggerScenarios":"Thrown at client/src/main/java/com/alibaba/otter/canal/client/pulsarmq/PulsarMQCanalConnector.java:150 when the library encounters an invalid state.","commonSituations":"Missing Pulsar subscription name. Require the property at configuration load time rather than at first consume, and fail fast with the property key in the message.","solutions":["Set the Pulsar subscription name (subscriptName) in the connector configuration before connecting.","Ensure the same subscription name is used consistently so messages are not duplicated across consumers."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"87be50e87686a3e8af08c368d0e1ffd1f59eb04a","analyzedAt":"2026-08-14T04:30:11.918Z","schemaVersion":2},"datasetVersion":"2026-08-14T05:17:29.042Z"}