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

Method RemovePool

api/client/connection.go:250–261  ·  view source on GitHub ↗
(ctx context.Context, id ksuid.KSUID)

Source from the content-addressed store, hash-verified

248}
249
250func (c *Connection) RemovePool(ctx context.Context, id ksuid.KSUID) error {
251 req := c.NewRequest(ctx, http.MethodDelete, path.Join("/pool", id.String()), nil)
252 res, err := c.Do(req)
253 if err != nil {
254 if errIsStatus(err, http.StatusNotFound) {
255 return ErrPoolNotFound
256 }
257 return err
258 }
259 res.Body.Close()
260 return nil
261}
262
263func (c *Connection) CreateBranch(ctx context.Context, poolID ksuid.KSUID, payload api.BranchPostRequest) (branches.Config, error) {
264 req := c.NewRequest(ctx, http.MethodPost, path.Join("/pool", poolID.String()), payload)

Callers

nothing calls this directly

Calls 5

NewRequestMethod · 0.95
DoMethod · 0.95
errIsStatusFunction · 0.85
StringMethod · 0.65
CloseMethod · 0.65

Tested by

no test coverage detected