From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from firstgate.proxmox.com (firstgate.proxmox.com [212.224.123.68]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by lists.proxmox.com (Postfix) with ESMTPS id 574BA6C584 for ; Thu, 23 Sep 2021 07:25:29 +0200 (CEST) Received: from firstgate.proxmox.com (localhost [127.0.0.1]) by firstgate.proxmox.com (Proxmox) with ESMTP id 4E5BF20BC5 for ; Thu, 23 Sep 2021 07:25:29 +0200 (CEST) Received: from proxmox-new.maurer-it.com (proxmox-new.maurer-it.com [94.136.29.106]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by firstgate.proxmox.com (Proxmox) with ESMTPS id 0DD7020BB8 for ; Thu, 23 Sep 2021 07:25:28 +0200 (CEST) Received: from proxmox-new.maurer-it.com (localhost.localdomain [127.0.0.1]) by proxmox-new.maurer-it.com (Proxmox) with ESMTP id D26B844A55 for ; Thu, 23 Sep 2021 07:25:27 +0200 (CEST) Message-ID: <47542209-5eb6-3886-cd73-7d5618e51188@proxmox.com> Date: Thu, 23 Sep 2021 07:24:35 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:93.0) Gecko/20100101 Thunderbird/93.0 Content-Language: en-US To: Proxmox Backup Server development discussion , =?UTF-8?Q?Fabian_Gr=c3=bcnbichler?= References: <20210915134157.19762-1-f.gruenbichler@proxmox.com> <20210915134157.19762-7-f.gruenbichler@proxmox.com> <3411c837-865e-4f66-04e4-05e93b37c6c0@proxmox.com> <5ba7b5b3-3ab0-e7e8-3cb7-fe0c28b01ce9@proxmox.com> <1631778363.a4s2m09ziw.astroid@nora.none> From: Thomas Lamprecht In-Reply-To: <1631778363.a4s2m09ziw.astroid@nora.none> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-SPAM-LEVEL: Spam detection results: 0 AWL 0.251 Adjusted score from AWL reputation of From: address BAYES_00 -1.9 Bayes spam probability is 0 to 1% KAM_DMARC_STATUS 0.01 Test Rule for DKIM or SPF Failure with Strict Alignment NICE_REPLY_A -0.001 Looks like a legit reply (A) SPF_HELO_NONE 0.001 SPF: HELO does not publish an SPF Record SPF_PASS -0.001 SPF: sender matches SPF record Subject: Re: [pbs-devel] [pve-devel] [PATCH v2 proxmox-backup 06/10] sync: add group filtering X-BeenThere: pbs-devel@lists.proxmox.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Proxmox Backup Server development discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 23 Sep 2021 05:25:29 -0000 On 16.09.21 09:57, Fabian Gr=C3=BCnbichler wrote: > On September 16, 2021 9:38 am, Thomas Lamprecht wrote: >> On 16.09.21 09:19, Thomas Lamprecht wrote: >>>> if we want to make this configurable over the GUI, we probably w= ant to switch >>>> the job edit window to a tabpanel and add a second grid tab for = selecting >>>> the groups >>> we could also get away by adding it in the advanced section for now. >> >> I had a quick talk with Dominik which noticed me that there can be a l= ist of filters. >> >> So a separate tab-panel would seem OK to me. For UX I'd could imagine = having a >> "Add Filter" button that'd work out similarly to how we have the knet = link add in PVE >> cluster creation nowadays. In addition to that a preview window would = be nice to have, >> maybe similar to the "Prune now" one, but we only need the backup-grou= ps here not the >> full list of snapshots, so it would be relatively cheap to get. >> >=20 > yeah, that was kind of what I was going for - but with the added=20 > complexity of having different filter types with different=20 > "completion"/selection mechanisms > - the type filter has three static choices > - the regex is freeform (but maybe a dropdown with some common=20 > suggestions would be nice? those could also live in the docs though) yes, can be similar in spirit of what we do for the calendar-event schedu= le field. > - the group filter has a list of existing groups on the remote end to=20 > choose from, but also requires freeform entry as option (a group migh= t=20 > not exist yet, or not exist any longer, but still needs to be filtere= d=20 > for in the sync job, either to catch the group when it has been=20 > created, or to clean it up when it was previously synced, or just for= =20 > handling the currently set filters correctly) IMO that fits all in the approach with a [+] button, that could add a row= that looks somewhat like: Type: [ Combobox ] | [ INPUT ] Where the type combo-box allows to select for the regex-like filter or a editabled group selection combobox where one multi-select the existing but can also add others (i.e., only format not store/content validation).= >=20 > the last part I tried when writing v1, and it was quite the mess=20 > (Dominik's suggestion back then was to move it to a tab with a grid=20 > view, because the combobox selector was too limited IIRC). >=20 > a preview/dry-run for pull/sync would be nice in general, and shouldn't= =20 > be too hard to add. it would need to run in a worker though (as it need= s=20 > to query remote and local groups to decide what would be synced, even i= f=20 > the bulk work of actually downloading chunks is skipped). it could be=20 > done with the pull API without persisting the sync config, as those lin= e=20 > up 1:1. that's not required IMO, I would only show what the filter affects, that stuff is then not synced if already present on the remote does not matter= s much here on that level. > a preview of just the filterung with the already available (cached)=20 > remote groups is of course instant. could even be done GUI-side I guess= ,=20 > since the current filters are quite trivial to re-implement there. not = > sure how to fit that inside the already big dialogue tab though ;) Yeah, replicating the filter on the client side would be nice, single thi= ng that could cause trouble is difference between JS regex engines and the r= ust regex crate we use (the latter is probably much saner).