|
@ -14,10 +14,10 @@ import ( |
|
|
) |
|
|
) |
|
|
|
|
|
|
|
|
type B2Sink struct { |
|
|
type B2Sink struct { |
|
|
client *b2.Client |
|
|
|
|
|
bucket string |
|
|
|
|
|
dir string |
|
|
|
|
|
filerSource *source.FilerSource |
|
|
|
|
|
|
|
|
client *b2.Client |
|
|
|
|
|
bucket string |
|
|
|
|
|
dir string |
|
|
|
|
|
filerSource *source.FilerSource |
|
|
isIncremental bool |
|
|
isIncremental bool |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
@ -38,7 +38,7 @@ func (g *B2Sink) IsIncremental() bool { |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
func (g *B2Sink) Initialize(configuration util.Configuration, prefix string) error { |
|
|
func (g *B2Sink) Initialize(configuration util.Configuration, prefix string) error { |
|
|
g.isIncremental = configuration.GetBool(prefix+"is_incremental") |
|
|
|
|
|
|
|
|
g.isIncremental = configuration.GetBool(prefix + "is_incremental") |
|
|
return g.initialize( |
|
|
return g.initialize( |
|
|
configuration.GetString(prefix+"b2_account_id"), |
|
|
configuration.GetString(prefix+"b2_account_id"), |
|
|
configuration.GetString(prefix+"b2_master_application_key"), |
|
|
configuration.GetString(prefix+"b2_master_application_key"), |
|
|