{"record":{"id":"39b1b87d414d27e2","repo":"apache/incubator-seata","slug":"apollo-configuration-initialized-failed-please-che","errorCode":null,"errorMessage":"Apollo configuration initialized failed,please check the value of apolloMeta and apolloConfigService","messagePattern":"Apollo configuration initialized failed,please check the value of apolloMeta and apolloConfigService","errorType":"exception","errorClass":"RuntimeException","httpStatus":null,"severity":"critical","filePath":"config/seata-config-apollo/src/main/java/org/apache/seata/config/apollo/ApolloConfiguration.java","lineNumber":208,"sourceCode":"        if (!properties.containsKey(PROP_APOLLO_SECRET)) {\n            String apolloAccesskeySecret = FILE_CONFIG.getConfig(getApolloSecretFileKey());\n            if (StringUtils.isNotBlank(apolloAccesskeySecret)) {\n                System.setProperty(PROP_APOLLO_SECRET, apolloAccesskeySecret);\n            }\n        }\n        if (!properties.containsKey(PROP_APOLLO_CLUSTER)) {\n            String apolloCluster = FILE_CONFIG.getConfig(getApolloCluster());\n            if (StringUtils.isNotBlank(apolloCluster)) {\n                System.setProperty(PROP_APOLLO_CLUSTER, apolloCluster);\n            }\n        }\n        if (!properties.containsKey(PROP_APOLLO_CONFIG_SERVICE)) {\n            String apolloConfigService = FILE_CONFIG.getConfig(getApolloConfigService());\n            if (StringUtils.isNotBlank(apolloConfigService)) {\n                System.setProperty(PROP_APOLLO_CONFIG_SERVICE, apolloConfigService);\n            } else {\n                if (StringUtils.isBlank(System.getProperty(PROP_APOLLO_META))) {\n                    throw new RuntimeException(\n                            \"Apollo configuration initialized failed,please check the value of apolloMeta and apolloConfigService\");\n                }\n            }\n        }\n    }\n\n    @Override\n    public String getTypeName() {\n        return REGISTRY_TYPE;\n    }\n\n    public static String getApolloMetaFileKey() {\n        return String.join(FILE_CONFIG_SPLIT_CHAR, FILE_ROOT_CONFIG, REGISTRY_TYPE, APOLLO_META);\n    }\n\n    public static String getApolloSecretFileKey() {\n        return String.join(FILE_CONFIG_SPLIT_CHAR, FILE_ROOT_CONFIG, REGISTRY_TYPE, APOLLO_SECRET);\n    }","sourceCodeStart":190,"sourceCodeEnd":226,"githubUrl":"https://github.com/apache/incubator-seata/blob/e01f97c6db397165050caa6764020410c2c8199a/config/seata-config-apollo/src/main/java/org/apache/seata/config/apollo/ApolloConfiguration.java#L190-L226","documentation":"ApolloConfiguration's static init throws RuntimeException('Apollo configuration initialized failed,please check the value of apolloMeta and apolloConfigService') when neither apolloConfigService (env/tool props) nor apolloMeta (system property) is set. Apollo's client needs at least one service endpoint to locate its ConfigService; without it the config center is unreachable, so seata fails fast during ConfigurationFactory bootstrap.","triggerScenarios":"Setting config.type=apollo in registry.conf/file.conf or via -Dseata.config.type=apollo but omitting both apolloConfigService and apolloMeta; typos in the property names (e.g. apollo.meta vs apolloMeta or wrong env key apollo.config-service); the values expected in file.conf not flowing to system properties because the file wasn't loaded.","commonSituations":"New environment/deployment missing Apollo env vars (APP-ID, APOLLO_META, APOLLO_CONFIG_SERVICE); copying a registry template without filling Apollo endpoints; property-key casing/format mismatch between file.conf keys and System.setProperty names; CI containers lacking Apollo network config.","solutions":["Set -DapolloMeta=http://<apollo-meta-host>:8080 (or env APOLLO_META) so the Apollo client can discover the config service.","Alternatively set apolloConfigService (env APOLLO_CONFIG_SERVICE) to the config service URL directly.","Verify the file.conf/registry.conf apollo block keys (apolloMeta, apolloConfigService, app.id, cluster) are spelled exactly as seata expects.","Confirm the values actually reach System properties before seata initializes (log or assert them in a startup hook)."],"exampleFix":"# before\n# registry.conf / application.conf with no apollo endpoint\nconfig { type = \"apollo\" }\n\n# after\nconfig {\n  type = \"apollo\"\n  apollo {\n    appId = \"seata-server\"\n    apolloMeta = \"http://apollo-meta.example:8080\"\n    cluster = \"default\"\n  }\n}\n# or JVM flag: -DapolloMeta=http://apollo-meta.example:8080","handlingStrategy":"validation","validationCode":"String meta = System.getProperty(\"apolloMeta\", System.getenv(\"APOLLO_META\"));\nString svc = System.getProperty(\"apolloConfigService\", System.getenv(\"APOLLO_CONFIG_SERVICE\"));\nif (isBlank(meta) && isBlank(svc)) {\n    throw new IllegalStateException(\"Apollo endpoint missing: set apolloMeta or apolloConfigService\");\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Set Apollo endpoint env vars (APOLLO_META/APOLLO_CONFIG_SERVICE) in every deployment environment","Add a startup preflight assertion for Apollo properties before seata initializes","Keep apollo key spelling in registry.conf/file.conf exactly as documented"],"tags":["apollo","config","startup","configuration","seata"],"backgroundTag":null,"analyzedSha":"e01f97c6db397165050caa6764020410c2c8199a","analyzedAt":"2026-08-14T10:23:53.097Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}