brimdata / zui

Zui is a powerful desktop application for exploring and working with data. The official front-end to the Zed lake.
https://www.brimdata.io/download/
Other
1.81k stars 132 forks source link

Multi-pool select to populate "from" pin #2562

Open philrz opened 2 years ago

philrz commented 2 years ago

As this issue is being filed, Brim is currently at commit 6eaaa54.

A community zync user pointed out how Zed can now target multiple pools in a single from (https://github.com/brimdata/zed/issues/3008) therefore it would be great for the app to have a multi-select feature in the pool pickers to construct from pins that target the multiple pools.

philrz commented 10 months ago

Another community user bumped into the need for this in a recent Slack thread. In their own words:

one issue i am having is combing two pools (two separate security attacks in the lake) the zui drop down appears to pin only one pool at a time. Unless I missed something in the zui interface

We walked them through how they could right-click on any existing pin, select Delete, and then manually type out a multi-pool wildcard like from * or a regexp pattern like from /my_pool_1|my_pool_2/ at the top of their Zed program in the editor. However, seeing the experience through their eyes reminded us again that we could have saved them from asking if there was some intuitive UX added here.

Here's some specific ideas based on what I can observe in current Zui as of commit b413f0c as shown in the video below.

  1. The pools list in the left sidebar already allows shift-click to highlight multiple pools followed by a Delete option that, when selected, deletes all the highlighted pools. However, right now after multi-click selection, right-click selection of Use as from pin only populates the last-clicked pool in the created from pin. Hopefully this could be easily adjusted to instead create a from /my_pool_1|my_pool_2/-style pin that holds the name of all the selected pools.

  2. Right now after clicking + to open a new Query Session tab, a single-pool from pin is created as soon as a single pool name is single-clicked in the list shown below No Pool Specified. However, this could perhaps be modified to allow multi-pool selection and right-click from /my_pool_1|my_pool_2/-style pin creation like proposed in the prior bullet.

  3. Once such multi-pool pins exist, it seems we'd want to add an Edit option to add/delete pools from the list when the user left-clicks on such a pin, similar to the Edit option that already exists for Time Range pins.

  4. Since the from * wildcard variant may be handy at times, we could perhaps come up with easy ways to invoke this. One would be that if a user does a "select all" on a pool list, we could notice this as a special case such that a right-click menu could offer a "from * pin" option (in addition to still offering to make one made up of the names of all pools listed out |-separated). Perhaps we could also offer this option if the user right-clicks in the blank area of the pools list in the left sidebar.

https://github.com/brimdata/zui/assets/5934157/621dd45d-0356-4a24-9bc1-5ee5d72e88af