| 207 | } |
| 208 | |
| 209 | func (c *Connection) PoolStats(ctx context.Context, id ksuid.KSUID) (exec.PoolStats, error) { |
| 210 | req := c.NewRequest(ctx, http.MethodGet, path.Join("/pool", id.String(), "stats"), nil) |
| 211 | var stats exec.PoolStats |
| 212 | err := c.doAndUnmarshal(req, &stats) |
| 213 | if errIsStatus(err, http.StatusNotFound) { |
| 214 | err = ErrPoolNotFound |
| 215 | } |
| 216 | return stats, err |
| 217 | } |
| 218 | |
| 219 | func (c *Connection) BranchGet(ctx context.Context, poolID ksuid.KSUID, branchName string) (api.CommitResponse, error) { |
| 220 | path := urlPath("pool", poolID.String(), "branch", branchName) |