@@ -33,12 +33,12 @@ import (
33
33
)
34
34
35
35
// RemoveBucketReplication removes a replication config on an existing bucket.
36
- func (c Client ) RemoveBucketReplication (ctx context.Context , bucketName string ) error {
36
+ func (c * Client ) RemoveBucketReplication (ctx context.Context , bucketName string ) error {
37
37
return c .removeBucketReplication (ctx , bucketName )
38
38
}
39
39
40
40
// SetBucketReplication sets a replication config on an existing bucket.
41
- func (c Client ) SetBucketReplication (ctx context.Context , bucketName string , cfg replication.Config ) error {
41
+ func (c * Client ) SetBucketReplication (ctx context.Context , bucketName string , cfg replication.Config ) error {
42
42
// Input validation.
43
43
if err := s3utils .CheckValidBucketName (bucketName ); err != nil {
44
44
return err
@@ -53,7 +53,7 @@ func (c Client) SetBucketReplication(ctx context.Context, bucketName string, cfg
53
53
}
54
54
55
55
// Saves a new bucket replication.
56
- func (c Client ) putBucketReplication (ctx context.Context , bucketName string , cfg replication.Config ) error {
56
+ func (c * Client ) putBucketReplication (ctx context.Context , bucketName string , cfg replication.Config ) error {
57
57
// Get resources properly escaped and lined up before
58
58
// using them in http request.
59
59
urlValues := make (url.Values )
@@ -86,7 +86,7 @@ func (c Client) putBucketReplication(ctx context.Context, bucketName string, cfg
86
86
}
87
87
88
88
// Remove replication from a bucket.
89
- func (c Client ) removeBucketReplication (ctx context.Context , bucketName string ) error {
89
+ func (c * Client ) removeBucketReplication (ctx context.Context , bucketName string ) error {
90
90
// Get resources properly escaped and lined up before
91
91
// using them in http request.
92
92
urlValues := make (url.Values )
@@ -107,7 +107,7 @@ func (c Client) removeBucketReplication(ctx context.Context, bucketName string)
107
107
108
108
// GetBucketReplication fetches bucket replication configuration.If config is not
109
109
// found, returns empty config with nil error.
110
- func (c Client ) GetBucketReplication (ctx context.Context , bucketName string ) (cfg replication.Config , err error ) {
110
+ func (c * Client ) GetBucketReplication (ctx context.Context , bucketName string ) (cfg replication.Config , err error ) {
111
111
// Input validation.
112
112
if err := s3utils .CheckValidBucketName (bucketName ); err != nil {
113
113
return cfg , err
@@ -124,7 +124,7 @@ func (c Client) GetBucketReplication(ctx context.Context, bucketName string) (cf
124
124
}
125
125
126
126
// Request server for current bucket replication config.
127
- func (c Client ) getBucketReplication (ctx context.Context , bucketName string ) (cfg replication.Config , err error ) {
127
+ func (c * Client ) getBucketReplication (ctx context.Context , bucketName string ) (cfg replication.Config , err error ) {
128
128
// Get resources properly escaped and lined up before
129
129
// using them in http request.
130
130
urlValues := make (url.Values )
@@ -153,7 +153,7 @@ func (c Client) getBucketReplication(ctx context.Context, bucketName string) (cf
153
153
}
154
154
155
155
// GetBucketReplicationMetrics fetches bucket replication status metrics
156
- func (c Client ) GetBucketReplicationMetrics (ctx context.Context , bucketName string ) (s replication.Metrics , err error ) {
156
+ func (c * Client ) GetBucketReplicationMetrics (ctx context.Context , bucketName string ) (s replication.Metrics , err error ) {
157
157
// Input validation.
158
158
if err := s3utils .CheckValidBucketName (bucketName ); err != nil {
159
159
return s , err
@@ -199,7 +199,7 @@ func mustGetUUID() string {
199
199
200
200
// ResetBucketReplication kicks off replication of previously replicated objects if ExistingObjectReplication
201
201
// is enabled in the replication config
202
- func (c Client ) ResetBucketReplication (ctx context.Context , bucketName string , olderThan time.Duration ) (rID string , err error ) {
202
+ func (c * Client ) ResetBucketReplication (ctx context.Context , bucketName string , olderThan time.Duration ) (rID string , err error ) {
203
203
rID = mustGetUUID ()
204
204
_ , err = c .resetBucketReplicationOnTarget (ctx , bucketName , olderThan , "" , rID )
205
205
if err != nil {
@@ -210,14 +210,14 @@ func (c Client) ResetBucketReplication(ctx context.Context, bucketName string, o
210
210
211
211
// ResetBucketReplication kicks off replication of previously replicated objects if ExistingObjectReplication
212
212
// is enabled in the replication config
213
- func (c Client ) ResetBucketReplicationOnTarget (ctx context.Context , bucketName string , olderThan time.Duration , tgtArn string ) (rinfo replication.ResyncTargetsInfo , err error ) {
213
+ func (c * Client ) ResetBucketReplicationOnTarget (ctx context.Context , bucketName string , olderThan time.Duration , tgtArn string ) (rinfo replication.ResyncTargetsInfo , err error ) {
214
214
rID := mustGetUUID ()
215
215
return c .resetBucketReplicationOnTarget (ctx , bucketName , olderThan , tgtArn , rID )
216
216
}
217
217
218
218
// ResetBucketReplication kicks off replication of previously replicated objects if ExistingObjectReplication
219
219
// is enabled in the replication config
220
- func (c Client ) resetBucketReplicationOnTarget (ctx context.Context , bucketName string , olderThan time.Duration , tgtArn string , resetID string ) (rinfo replication.ResyncTargetsInfo , err error ) {
220
+ func (c * Client ) resetBucketReplicationOnTarget (ctx context.Context , bucketName string , olderThan time.Duration , tgtArn string , resetID string ) (rinfo replication.ResyncTargetsInfo , err error ) {
221
221
// Input validation.
222
222
if err = s3utils .CheckValidBucketName (bucketName ); err != nil {
223
223
return
0 commit comments