apache/seatunnel · error · CatalogException

Failed close kudu client

Error message

Failed close kudu client

What it means

KuduCatalog.close() attempts to release the underlying Kudu client (or its resource wrapper). If closing the Kudu client raises a KuduException, it is rethrown as a CatalogException with this message. It signals the client connection to the Kudu masters/tablets could not be shut down cleanly.

Source

Thrown at seatunnel-connectors-v2/connector-kudu/src/main/java/org/apache/seatunnel/connectors/seatunnel/kudu/catalog/KuduCatalog.java:89

        this.catalogName = catalogName;
    }

    @Override
    public void open() throws CatalogException {
        kuduClientResource = KuduUtil.getKuduClientResource(config);
        kuduClient = kuduClientResource.getClient();
    }

    @Override
    public void close() throws CatalogException {
        try {
            if (kuduClientResource != null) {
                kuduClientResource.close();
            } else if (kuduClient != null) {
                kuduClient.close();
            }
        } catch (KuduException e) {
            throw new CatalogException("Failed close kudu client", e);
        } finally {
            kuduClient = null;
            kuduClientResource = null;
        }
    }

    @Override
    public String name() {
        return catalogName;
    }

    @Override
    public String getDefaultDatabase() throws CatalogException {
        return defaultDatabase;
    }

    @Override
    public boolean databaseExists(String databaseName) throws CatalogException {

View on GitHub (pinned to cf67b549a7)

Solutions

  1. Check network connectivity to Kudu master addresses at shutdown
  2. Verify the Kudu cluster is healthy (master status)
  3. Retry catalog close; the finally block nulls the client so leaks are unlikely
  4. Inspect the wrapped KuduException cause for the root RPC failure
Defensive patterns

Strategy: try-catch

Try / catch

try { catalog.close(); } catch (CatalogException e) { log.warn("Kudu client close failed", e.getCause()); } // resources are nulled in finally, safe to continue

Prevention

When it happens

Trigger: Calling catalog.close() when the KuduClient's close RPC fails — e.g. connection to Kudu masters already broken or a KuduException thrown during client shutdown.

Common situations: Job teardown after a network partition with the Kudu cluster; stale clients after Kudu master restarts; shutdown during connection timeouts.

Understand the failure class

Background: Database query failed: Internal Server Error 500s wrapping SQL, Prisma, and connection failures — what to check first — this error's family across 16 libraries.

Related errors


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