src/client/admin.go
func (c APIClient) Extract(objects bool, f func(op *admin.Op) error) error {
	extractClient, err := c.AdminAPIClient.Extract(c.Ctx(), &admin.ExtractRequest{NoObjects: !objects})
	if err != nil {
		return grpcutil.ScrubGRPC(err)
	}
	for {
		op, err := extractClient.Recv()
		if err == io.EOF {
			break
		}
		if err != nil {
			return grpcutil.ScrubGRPC(err)
		}
		if err := f(op); err != nil {
			return err
		}
	}
	return nil
}
func (c APIClient) Extract(objects bool, f func(op *admin.Op) error) error {
	extractClient, err := c.AdminAPIClient.Extract(c.Ctx(), &admin.ExtractRequest{NoObjects: !objects})
	if err != nil {
		return grpcutil.ScrubGRPC(err)
	}
	for {
		op, err := extractClient.Recv()
		if err == io.EOF {
			break
		}
		if err != nil {
			return grpcutil.ScrubGRPC(err)
		}
		if err := f(op); err != nil {
			return err
		}
	}
	return nil
}
func ( c APIClient ) Extract ( objects bool , f func ( op * admin . Op ) error ) error { extractClient , err := c . AdminAPIClient . Extract ( c . Ctx ( ) , & admin . ExtractRequest { NoObjects : ! objects } ) if err != nil { return grpcutil . ScrubGRPC ( err ) } for { op , err := extractClient . Recv ( ) if err == io . EOF { break } if err != nil { return grpcutil . ScrubGRPC ( err ) } if err := f ( op ) ; err != nil { return err } } return nil }
// Extract all cluster state, call f with each operation.
Extract all cluster state call f with each operation .