MCPcopy
hub / github.com/etcd-io/etcd / Defragment

Method Defragment

tests/framework/integration/integration.go:250–263  ·  view source on GitHub ↗
(ctx context.Context, o config.DefragOption)

Source from the content-addressed store, hash-verified

248}
249
250func (c integrationClient) Defragment(ctx context.Context, o config.DefragOption) error {
251 if o.Timeout != 0 {
252 var cancel context.CancelFunc
253 ctx, cancel = context.WithTimeout(ctx, o.Timeout)
254 defer cancel()
255 }
256 for _, ep := range c.Endpoints() {
257 _, err := c.Client.Defragment(ctx, ep)
258 if err != nil {
259 return err
260 }
261 }
262 return nil
263}
264
265func (c integrationClient) TimeToLive(ctx context.Context, id clientv3.LeaseID, o config.LeaseOption) (*clientv3.LeaseTimeToLiveResponse, error) {
266 var leaseOpts []clientv3.LeaseOption

Callers

nothing calls this directly

Calls 2

EndpointsMethod · 0.65
DefragmentMethod · 0.65

Tested by

no test coverage detected