diff options
| author | Chris Lu <chris.lu@gmail.com> | 2018-10-06 13:01:38 -0700 |
|---|---|---|
| committer | Chris Lu <chris.lu@gmail.com> | 2018-10-06 13:01:38 -0700 |
| commit | 14858f6224a946c7b01d11552e47736bf42bba8b (patch) | |
| tree | b40d381df44d88f27e95a8d305246479eda5822a /weed/command/filer_replication.go | |
| parent | 04da4c8094db4fccece63d8c5d29aee00a47b0bc (diff) | |
| download | seaweedfs-14858f6224a946c7b01d11552e47736bf42bba8b.tar.xz seaweedfs-14858f6224a946c7b01d11552e47736bf42bba8b.zip | |
add logging
Diffstat (limited to 'weed/command/filer_replication.go')
| -rw-r--r-- | weed/command/filer_replication.go | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/weed/command/filer_replication.go b/weed/command/filer_replication.go index 5e41cbb55..02b6f70eb 100644 --- a/weed/command/filer_replication.go +++ b/weed/command/filer_replication.go @@ -1,12 +1,16 @@ package command import ( + "strings" + "github.com/chrislusf/seaweedfs/weed/glog" "github.com/chrislusf/seaweedfs/weed/replication" "github.com/chrislusf/seaweedfs/weed/server" "github.com/spf13/viper" - "strings" "github.com/chrislusf/seaweedfs/weed/replication/sink" + _ "github.com/chrislusf/seaweedfs/weed/replication/sink/s3sink" + _ "github.com/chrislusf/seaweedfs/weed/replication/sink/filersink" + _ "github.com/chrislusf/seaweedfs/weed/replication/sink/gcssink" ) func init() { @@ -72,6 +76,14 @@ func runFilerReplicate(cmd *Command, args []string) bool { } } + if dataSink == nil { + println("no data sink defined:") + for _, sk := range sink.Sinks { + println(" " + sk.GetName()) + } + return true + } + replicator := replication.NewReplicator(config.Sub("source.filer"), dataSink) for { |
