AuthCtx is the context required to create a Namespace (project-id, account-id). In other words, authorise if the context can access Namespace.
In many places the service traits takes this type parameter of AuthCtx which doesn't make much sense.
Service layer is simply concerned with working with the entities in the namespace, and not exactly the access to the namespace.
I think happens either due to the suboptimal usage or abuse of the idea of AuthCtx type parameterization in favor of some simplicity, or not understanding the whole idea. Or, may be it was a mistake from the beginning.
This ticket can also be used to review the code, and fix things across. If the idea of AuthCtx is suboptimal, may be we revisit.
I can also see Namespace being String in certain places with an argument that it largely simplifies the code. If this was done, then the decision of making it String should be applied to the whole in favor of consistency. In either ways, consistency should be maintained. In my strong opinion, this String approach is deceivingly simple, and practically complex!
AuthCtx
is the context required to create aNamespace
(project-id, account-id). In other words, authorise if the context can accessNamespace
.In many places the service traits takes this type parameter of
AuthCtx
which doesn't make much sense.Service layer is simply concerned with working with the entities in the namespace, and not exactly the access to the namespace.
I think happens either due to the suboptimal usage or abuse of the idea of
AuthCtx
type parameterization in favor of some simplicity, or not understanding the whole idea. Or, may be it was a mistake from the beginning.This ticket can also be used to review the code, and fix things across. If the idea of
AuthCtx
is suboptimal, may be we revisit.I can also see
Namespace
beingString
in certain places with an argument that it largely simplifies the code. If this was done, then the decision of making itString
should be applied to the whole in favor of consistency. In either ways, consistency should be maintained. In my strong opinion, thisString
approach is deceivingly simple, and practically complex!