apache/seatunnel · error · SeaTunnelException

Cannot find plugin jar for pluginIdentifier: %s -> %s. Possi

Error message

Cannot find plugin jar for pluginIdentifier: %s -> %s. Possible impact jar: %s

What it means

selectPluginJar matches a requested plugin to candidate jars in the plugin dir. CDC connectors ship as two jars (base + specific connector); if matching yields anything other than exactly 2 URLs for a 'cdc' plugin, it throws SeaTunnelException listing the candidate jars considered.

Source

Thrown at seatunnel-plugin-discovery/src/main/java/org/apache/seatunnel/plugin/discovery/AbstractPluginDiscovery.java:534

            return pathname.getName().endsWith(".jar")
                    && (StringUtils.startsWithIgnoreCase(pathname.getName(), pluginJarPrefix)
                            || StringUtils.startsWithIgnoreCase(
                                    pathname.getName(), "connector-cdc-base"));
        }
        return pathname.getName().endsWith(".jar")
                && StringUtils.startsWithIgnoreCase(pathname.getName(), pluginJarPrefix);
    }

    private Optional<List<URL>> selectPluginJar(
            File[] targetPluginFiles, String pluginJarPrefix, String pluginName, PluginType type) {
        List<URL> resMatchedUrls = new ArrayList<>();
        for (File file : targetPluginFiles) {
            Optional<URL> matchedUrl = findMatchingUrl(file, type, pluginName);
            matchedUrl.ifPresent(resMatchedUrls::add);
        }
        if (pluginName.contains("cdc")) {
            if (resMatchedUrls.size() != 2) {
                throw new SeaTunnelException(
                        String.format(
                                "Cannot find plugin jar for pluginIdentifier: %s -> %s. Possible impact jar: %s",
                                pluginName, pluginJarPrefix, Arrays.asList(targetPluginFiles)));
            }
        } else if (resMatchedUrls.size() != 1) {
            throw new SeaTunnelException(
                    String.format(
                            "Cannot find unique plugin jar for pluginIdentifier: %s -> %s. Possible impact jar: %s",
                            pluginName, pluginJarPrefix, Arrays.asList(targetPluginFiles)));
        }
        return Optional.of(resMatchedUrls);
    }

    private Optional<URL> findMatchingUrl(File file, PluginType type, String pluginName) {
        Map<PluginIdentifier, String> pluginInstanceMap = null;
        switch (type) {
            case SINK:
                pluginInstanceMap = sinkPluginInstance;

View on GitHub (pinned to cf67b549a7)

Solutions

  1. List the connectors dir and ensure both the CDC base jar and the specific CDC connector jar (same version) are present
  2. Remove duplicate/old versions of connector-cdc-* jars so exactly one pair matches
  3. Re-run sh bin/install-plugin.sh <version> to restore a consistent CDC jar set

Example fix

// before
connectors/connector-cdc-mysql-2.3.12.jar   # base jar missing
// after
connectors/connector-cdc-base-2.3.12.jar
connectors/connector-cdc-mysql-2.3.12.jar
Defensive patterns

Strategy: validation

Validate before calling

ls $SEATUNNEL_HOME/connectors | grep cdc
# expect exactly: connector-cdc-base-<v>.jar plus one connector-cdc-<engine>-<v>.jar, all same version

Prevention

When it happens

Trigger: findPluginJarPath is called for a plugin whose name contains 'cdc', and findMatchingUrl returns a count != 2 across targetPluginFiles — e.g. one of the CDC jar pair is missing or multiple duplicate copies exist.

Common situations: Manually copied connector-cdc jars leaving base jar missing; multiple versions of connector-cdc-base present causing ambiguous matches; install-plugin.sh partially failed.

Understand the failure class

Background: 'Could not be found', 'does not exist', 'not found in database': the resource-not-found family when an ID, slug, key, or URI lookup comes back empty — this error's family across 20 libraries.

Related errors


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