hi, since the schema is one document per
# spicedb
e
hi, since the schema is one document per cluster, what is the maximum size of this schema if we have a large number of object types and permissions defined. Also how would the customer deal with many schema changes. our system adds and remove schema items often. Is this something that has been tested?
v
The maximum schema size is 4MB https://github.com/authzed/api/pull/77
frequent schema changes are fine, it depends how often they are, are they happen like every second?
e
Thank you. we need to determine that but I don't think that should be the case. What happens if we write more than 4MiBk, I assume we get an error. how would we determine we are getting close or know before we try to write that it will trigger it. It is not just the bytes of the schema string I assume. Also Spicedb does not have concept of tenant and I think previously it was suggested a deployment per tenant which may or may not be a good idea for us. If we get to the point we get to 4MB, what is the guidance, we need a new deployment?
v
> What happens if we write more than 4MiBk, I assume we get an error. how would we determine we are getting close or know before we try to write that it will trigger it. It is not just the bytes of the schema string I assume. There is no easy way because the server takes the text and compiles it into protos, so it's storing serialized proto for your definitions and cavats. You may be able to, using the exported SpiceDB Go packages, try to replicate what the server does to get an approximate. > Also Spicedb does not have concept of tenant and I think previously it was suggested a deployment per tenant which may or may not be a good idea for us. If we get to the point we get to 4MB, what is the guidance, we need a new deployment? That would work but would make interoperation between the different parts of the schema impossible. Another option is forking the
authzed-go
and
spicedb
repo with a different limit. Maybe we could also explore adding a flag for the limit and you could increase it. @Joey thoughts?
2 Views