MCPcopy Create free account
hub / github.com/brimdata/super / PoolID

Method PoolID

db/api/remote.go:38–49  ·  view source on GitHub ↗
(ctx context.Context, poolName string)

Source from the content-addressed store, hash-verified

36}
37
38func (r *remote) PoolID(ctx context.Context, poolName string) (ksuid.KSUID, error) {
39 if id, err := dbid.ParseID(poolName); err == nil {
40 if _, err := LookupPoolByID(ctx, r, id); err == nil {
41 return id, nil
42 }
43 }
44 config, err := LookupPoolByName(ctx, r, poolName)
45 if err != nil {
46 return ksuid.Nil, err
47 }
48 return config.ID, nil
49}
50
51func (r *remote) CommitObject(ctx context.Context, poolID ksuid.KSUID, branchName string) (ksuid.KSUID, error) {
52 res, err := r.conn.BranchGet(ctx, poolID, branchName)

Callers

nothing calls this directly

Calls 3

ParseIDFunction · 0.92
LookupPoolByIDFunction · 0.85
LookupPoolByNameFunction · 0.85

Tested by

no test coverage detected