From: Christian Ebner <c.ebner@proxmox.com>
To: pbs-devel@lists.proxmox.com
Subject: [pbs-devel] [PATCH proxmox-backup 1/1] fix #7078: ui: exponse DeleteObjects via DeleteObject provider quirk
Date: Tue, 27 Jan 2026 13:27:12 +0100 [thread overview]
Message-ID: <20260127122712.505774-5-c.ebner@proxmox.com> (raw)
In-Reply-To: <20260127122712.505774-1-c.ebner@proxmox.com>
The S3 compatible storage API for Google Cloud Storage does not
implement deleteObjects api method, even if mentioned in the docs,
although erratic [0] (incorrect anchor and docs switched with delete
object ones at the time of last check).
Provide users a workaround by allowing to set the provider quirk to
perform individual deleteObject calls instead of deleteObjects on the
list of objects to delete.
The same quirk might also be used when delete object calls are
monetarily cheaper as compared to the multi object deletion, at the
cost of additional api calls and all the added delays that implies.
As suggested when the provider quirks first got applied in [1],
instead of exposing the additional quirk via an added entry to the
dropdown selector, move to a fieldset with nested checkboxes for
better accessibility.
[0] https://cloud.google.com/distributed-cloud/hosted/docs/latest/gdch/apis/service/storage/storage-s3-rest-api#DeleteObjects
[1] https://lore.proxmox.com/pbs-devel/175440823229.3188344.11268683178675917633.b4-ty@proxmox.com/
Fixes: https://bugzilla.proxmox.com/show_bug.cgi?id=7078
Signed-off-by: Christian Ebner <c.ebner@proxmox.com>
---
www/window/S3ClientEdit.js | 57 ++++++++++++++++++++++++++++----------
1 file changed, 43 insertions(+), 14 deletions(-)
diff --git a/www/window/S3ClientEdit.js b/www/window/S3ClientEdit.js
index 8862683b8..c7e8ade1f 100644
--- a/www/window/S3ClientEdit.js
+++ b/www/window/S3ClientEdit.js
@@ -135,20 +135,6 @@ Ext.define('PBS.window.S3ClientEdit', {
emptyText: gettext('Unlimited'),
submitAutoScaledSizeUnit: true,
},
- {
- xtype: 'proxmoxKVComboBox',
- name: 'provider-quirks',
- fieldLabel: gettext('Provider Quirks'),
- value: '__default__',
- defaultValue: '__default__',
- comboItems: [
- ['__default__', gettext('None (default)')],
- ['skip-if-none-match-header', gettext('Skip If-None-Match header')],
- ],
- cbind: {
- deleteEmpty: '{!isCreate}',
- },
- },
],
advancedColumn2: [
{
@@ -166,6 +152,27 @@ Ext.define('PBS.window.S3ClientEdit', {
submitAutoScaledSizeUnit: true,
},
],
+ advancedColumnB: [
+ {
+ xtype: 'fieldset',
+ name: 'provider-quirks',
+ fieldLabel: gettext('Provider Quirks'),
+ items: [
+ {
+ xtype: 'checkbox',
+ name: 'skip-if-none-match-header',
+ fieldLabel: gettext('Skip If-None-Match header'),
+ labelWidth: 200,
+ },
+ {
+ xtype: 'checkbox',
+ name: 'delete-objects-via-delete-object',
+ fieldLabel: gettext('DeleteObjects via deleteObject'),
+ labelWidth: 200,
+ },
+ ],
+ },
+ ],
},
getValues: function () {
@@ -193,6 +200,28 @@ Ext.define('PBS.window.S3ClientEdit', {
delete values['secret-key'];
}
+ let quirks = [];
+ ['skip-if-none-match-header', 'delete-objects-via-delete-object'].forEach((quirk) => {
+ if (values[quirk]) {
+ quirks.push(quirk);
+ delete values[quirk];
+ }
+ });
+
+ if (quirks.length > 0) {
+ values['provider-quirks'] = quirks;
+ } else if (!me.isCreate) {
+ values.delete.push('provider-quirks');
+ }
+
return values;
},
+
+ setValues: function (values) {
+ if (values['provider-quirks']) {
+ values['provider-quirks'].forEach((quirk) => (values[quirk] = true));
+ }
+
+ this.callParent(arguments);
+ },
});
--
2.47.3
_______________________________________________
pbs-devel mailing list
pbs-devel@lists.proxmox.com
https://lists.proxmox.com/cgi-bin/mailman/listinfo/pbs-devel
prev parent reply other threads:[~2026-01-27 12:27 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-01-27 12:27 [pbs-devel] [PATCH proxmox{, -backup} 0/4] fix #7078: Add quirk for providers not supporting deleteObjects Christian Ebner
2026-01-27 12:27 ` [pbs-devel] [PATCH proxmox 1/3] s3-client: factor out optional response header parsing Christian Ebner
2026-01-27 12:27 ` [pbs-devel] [PATCH proxmox 2/3] s3-client: parse and return headers for delete object response Christian Ebner
2026-01-27 12:27 ` [pbs-devel] [PATCH proxmox 3/3] s3-client: extend provider quirks by delete objects via delete object Christian Ebner
2026-01-27 12:27 ` Christian Ebner [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260127122712.505774-5-c.ebner@proxmox.com \
--to=c.ebner@proxmox.com \
--cc=pbs-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.