OPA data and policy storage #186
Replies: 1 comment 3 replies
-
Hey there.
Since the memory will be in a pristine state when OPA restarts, that data will be gone.
Disk storage can be used for data persistency across restarts. There are also other means to do that: Bundles. If your OPA service is configured to load bundles, it'll do so on every (re)start and periodically while it's running. Bundles can even be persisted on disk, so that if an OPA service restarts, it'll be able to use the previously fetched bundle right away. See the Bundles documentation for all the details. |
Beta Was this translation helpful? Give feedback.
-
Hello,
From the discussions it seems like OPA stores both policy and data in memory, if that is the case, when we do a create and update API to OPA using
PUT /v1/data/{path:.+}
orPATCH /v1/data/{path:.+}
Here are my questions regarding this?
The storage configuration https://www.openpolicyagent.org/docs/latest/misc-disk/ only talks about data that does not fit into memory. But then if opa crashes how does the services know which data to push and update?
Beta Was this translation helpful? Give feedback.
All reactions