From a46baf768558d1087ebe789305894dd207ff07e1 Mon Sep 17 00:00:00 2001 From: Alexander Neumann Date: Wed, 7 Jun 2017 20:51:45 +0200 Subject: [PATCH] s3: Remove cache --- src/restic/backend/s3/s3.go | 20 ++++++++------------ 1 file changed, 8 insertions(+), 12 deletions(-) diff --git a/src/restic/backend/s3/s3.go b/src/restic/backend/s3/s3.go index 767c21dc0..dde45b789 100644 --- a/src/restic/backend/s3/s3.go +++ b/src/restic/backend/s3/s3.go @@ -8,7 +8,6 @@ import ( "path" "restic" "strings" - "sync" "time" "restic/backend" @@ -23,12 +22,10 @@ const connLimit = 10 // s3 is a backend which stores the data on an S3 endpoint. type s3 struct { - client *minio.Client - sem *backend.Semaphore - bucketname string - prefix string - cacheMutex sync.RWMutex - cacheObjSize map[string]int64 + client *minio.Client + sem *backend.Semaphore + bucketname string + prefix string backend.Layout } @@ -53,11 +50,10 @@ func Open(cfg Config) (restic.Backend, error) { } be := &s3{ - client: client, - sem: sem, - bucketname: cfg.Bucket, - prefix: cfg.Prefix, - cacheObjSize: make(map[string]int64), + client: client, + sem: sem, + bucketname: cfg.Bucket, + prefix: cfg.Prefix, } client.SetCustomTransport(backend.Transport())