mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2024-01-19 02:48:24 +00:00
add logging
This commit is contained in:
parent
04da4c8094
commit
14858f6224
|
@ -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 {
|
||||
|
|
Loading…
Reference in a new issue