mirror of
https://github.com/restic/restic.git
synced 2026-06-20 07:34:18 +00:00
backend/azure/gs/s3: remove unused Path() method
This commit is contained in:
@@ -34,7 +34,6 @@ type Backend struct {
|
||||
cfg Config
|
||||
container *azContainer.Client
|
||||
connections uint
|
||||
prefix string
|
||||
layout.Layout
|
||||
|
||||
accessTier blob.AccessTier
|
||||
@@ -224,11 +223,6 @@ func (be *Backend) Hasher() hash.Hash {
|
||||
return md5.New()
|
||||
}
|
||||
|
||||
// Path returns the path in the bucket that is used for this backend.
|
||||
func (be *Backend) Path() string {
|
||||
return be.prefix
|
||||
}
|
||||
|
||||
// useAccessTier determines whether to apply the configured access tier to a given file.
|
||||
// For archive access tier, only data files are stored using that class; metadata
|
||||
// must remain instantly accessible.
|
||||
|
||||
@@ -41,7 +41,6 @@ type gs struct {
|
||||
bucketName string
|
||||
region string
|
||||
bucket *storage.BucketHandle
|
||||
prefix string
|
||||
layout.Layout
|
||||
}
|
||||
|
||||
@@ -108,7 +107,6 @@ func open(cfg Config, rt http.RoundTripper) (*gs, error) {
|
||||
bucketName: cfg.Bucket,
|
||||
region: cfg.Region,
|
||||
bucket: gcsClient.Bucket(cfg.Bucket),
|
||||
prefix: cfg.Prefix,
|
||||
Layout: layout.NewDefaultLayout(cfg.Prefix, path.Join),
|
||||
}
|
||||
|
||||
@@ -189,11 +187,6 @@ func (be *gs) Hasher() hash.Hash {
|
||||
return md5.New()
|
||||
}
|
||||
|
||||
// Path returns the path in the bucket that is used for this backend.
|
||||
func (be *gs) Path() string {
|
||||
return be.prefix
|
||||
}
|
||||
|
||||
// Save stores data in the backend at the handle.
|
||||
func (be *gs) Save(ctx context.Context, h backend.Handle, rd backend.RewindReader) error {
|
||||
objName := be.Filename(h)
|
||||
|
||||
@@ -272,11 +272,6 @@ func (be *s3) Hasher() hash.Hash {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Path returns the path in the bucket that is used for this backend.
|
||||
func (be *s3) Path() string {
|
||||
return be.cfg.Prefix
|
||||
}
|
||||
|
||||
// useStorageClass returns whether file should be saved in the provided Storage Class
|
||||
// For archive storage classes, only data files are stored using that class; metadata
|
||||
// must remain instantly accessible.
|
||||
|
||||
Reference in New Issue
Block a user