{"record":{"id":"630f09171ceb52a5","repo":"iflytek/astron-agent","slug":"tenant-internal-authentication-is-not-configured-request-was","errorCode":null,"errorMessage":"Tenant internal authentication is not configured; request was not sent","messagePattern":"Tenant internal authentication is not configured; request was not sent","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"console/backend/hub/src/main/java/com/iflytek/astron/console/hub/service/publish/impl/TenantServiceImpl.java","lineNumber":128,"sourceCode":"            if (reqJson.getInteger(\"code\") == 0 && reqJson.containsKey(\"data\")\n                    && reqJson.getJSONArray(\"data\").getJSONObject(0).containsKey(\"auth_list\")) {\n                return JSONArray.parseArray(reqJson.getJSONArray(\"data\").getJSONObject(0).getString(\"auth_list\"), TenantAuth.class).get(0);\n            } else {\n                log.error(\n                        \"Tenant app detail response was rejected or incomplete, code={}\",\n                        reqJson.getInteger(\"code\"));\n            }\n        } catch (Exception e) {\n            log.error(\"Tenant app detail request failed: {}\", e.getClass().getSimpleName());\n        }\n        return null;\n    }\n\n    private String configuredTenantInternalKey() {\n        try {\n            return TenantInternalApiKey.requireConfigured(tenantInternalKey);\n        } catch (IllegalStateException exception) {\n            log.warn(\"Tenant internal authentication is not configured; request was not sent\");\n            return null;\n        }\n    }\n\n}\n","sourceCodeStart":110,"sourceCodeEnd":134,"githubUrl":"https://github.com/iflytek/astron-agent/blob/5e758547a83371a5a4b29dadf4ac03e8dd527635/console/backend/hub/src/main/java/com/iflytek/astron/console/hub/service/publish/impl/TenantServiceImpl.java#L110-L134","documentation":"A warn log when the tenant internal API key is not configured (blank/absent), so the tenant request is deliberately not sent and the method returns null. TenantInternalApiKey.requireConfigured throws IllegalStateException which is converted to a null return.","triggerScenarios":"Any call to configuredInternalKey (via configuredTenantInternalKey) when the tenantInternalKey config property is unset or empty in the environment.","commonSituations":"Deploying hub without setting the tenant internal auth key env/config; config key renamed after upgrade; local dev environments missing the property that production has.","solutions":["Set the tenant internal API key configuration property (e.g. env var / application.yml) for the hub service","Confirm TenantInternalApiKey.requireConfigured's expected config source and key name match your deployment config","Restart the service after adding the key and verify via startup config validation"],"exampleFix":"// before\ntenant:\n  internal-key:   # empty\n// after\ntenant:\n  internal-key: ${TENANT_INTERNAL_API_KEY}","handlingStrategy":"fallback","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":["config","authentication","tenant"],"backgroundTag":"missing-env-var","analyzedSha":"5e758547a83371a5a4b29dadf4ac03e8dd527635","analyzedAt":"2026-09-12T08:03:51.356Z","contentChangedAt":"2026-09-12T08:03:51.356Z","schemaVersion":2},"datasetVersion":"2026-09-15T23:17:13.987Z"}