mirror of
https://github.com/featurebasedb/featurebase.git
synced 2026-08-28 10:54:59 +00:00
ignore checksum on single node clusters
This commit is contained in:
parent
a89af88d47
commit
4035763ef4
1 changed files with 6 additions and 2 deletions
|
|
@ -1245,13 +1245,17 @@ func (s *FragmentSyncer) isClosing() bool {
|
|||
func (s *FragmentSyncer) SyncFragment() error {
|
||||
// Determine replica set.
|
||||
nodes := s.Cluster.FragmentNodes(s.Fragment.DB(), s.Fragment.Slice())
|
||||
|
||||
if len(nodes) == 1 {
|
||||
//fmt.Println("no place to replicate", s.Fragment.DB(), s.Fragment.Frame(), s.Fragment.Slice())
|
||||
return nil
|
||||
}
|
||||
// Create a set of blocks.
|
||||
blockSets := make([][]FragmentBlock, 0, len(nodes))
|
||||
for _, node := range nodes {
|
||||
// Read local blocks.
|
||||
if node.Host == s.Host {
|
||||
blockSets = append(blockSets, s.Fragment.Blocks())
|
||||
b := s.Fragment.Blocks()
|
||||
blockSets = append(blockSets, b)
|
||||
continue
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue