From a76ce1f704ad8ed21d9eecd7390172505fc6f734 Mon Sep 17 00:00:00 2001 From: jkoberg Date: Wed, 26 Jun 2024 11:19:14 +0200 Subject: [PATCH] feat(decomposedfs): expose disable-versioning Signed-off-by: jkoberg --- changelog/unreleased/expose-disable-versioning.md | 5 +++++ pkg/storage/utils/decomposedfs/decomposedfs.go | 9 +++++---- pkg/storage/utils/decomposedfs/options/options.go | 2 ++ 3 files changed, 12 insertions(+), 4 deletions(-) create mode 100644 changelog/unreleased/expose-disable-versioning.md diff --git a/changelog/unreleased/expose-disable-versioning.md b/changelog/unreleased/expose-disable-versioning.md new file mode 100644 index 0000000000..ab4bfe8ce8 --- /dev/null +++ b/changelog/unreleased/expose-disable-versioning.md @@ -0,0 +1,5 @@ +Enhancement: Expose disable-versioning configuration option + +This PR exposes the disable-versioning configuration option to the user. This option allows the user to disable versioning for the storage-providers. + +https://github.com/cs3org/reva/pull/4742 diff --git a/pkg/storage/utils/decomposedfs/decomposedfs.go b/pkg/storage/utils/decomposedfs/decomposedfs.go index fd8e9696d1..8b53a82d3b 100644 --- a/pkg/storage/utils/decomposedfs/decomposedfs.go +++ b/pkg/storage/utils/decomposedfs/decomposedfs.go @@ -157,10 +157,11 @@ func NewDefault(m map[string]interface{}, bs tree.Blobstore, es events.Stream) ( } aspects := aspects.Aspects{ - Lookup: lu, - Tree: tp, - Permissions: permissions.NewPermissions(node.NewPermissions(lu), permissionsSelector), - EventStream: es, + Lookup: lu, + Tree: tp, + Permissions: permissions.NewPermissions(node.NewPermissions(lu), permissionsSelector), + EventStream: es, + DisableVersioning: o.DisableVersioning, } return New(o, aspects) diff --git a/pkg/storage/utils/decomposedfs/options/options.go b/pkg/storage/utils/decomposedfs/options/options.go index e68bd73d06..61355c935e 100644 --- a/pkg/storage/utils/decomposedfs/options/options.go +++ b/pkg/storage/utils/decomposedfs/options/options.go @@ -90,6 +90,8 @@ type Options struct { MaxConcurrency int `mapstructure:"max_concurrency"` MaxQuota uint64 `mapstructure:"max_quota"` + + DisableVersioning bool `mapstructure:"disable_versioning"` } // AsyncPropagatorOptions holds the configuration for the async propagator