mirror of
https://github.com/open-policy-agent/opa.git
synced 2026-08-13 03:42:35 -06:00
e5427d5adb
Previously, initializing a new WASM resolver always used a background context. This prevented callers from passing down an existing context for timeouts, cancellation, or tracing. This change introduces `NewWithContext` in `v1/resolver/wasm` which accepts a context and propagates it to `Entrypoints()`. The existing `New` function has been updated to wrap `NewWithContext` using a background context to preserve backwards compatibility. `LoadWasmResolversFromStore` has been updated to pass the provided context appropriately. Signed-off-by: Dominik Schulz <dschulz@google.com>