Hi guys, We are considering switching to a service...
# help
Hi guys, We are considering switching to a service deployment but I have a question from one of the developers:
Are there any additional network implications as a service that result in longer calls than would exist as a coupled process? If you loop over a list of objects to filter a list of N items by policy, we want to be sure that its not going to add 10s of seconds on.
A service deployment looks as though it will be better for our particular use case, but we just want to be sure it isn't going to impact performance drastically. Cheers 😄
Unless your service deployment is in a different continent from the application, the network overhead is negligible in modern data centres. It's no different from accessing a database -- which most applications do and Cerbos is much lighter and faster than a typical database. Because Cerbos is stateless, you can effortlessly horizontally scale it to match the demand from your applications as well. In case you weren't aware, Cerbos has a concept called a query planner that makes filtering by authorization logic much easier and efficient than iterating over a list of items and checking each one. There are some blog posts on our site about that (https://cerbos.dev/blog/filtering-data-using-authorization-logic) and there are example query plan adapters available for some popular frameworks as well (https://github.com/cerbos/query-plan-adapters)
👍 1
Thank you! I wasn't aware of the query planner, but I will pass it onto the devs and see if they were aware.
In case it helps, we run Cerbos in that deployment model & see P95s with very low millisecond responses