Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Keywords: etcd, datacoord, datanode

Released:

Summary

DataCoord register channels on etcd and DataNode watch etcd to do watch/release operations.

Motivation

There are several problems when DataCoord sends the WatchDmChannel to the DataNode through grpc:

  1. If datacoord cannot connect to datanode, it needs to try again. Retrial failure requires reallocation, which may result in duplicate watches.
  2. If datacoord has load balance, it needs to send unwatch and watch request, which may also lead to failure and retrying.

Public Interfaces

Remove WatchDmChannel of DataNode.

Design Details

Etcd key:channel / [nodeID] / [channelName],value: ChannelInfo

...

  1. When DataNode starts, the channel of this Node on etcd must be empty, because the nodeID is incremented.
  2. When DataNode receives an Add event, execute WatchChannel.
  3. When DataNode receives Delete event, execute ReleaseChannel.

Test Plan