apache/dolphinscheduler · error · RegistryException

Delete key: %s error

Error message

Delete key: %s error

What it means

Wrapper thrown in JdbcRegistry.delete: any exception from jdbcRegistryClient.deleteJdbcRegistryDataByKey (SQL failure, missing table, connection problems) is converted to a RegistryException naming the key, so registry callers get a uniform checked-style failure with the cause preserved.

Source

Thrown at dolphinscheduler-registry/dolphinscheduler-registry-plugins/dolphinscheduler-registry-jdbc/src/main/java/org/apache/dolphinscheduler/plugin/registry/jdbc/JdbcRegistry.java:159

        }
    }

    @Override
    public void put(String key, String value, boolean deleteOnDisconnect) {
        try {
            DataType dataType = deleteOnDisconnect ? DataType.EPHEMERAL : DataType.PERSISTENT;
            jdbcRegistryClient.putJdbcRegistryData(key, value, dataType);
        } catch (Exception ex) {
            throw new RegistryException(String.format("put key:%s, value:%s error", key, value), ex);
        }
    }

    @Override
    public void delete(String key) {
        try {
            jdbcRegistryClient.deleteJdbcRegistryDataByKey(key);
        } catch (Exception e) {
            throw new RegistryException(String.format("Delete key: %s error", key), e);
        }
    }

    @Override
    public Collection<String> children(String key) {
        try {
            final List<JdbcRegistryDataDTO> children = jdbcRegistryClient.listJdbcRegistryDataChildren(key);
            return children
                    .stream()
                    .map(JdbcRegistryDataDTO::getDataKey)
                    .map(fullPath -> StringUtils.substringBefore(fullPath.substring(key.length() + 1), "/"))
                    .distinct()
                    .collect(Collectors.toList());
        } catch (Exception e) {
            throw new RegistryException(String.format("Get key: %s children error", key), e);
        }
    }

View on GitHub (pinned to 02eac45a1b)

Solutions

  1. Inspect the cause for the actual SQL/connection failure
  2. Verify DB connectivity and table permissions
  3. Retry the delete; if the key is already gone the operation may be safely skipped
  4. Check for lock contention with other registry clients
Defensive patterns

Strategy: retry

Validate before calling

// optionally check exists(key) if delete idempotency matters

Try / catch

try { registry.delete(key); } catch (RegistryException e) { log.warn("delete failed for {}", key, e); }

Prevention

When it happens

Trigger: Calling registry.delete(key) when the DB connection fails, the transaction cannot commit, or the delete statement errors.

Common situations: DB outage or failover mid-operation, connection pool exhausted, permissions revoked on the registry table, deadlocks.

Related errors


AI-assisted analysis of apache/dolphinscheduler@02eac45a1b (2026-09-06). Data as JSON: /api/errors/72c42da3406b607b. Report an issue: GitHub.