Juliacon 2024

Policy Enforcement in Julia Enterprise Applications with OPA
07-12, 10:10–10:20 (Europe/Amsterdam), Function (4.1)

This talk will introduce the OpenPolicyAgent.jl package, which makes integrating OPA (Open Policy Agent), a general purpose policy engine, with any Julia application easy. OPA provides a high-level declarative language that allows policy to be specified as code, and an engine that can offload policy decision-making over API calls to the OPA engine. It is the industry standard in open source policy agents, and has a wide range of tools and integrations available for use.


OPA is a general purpose open source policy engine that unifies policy enforcement across the application stack. OPA provides a high-level declarative language that allows policy to be specified as code, and an engine that can offload policy decision-making over API calls to the OPA engine. OPA can be used to enforce policies in microservices, Kubernetes, CI/CD pipelines, API gateways, and more.

This talk will introduce the OpenPolicyAgent.jl package, which makes integrating OPA with any Julia application easy. It will demonstrate how to use the packaged server module to run the OPA engine as a sidecar, and how to use the Julia client APIs to interface with the engine.

OPA also allows partial evaluation of policy rules, resulting in a simplified AST that can be used for further processing in applications. OpenPolicyAgent.jl exposes a generic way to walk over the AST, and allows code to be plugged into that. For example the AST resulting from partially evaluating policies related to database tables can be used to generate SQL query conditions. OpenPolicyAgent.jl includes a plugin that can generate such SQL query conditions from partially evaluated policies. Durnig the talk we shall walk through examples that use this too.

Author and contributor of various packages across the Julia ecosystem. Mostly involved with packages in JuliaWeb, JuliaIO, JuliaParallel and JuliaDatabase orgs. Currently working with JuliaHub Inc., focussing on the JuliaHub platform and cluster management pieces.

This speaker also appears in: