cacheProxyHealthURL returns the health endpoint URL (empty if disabled).
()
| 38 | // DuckDB warmup and the control-plane health RPC. |
| 39 | maxCacheProxyConnectTimeout = 10 * time.Second |
| 40 | ) |
| 41 | |
| 42 | // cacheEnabled returns true when the cache proxy integration should be used. |
| 43 | func cacheEnabled() bool { |
| 44 | return os.Getenv("DUCKGRES_CACHE_ENABLED") == "true" |
| 45 | } |
| 46 | |
| 47 | // cacheProxyHealthURL returns the health endpoint URL (empty if disabled). |
| 48 | func cacheProxyHealthURL() string { |
| 49 | if !cacheEnabled() { |
| 50 | return "" |
| 51 | } |
| 52 | nodeIP := os.Getenv(nodeIPEnvVar) |