apache/incubator-seata · warning · NotSupportYetException

not support removeConfig

Error message

not support removeConfig

What it means

ApolloConfiguration.removeConfig throws NotSupportYetException('not support removeConfig'). Deleting configuration is not implemented for Apollo because seata's Apollo integration is read-only; namespace changes must go through Apollo's own portal or OpenAPI with its audit/rollback semantics.

Solutions

  1. Move the deletion to Apollo's portal or Admin Service API.
  2. Remove the delete path from your code when running against Apollo (feature-flag by config type).
  3. Use a writable backend if programmatic removal is required.
  4. Catch NotSupportYetException for optional cleanup steps.

Example fix

// before
configuration.removeConfig(dataId, 5000);

// after
try {
    configuration.removeConfig(dataId, 5000);
} catch (NotSupportYetException e) {
    LOGGER.info("removeConfig unsupported on apollo; delete {} via Apollo portal", dataId);
}
Defensive patterns

Strategy: try-catch

Validate before calling

"apollo".equals(configuration.getTypeName()) // skip removeConfig when true

Try / catch

try {
    configuration.removeConfig(dataId, timeoutMills);
} catch (NotSupportYetException e) {
    LOGGER.info("removeConfig unsupported on {}; delete via the backend's own console", configuration.getTypeName());
}

Prevention

When it happens

Trigger: Calling removeConfig(dataId, timeoutMills) while config.type=apollo — e.g. cleanup routines, dynamic config-unregistration code, or admin tooling that deletes keys across all config centers.

Common situations: Environment-cleanup scripts written against Nacos being reused on Apollo; lifecycle code removing temporary config keys on shutdown.

Related errors


AI-assisted analysis of apache/incubator-seata@e01f97c6db (2026-08-14). Data as JSON: /api/errors/e9fa8d5208aa8401. Report an issue: GitHub.

Appendix: source

Thrown at config/seata-config-apollo/src/main/java/org/apache/seata/config/apollo/ApolloConfiguration.java:147

            String result = config.getProperty(dataId, defaultValue);
            configFuture.setResult(result);
        });
        return (String) configFuture.get();
    }

    @Override
    public boolean putConfig(String dataId, String content, long timeoutMills) {
        throw new NotSupportYetException("not support putConfig");
    }

    @Override
    public boolean putConfigIfAbsent(String dataId, String content, long timeoutMills) {
        throw new NotSupportYetException("not support atomic operation putConfigIfAbsent");
    }

    @Override
    public boolean removeConfig(String dataId, long timeoutMills) {
        throw new NotSupportYetException("not support removeConfig");
    }

    @Override
    public void addConfigListener(String dataId, ConfigurationChangeListener listener) {
        if (StringUtils.isBlank(dataId) || listener == null) {
            return;
        }
        LISTENER_SERVICE_MAP
                .computeIfAbsent(dataId, key -> ConcurrentHashMap.newKeySet())
                .add(listener);
    }

    @Override
    public void removeConfigListener(String dataId, ConfigurationChangeListener listener) {
        if (StringUtils.isBlank(dataId) || listener == null) {
            return;
        }
        Set<ConfigurationChangeListener> configListeners = getConfigListeners(dataId);

View on GitHub (pinned to e01f97c6db)