Method
AddBind
(ctx context.Context, req *rpcpb.AddBindReq)
Source from the content-addressed store, hash-verified
| 282 | } |
| 283 | |
| 284 | func (s *metaService) AddBind(ctx context.Context, req *rpcpb.AddBindReq) (*rpcpb.AddBindRsp, error) { |
| 285 | select { |
| 286 | case <-ctx.Done(): |
| 287 | return nil, errRPCCancel |
| 288 | default: |
| 289 | err := s.db.AddBind(&metapb.Bind{ |
| 290 | ClusterID: req.Cluster, |
| 291 | ServerID: req.Server, |
| 292 | }) |
| 293 | if err != nil { |
| 294 | return nil, err |
| 295 | } |
| 296 | |
| 297 | return &rpcpb.AddBindRsp{}, nil |
| 298 | } |
| 299 | } |
| 300 | |
| 301 | func (s *metaService) Batch(ctx context.Context, req *rpcpb.BatchReq) (*rpcpb.BatchRsp, error) { |
| 302 | select { |
Callers
nothing calls this directly
Tested by
no test coverage detected