Skip to content

Commit 0947249

Browse files
committed
update comment
Signed-off-by: Jose I. Paris <jiparis@chainloop.dev>
1 parent 5c08c98 commit 0947249

1 file changed

Lines changed: 2 additions & 10 deletions

File tree

app/controlplane/internal/service/casbackend.go

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -67,11 +67,7 @@ func (s *CASBackendService) Create(ctx context.Context, req *pb.CASBackendServic
6767
return nil, err
6868
}
6969

70-
// Managed-only providers (currently AWS-S3-ACCESS-POINT) are
71-
// reserved for the platform reconciler, which provisions them via
72-
// the biz layer directly. Reject any attempt to create one through
73-
// the public RPC so a user can't end up with a half-provisioned row
74-
// pointing at an AP they don't own.
70+
// Managed-only providers (currently AWS-S3-ACCESS-POINT) are reserved
7571
if isManagedOnlyProvider(req.Provider) {
7672
return nil, errors.BadRequest("invalid CAS backend",
7773
"managed CAS backends cannot be created via this API")
@@ -249,11 +245,7 @@ func bizCASBackendToPb(in *biz.CASBackend) *pb.CASBackendItem {
249245
return r
250246
}
251247

252-
// isManagedOnlyProvider returns true when the supplied provider ID can
253-
// only be instantiated by the platform reconciler — never by a user via
254-
// the public CASBackendService.Create RPC. Today that's just the S3
255-
// Access Point provider; if more managed providers land later, list
256-
// them here.
248+
// isManagedOnlyProvider returns true when the supplied provider is managed
257249
func isManagedOnlyProvider(id string) bool {
258250
return id == s3accesspoint.ProviderID
259251
}

0 commit comments

Comments
 (0)