diff --git a/desktop/conf.dist/hue.ini b/desktop/conf.dist/hue.ini index cfde39391d8..8bb9b0842c0 100644 --- a/desktop/conf.dist/hue.ini +++ b/desktop/conf.dist/hue.ini @@ -935,8 +935,6 @@ tls=no # Settings for the Google Cloud lib # ------------------------------------------------------------------------ -# Maximum number of keys with specific directory prefix that can be deleted in a single bulk operation in GS. -## gs_bulk_delete_dir_keys_max_limit=100 [[gc_accounts]] [[[default]]] diff --git a/desktop/conf/pseudo-distributed.ini.tmpl b/desktop/conf/pseudo-distributed.ini.tmpl index 5cfb6bc4edb..dd48ad13fba 100644 --- a/desktop/conf/pseudo-distributed.ini.tmpl +++ b/desktop/conf/pseudo-distributed.ini.tmpl @@ -918,8 +918,6 @@ # Settings for the Google Cloud lib # ------------------------------------------------------------------------ - # Maximum number of keys with specific directory prefix that can be deleted in a single bulk operation in GS. - ## gs_bulk_delete_dir_keys_max_limit=100 [[gc_accounts]] [[[default]]] diff --git a/desktop/core/src/desktop/conf.py b/desktop/core/src/desktop/conf.py index dc117e27581..e99fd3c1b19 100644 --- a/desktop/core/src/desktop/conf.py +++ b/desktop/core/src/desktop/conf.py @@ -2591,13 +2591,6 @@ def get_ldap_bind_password(ldap_config): PERMISSION_ACTION_GS = "gs_access" -GS_BULK_DELETE_DIR_KEYS_MAX_LIMIT = Config( - help=_('Maximum number of keys with specific directory prefix that can be deleted in a single bulk operation in GS.'), - key='gs_bulk_delete_dir_keys_max_limit', - default=1000, - type=coerce_zero_or_positive_integer -) - GC_ACCOUNTS = UnspecifiedConfigSection( 'gc_accounts', help=_('One entry for each GC account'), diff --git a/desktop/core/src/desktop/lib/fs/gc/gs.py b/desktop/core/src/desktop/lib/fs/gc/gs.py index c7442af8a47..8cf3cc948c6 100644 --- a/desktop/core/src/desktop/lib/fs/gc/gs.py +++ b/desktop/core/src/desktop/lib/fs/gc/gs.py @@ -27,7 +27,7 @@ from boto.s3.prefix import Prefix from django.utils.translation import gettext as _ -from desktop.conf import PERMISSION_ACTION_GS, GS_BULK_DELETE_DIR_KEYS_MAX_LIMIT, is_raz_gs +from desktop.conf import PERMISSION_ACTION_GS, is_raz_gs from desktop.lib.fs.gc import GS_ROOT, abspath, parse_uri, translate_gs_error, normpath, join as gs_join from desktop.lib.fs.gc.gsstat import GSStat from desktop.lib.fs.gc.gsfile import open as gsfile_open @@ -310,15 +310,8 @@ def rmtree(self, path, skipTrash=True): else: # key.bucket.delete_keys() call is not supported from GS side # So, try deleting the all keys with directory prefix one by one - - # TODO: Check on the UI side if key count is greater than max limit and show nice notification. - deleted_dir_key_count = 0 for key in list(dir_keys): - if deleted_dir_key_count > GS_BULK_DELETE_DIR_KEYS_MAX_LIMIT.get(): - break - deleted_key = key.delete() - deleted_dir_key_count += 1 @translate_gs_error @auth_error_handler