aboutsummaryrefslogtreecommitdiff
path: root/weed/replication/replicator.go
diff options
context:
space:
mode:
authorChris Lu <chris.lu@gmail.com>2020-04-05 13:11:43 -0700
committerChris Lu <chris.lu@gmail.com>2020-04-05 13:11:43 -0700
commit91da7057b1e4e0a623e2c2d273cce4a1426e69c1 (patch)
tree75bdd6b586bc4c23dfc567461e16d5c2d4583e21 /weed/replication/replicator.go
parent2d43f85577cb998656abf2525445b72fcd8cc48d (diff)
downloadseaweedfs-91da7057b1e4e0a623e2c2d273cce4a1426e69c1.tar.xz
seaweedfs-91da7057b1e4e0a623e2c2d273cce4a1426e69c1.zip
refactoring
Diffstat (limited to 'weed/replication/replicator.go')
-rw-r--r--weed/replication/replicator.go3
1 files changed, 1 insertions, 2 deletions
diff --git a/weed/replication/replicator.go b/weed/replication/replicator.go
index a91c2ddd3..1ed60f536 100644
--- a/weed/replication/replicator.go
+++ b/weed/replication/replicator.go
@@ -3,7 +3,6 @@ package replication
import (
"context"
"fmt"
- "path/filepath"
"strings"
"github.com/chrislusf/seaweedfs/weed/glog"
@@ -36,7 +35,7 @@ func (r *Replicator) Replicate(ctx context.Context, key string, message *filer_p
glog.V(4).Infof("skipping %v outside of %v", key, r.source.Dir)
return nil
}
- newKey := filepath.ToSlash(filepath.Join(r.sink.GetSinkToDirectory(), key[len(r.source.Dir):]))
+ newKey := util.Join(r.sink.GetSinkToDirectory(), key[len(r.source.Dir):])
glog.V(3).Infof("replicate %s => %s", key, newKey)
key = newKey
if message.OldEntry != nil && message.NewEntry == nil {