Summary
Migrate gate's tenant.proto and identity_group.proto to import canonical types from the identity service's proto package instead of redefining Organization, OrgMember, APIKey, Identity, and Group independently.
Problem
Gate defines its own versions of identity domain types in two proto files:
proto/gate/v1/tenant.proto — Organization, OrgMember, APIKey, plus org CRUD RPCs
proto/gate/v1/identity_group.proto — Identity, Group, plus CRUD RPCs
These overlap with but differ from chat's auth/v1/auth.proto definitions (WorkspaceInfo, WorkspaceMemberInfo, APIKeyInfo). Both are independent re-implementations of concepts that should be owned by the identity service.
For example, gate's OrgMember has {org_id, user_id, role, created_at} while chat's WorkspaceMemberInfo has {user_id, email, name, picture, role, status, identity_provider, provisioning_source}. Neither is wrong — but they should extend a shared base type rather than being independent.
Scope
- Once identity publishes canonical proto types, import them in gate's protos
- Gate-specific fields (like proxy-related context) can extend the shared types
- Update
controlplane.proto to reference the imported types
- Regenerate Go code
Depends on
- evalops/identity proto definitions being published
Summary
Migrate gate's
tenant.protoandidentity_group.prototo import canonical types from the identity service's proto package instead of redefining Organization, OrgMember, APIKey, Identity, and Group independently.Problem
Gate defines its own versions of identity domain types in two proto files:
proto/gate/v1/tenant.proto—Organization,OrgMember,APIKey, plus org CRUD RPCsproto/gate/v1/identity_group.proto—Identity,Group, plus CRUD RPCsThese overlap with but differ from chat's
auth/v1/auth.protodefinitions (WorkspaceInfo,WorkspaceMemberInfo,APIKeyInfo). Both are independent re-implementations of concepts that should be owned by the identity service.For example, gate's
OrgMemberhas{org_id, user_id, role, created_at}while chat'sWorkspaceMemberInfohas{user_id, email, name, picture, role, status, identity_provider, provisioning_source}. Neither is wrong — but they should extend a shared base type rather than being independent.Scope
controlplane.prototo reference the imported typesDepends on