{"record":{"id":"7d87dd20733e90e6","repo":"risingwavelabs/risingwave","slug":"obs-endpoint-not-found-from-environment-variables","errorCode":null,"errorMessage":"OBS_ENDPOINT not found from environment variables","messagePattern":"OBS_ENDPOINT not found from environment variables","errorType":"panic","errorClass":null,"httpStatus":null,"severity":"critical","filePath":"src/object_store/src/object/opendal_engine/obs.rs","lineNumber":38,"sourceCode":"use risingwave_common::config::ObjectStoreConfig;\n\nuse super::{MediaType, OpendalObjectStore, new_operator};\nuse crate::object::ObjectResult;\nuse crate::object::object_metrics::ObjectStoreMetrics;\n\nimpl OpendalObjectStore {\n    /// create opendal obs engine.\n    pub fn new_obs_engine(\n        bucket: String,\n        root: String,\n        config: Arc<ObjectStoreConfig>,\n        metrics: Arc<ObjectStoreMetrics>,\n    ) -> ObjectResult<Self> {\n        // Create obs backend builder.\n        let mut builder = Obs::default().bucket(&bucket).root(&root);\n\n        let endpoint = std::env::var(\"OBS_ENDPOINT\")\n            .unwrap_or_else(|_| panic!(\"OBS_ENDPOINT not found from environment variables\"));\n        let access_key_id = std::env::var(\"OBS_ACCESS_KEY_ID\")\n            .unwrap_or_else(|_| panic!(\"OBS_ACCESS_KEY_ID not found from environment variables\"));\n        let secret_access_key = std::env::var(\"OBS_SECRET_ACCESS_KEY\").unwrap_or_else(|_| {\n            panic!(\"OBS_SECRET_ACCESS_KEY not found from environment variables\")\n        });\n\n        builder = builder\n            .endpoint(&endpoint)\n            .access_key_id(&access_key_id)\n            .secret_access_key(&secret_access_key);\n\n        let op = new_operator(\n            &config,\n            Operator::new(builder)?.layer(LoggingLayer::default()),\n        );\n\n        Ok(Self {\n            op,","sourceCodeStart":20,"sourceCodeEnd":56,"githubUrl":"https://github.com/risingwavelabs/risingwave/blob/6469eb736d691e8e9b8a419a57edd6429ca77417/src/object_store/src/object/opendal_engine/obs.rs#L20-L56","documentation":"new_obs_engine requires the Huawei OBS endpoint via the OBS_ENDPOINT environment variable and panics when it is unset, since the OpenDAL obs builder needs an endpoint to build the client. The process aborts during object store initialization.","triggerScenarios":"Using an obs:// remote store without OBS_ENDPOINT exported in the environment of the RisingWave process.","commonSituations":"Deploying to Huawei Cloud OBS but forgetting to inject the endpoint env var into the container/pod, or misspelling the variable name.","solutions":["Export OBS_ENDPOINT (e.g. https://obs.<region>.myhuaweicloud.com) before starting RisingWave","Add the env var to your Kubernetes/docker deployment config","Verify the variable is visible to the process (env | grep OBS)","Set OBS_ACCESS_KEY_ID and OBS_SECRET_ACCESS_KEY as well — the next panic will otherwise come from those"],"exampleFix":"# before\ndocker run risingwave/risingwave ...  # OBS_ENDPOINT unset -> panic\n# after\ndocker run -e OBS_ENDPOINT=https://obs.cn-north-4.myhuaweicloud.com \\\n  -e OBS_ACCESS_KEY_ID=... -e OBS_SECRET_ACCESS_KEY=... risingwave/risingwave ...","handlingStrategy":"validation","validationCode":"// Preflight all three OBS variables before starting\nfor var in [\"OBS_ENDPOINT\", \"OBS_ACCESS_KEY_ID\", \"OBS_SECRET_ACCESS_KEY\"] {\n    if std::env::var(var).is_err() {\n        eprintln!(\"{} must be set for obs:// object store\", var);\n        std::process::exit(1);\n    }\n}","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Set OBS_ENDPOINT, OBS_ACCESS_KEY_ID and OBS_SECRET_ACCESS_KEY together as one unit in deployment configs","Add an env preflight check in your container entrypoint","Document required OBS vars wherever the obs:// store URL is configured"],"tags":["rust","obs","huawei","opendal","env-var","panic"],"backgroundTag":"missing-env-var","analyzedSha":"6469eb736d691e8e9b8a419a57edd6429ca77417","analyzedAt":"2026-09-11T21:06:21.487Z","contentChangedAt":"2026-09-11T21:06:21.487Z","schemaVersion":2},"datasetVersion":"2026-09-14T16:17:12.679Z"}