mirror of
https://github.com/open-policy-agent/opa.git
synced 2026-08-13 03:42:35 -06:00
679c3de78b
This commit enables print() calls inside of the server for INFO and DEBUG log levels. The print hook is plumbed through to the server via the manager so that other server implementations (e.g., the Envoy plugin) can be updated similarly. The server will compile print() calls for the /v1/query API but not others since (i) print() calls inside the policies will already have been compiled and (ii) the queries are limited to fetching `data` paths and therefore cannot contain print() calls themselves. The bundle plugin has been updated to compile print() calls as well--this way the bundle plugin/server will respect incoming bundles and not attempt to override them. Signed-off-by: Torin Sandall <torinsandall@gmail.com>