Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Discover][Observability] Register Logs Explorer top navigation #182230

Closed
gbamparop opened this issue May 1, 2024 · 23 comments · Fixed by #198987
Closed

[Discover][Observability] Register Logs Explorer top navigation #182230

gbamparop opened this issue May 1, 2024 · 23 comments · Fixed by #198987
Assignees
Labels
Project:OneDiscover Enrich Discover with contextual awareness Team:obs-ux-logs Observability Logs User Experience Team

Comments

@gbamparop
Copy link
Contributor

gbamparop commented May 1, 2024

📓 Summary

The top navigation in Logs Explorer includes links to the Observability onboarding guides as well as actions to create rules and SLOs while maintaining context. This functionality will be moved to Discover for Observability projects.

image

✔ Acceptance Criteria

  • The top navigation bar should be registered as a feature using the DiscoverFeaturesRegistry provided by the discover-shared plugin using the newly created extension point.
  • The top navigation bar in Discover will contain a link to add data through the Observability onboarding guides in Observability projects
  • The top navigation bar in Discover will contain a link to the Data sets page.
  • The top navigation bar in Discover will contain actions to create custom threshold rules and SLOs in Observability projects

❓ Open questions

  • Will the link to the feedback form be part of the new bar?
@gbamparop gbamparop added Team:obs-ux-logs Observability Logs User Experience Team Project:OneDiscover Enrich Discover with contextual awareness labels May 1, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/obs-ux-logs-team (Team:obs-ux-logs)

@tonyghiani tonyghiani self-assigned this May 2, 2024
@tonyghiani
Copy link
Contributor

Will the link to the feedback form be part of the new bar?

@gbamparop My take is that we should keep it, aligning to a single actions design as the one we used for the project view since the beginning:

Screenshot 2024-05-02 at 08 56 07

This also means moving the beta badge (for the time we will still keep it), but the effort doesn't change since we already have this template in place for the project view top bar. Wdyt?

@gbamparop
Copy link
Contributor Author

@ninoslavmiskovic @alex-fedotyev what are your thoughts about having a different form per project type? The goal in this case would be to get feedback for the logs flavour.

@ninoslavmiskovic
Copy link
Contributor

ninoslavmiskovic commented May 3, 2024

@gbamparop Do you mean per data type/source e.g. when users are exploring logs then they get one survey, and when they are exploring security events in Discover, then they get another ?

This might be too granular. I think we should have one form for "One discover" and then we can have a question.. What kind of data are you exploring.. Logs, Metrics, Traces etc...

@ninoslavmiskovic
Copy link
Contributor

Be aware that serverless has an overall "Give feedback"

This means that there are 2 x Give feedback..

We need to consider a better UI for this.

Image

@tonyghiani
Copy link
Contributor

@gbamparop I agree having two feedback CTA might be confusing, shall we remove the current link we have for Logs Explorer in favour of a One Discover link once the MVP is ready as @ninoslavmiskovic suggested?

@tonyghiani
Copy link
Contributor

tonyghiani commented May 7, 2024

Another point to discuss is whether we want to keep the link "Open to Discover".
With the solution navbar in place and the tabs for "Discover" and "Logs Explorer" (which we'll soon remove), it seems redundant to have this link in place, although it's true it has a different function than the Discover tab navigation, since this link open the current selection and filters in the Discover tab.

I don't think there are many more benefits now in bringing the user in vanilla Discover switching tab with this link, given also that we'll soon have a single experience for all of this. My 2 cents is that we can remove it, wdyt? @gbamparop @ruflin

@ruflin
Copy link
Contributor

ruflin commented May 7, 2024

I suggest to remove the Give Feedback block all together as it was used rarely so far.

If a user clicks on Discover tab now, is the behaviour identical to the "Open in Discover"? If yes, agree on removing it.

@flash1293
Copy link
Contributor

I agree that having two buttons up there is a little weird, but the behavior of keeping the current filters is pretty nice.

Also we don't know whether we have the two tabs yet in all cases (on stateful it relies on the new navigation). Is it a lot of work to keep the current "Open in Discover" logic for now? If not, I think it's OK just retaining it and removing it with the final merge of the apps.

@tonyghiani
Copy link
Contributor

If a user clicks on Discover tab now, is the behaviour identical to the "Open in Discover"? If yes, agree on removing it.

@ruflin

  • Click on the tab => Load discover with default data view and no filters
  • Click on the "Open in Discover" link => Load discover with current Logs Explorer search (dataset + filter).

Different behaviours, although it's not specified in any way that "Open in Discover" moves to discover with the current search from Logs Explorer. I find it quite confusing now that they appear on the same topnav.

@gbamparop
Copy link
Contributor Author

gbamparop commented May 7, 2024

This might be too granular. I think we should have one form for "One discover" and then we can have a question.. What kind of data are you exploring.. Logs, Metrics, Traces etc...

+1 if we can have one form. Good point for serverless, we could also consider removing it as Nicolas suggested, we haven't received many responses yet but we have recently changed the email validation settings.

removing it with the final merge of the apps.

This sounds good to me.

@ruflin
Copy link
Contributor

ruflin commented May 8, 2024

I would bring the behaviour from "Open in Discover" to "Click on Tab" if possible that users keep state and remove the button. Is this complex to do? Otherwise, lets keep it for now temporary until the two apps have merged.

@tonyghiani
Copy link
Contributor

I would bring the behaviour from "Open in Discover" to "Click on Tab" if possible that users keep state and remove the button. Is this complex to do? Otherwise, lets keep it for now temporary until the two apps have merged.

This makes a lot of sense, although @flash1293 made a good point about still having the classic navigation bar without the tabs, so let's keep it temporary until the merge 👌

@tonyghiani
Copy link
Contributor

I now spent some time on the codebase for this task, here are some considerations that made me consider postponing this work until we remove the tabs for some limits it currently has:

1. There are currently 4 different scenarios for displaying the top nav. The current implementation between for tabs and navbar menu treats it as a unique topbar, so we cannot act and factor out the specific navbar menu without affecting the tabs' implementation.

Tabs Navbar menu
ProjectNav - Search - Discover Discover
ProjectNav - Obs - Discover Discover
ProjectNav - Obs - Logs Explorer Logs Explorer
ClassicNav - Obs - Logs Explorer Logs Explorer

This requires quite a lot of work to split the tabs and the navbar menu customization.

2. The logic to keep the filters applied on the "Open in Discover" menu item strongly depends on the data source selection and the Logs Explorer state logic, trying to register it as an external menu item in Discover would over-engineer the implementation, which I believe is not worth to mess it up now since it does its work well and will soon be removed.

3. With the context awareness in place, this observability navbar menu will become one of the available menus directly moved into Discover, it doesn't require the overhead of registering this externally since we'll be able to know in which context it should be displayed directly in Discover.

As soon as we remove the tabs, we'll need to touch this part anyway to resolve the Obs logs navbar menu, but it will be much easier since it will just result in a cut/paste work from Logs Explorer to Discover for the remaining menu items.

Also, all the above-described work wouldn't benefit the user experience if we do it now as there are no perceived changes on the UX, but it would just add more noise we have to clean up when removing the tabs.

My take is that we should pause this work until we move forward with the next steps on the One Discover context resolution, please let me know if there is any concern around this.

@ninoslavmiskovic
Copy link
Contributor

I think it makes sense to not invest in this until we are merging Log Explorer and Discover as part of "One Discover", and then revisit it again.

@tonyghiani
Copy link
Contributor

@gbamparop @ninoslavmiskovic now that the contextual awareness architecture is in place, we can consider moving on with this. There are some changes in terms of scope:

  • It requires implementing the extension point for the top nav menu.
  • The entries will not be moved from Logs Explorer (as the awareness architecture is not applied to the discover embeddable), but we can factor out the logic around the menu entries we need and re-use it in both apps.

The menu entries for logs should be applied one the logs data source context is resolved, and those are:

  • Add data: The top navigation bar in Discover will contain a link to add data through the Observability onboarding guides in Observability projects
  • Alerts: The top navigation bar in Discover will contain actions to create custom threshold rules and SLOs in Observability projects

Is this still relevant? Is there any change to the above definition?
From a design perspective, IMO those entries should not be prepended before the saved search menu entries, but appended at the end after with a separator.

@gbamparop
Copy link
Contributor Author

  • Add data: The top navigation bar in Discover will contain a link to add data through the Observability onboarding guides in Observability projects
  • Alerts: The top navigation bar in Discover will contain actions to create custom threshold rules and SLOs in Observability projects

Is this still relevant? Is there any change to the above definition?

These are the two items that need changing. We can explore whether we can have an extension point for these individual items instead of the whole top navigation bar. This can mean that for Alerts the extension point would be the popup that opens when the Alerts menu item is clicked. For Add data I would imagine having an extension where solutions can change the link to point to their onboarding flows. cc @kertal

@kertal
Copy link
Member

kertal commented Aug 14, 2024

I'm interested how the Add data functionality should look like, so this is what we currently have in Discover

Image

This is how it looks like in Logs explorer

Image

We can definitely make the right side of the toolbar / top navigation bar configureable , this is something @davismcphee and I discussed yesterday, however this definitely needs design input, should it be another button, a link, something different?

FYI @MichaelMarcialis @andreadelrio @ryankeairns

@tonyghiani
Copy link
Contributor

@kertal What I was thinking of is to use a separator between the saved search control and custom menu items:

Screenshot 2024-08-14 at 10 34 21

It doesn't convince me 100% having twice the solid button (the screen is purely copy/paste of some html), so we surely need some design input 👍

@ninoslavmiskovic
Copy link
Contributor

Hey team,

This needs not only design but specifications, as per the One Discover program the stage of this initiative is "Not started", so let's start a PRD with relevant user stories etc. before we move forward and pass the specification to begin designing. I will add it to our sync.

@ninoslavmiskovic
Copy link
Contributor

Hey @timductive I unassigned me here, because this is O11y that has the responsibility to register. I am on the work for the actual extension point.

@gbamparop
Copy link
Contributor Author

The dependency has now been resolved and the extension point is available.

@tonyghiani
Copy link
Contributor

tonyghiani commented Nov 4, 2024

@LucaWintergerst @gbamparop Given the resolved dependency and that we can start working on this, a couple of unresolved questions:

  • The main CTA can be a single button. In Discover is the "Save" button for saved searches, while for Logs Explorer is a "Add data" link to the onboarding flow. We cannot keep both, I'd say we could add the "Add data" link as a custom entry in the app menu, keeping the Save button consistent with the other views.
  • In Logs Explorer we have a link to a feedback form. We had conversations about this and it felt redundant to have it again in Discover, do we agree on removing it?

tonyghiani added a commit to tonyghiani/kibana that referenced this issue Nov 14, 2024
…ic#198987)

## 📓 Summary

Closes elastic#182230

This work introduces a new observability root profile and uses the new
extension point to register custom actions on the app menu.
The registered actions and link will appear only with the new project
navigation enabled on an Observability project:
- A link to the data sets quality page
- On the alerts sub menu...
- replace the default search rule creation with the observability custom
threshold rule
  - add an entry to directly create an SLO for the current search

To access the SLO capabilities without breaking the dependencies
hierarchy of the new sustainable architecture, the feature is registered
by the common plugin `discover-shared` in SLO and consumed then by
Discover using the IoC principle.

## 🖼️ Screenshots

### Observability project solution - show new menu

<img width="3004" alt="Screenshot 2024-11-06 at 12 37 02"
src="https://github.com/user-attachments/assets/d70b532d-1889-4d5b-b2ee-de2f048560f4">

### Search project solution - hide new menu

<img width="3006" alt="Screenshot 2024-11-06 at 12 36 19"
src="https://github.com/user-attachments/assets/660893c3-f6b5-4b06-b8de-50a61a6bdb98">

### Default navigation mode - hide new menu

<img width="3002" alt="Screenshot 2024-11-06 at 12 35 43"
src="https://github.com/user-attachments/assets/674c5a08-0084-40e5-ae34-a56c363cacce">

## 🎥  Demo

https://github.com/user-attachments/assets/104e6074-0401-4fd2-a8e6-8b05f2c070d7

---------

Co-authored-by: Marco Antonio Ghiani <[email protected]>
Co-authored-by: kibanamachine <[email protected]>
(cherry picked from commit 9d38922)

# Conflicts:
#	x-pack/plugins/observability_solution/slo/public/pages/slo_edit/shared_flyout/get_create_slo_flyout.tsx
#	x-pack/plugins/observability_solution/slo/public/plugin.ts
#	x-pack/plugins/observability_solution/slo/public/types.ts
#	x-pack/plugins/observability_solution/slo/tsconfig.json
#	x-pack/test_serverless/functional/test_suites/common/discover_ml_uptime/discover/search_source_alert.ts
tonyghiani added a commit that referenced this issue Nov 14, 2024
…198987) (#200145)

# Backport

This will backport the following commits from `main` to `8.x`:
- [[One Discover] Add app menu actions for Observability projects
(#198987)](#198987)

<!--- Backport version: 8.9.8 -->

### Questions ?
Please refer to the [Backport tool
documentation](https://github.com/sqren/backport)

<!--BACKPORT [{"author":{"name":"Marco Antonio
Ghiani","email":"[email protected]"},"sourceCommit":{"committedDate":"2024-11-14T10:00:38Z","message":"[One
Discover] Add app menu actions for Observability projects
(#198987)\n\n## 📓 Summary\r\n\r\nCloses #182230 \r\n\r\nThis work
introduces a new observability root profile and uses the
new\r\nextension point to register custom actions on the app
menu.\r\nThe registered actions and link will appear only with the new
project\r\nnavigation enabled on an Observability project:\r\n- A link
to the data sets quality page\r\n- On the alerts sub menu...\r\n-
replace the default search rule creation with the observability
custom\r\nthreshold rule\r\n - add an entry to directly create an SLO
for the current search\r\n\r\nTo access the SLO capabilities without
breaking the dependencies\r\nhierarchy of the new sustainable
architecture, the feature is registered\r\nby the common plugin
`discover-shared` in SLO and consumed then by\r\nDiscover using the IoC
principle.\r\n\r\n## 🖼️ Screenshots\r\n\r\n### Observability project
solution - show new menu\r\n\r\n<img width=\"3004\" alt=\"Screenshot
2024-11-06 at 12 37
02\"\r\nsrc=\"https://github.com/user-attachments/assets/d70b532d-1889-4d5b-b2ee-de2f048560f4\">\r\n\r\n###
Search project solution - hide new menu\r\n\r\n<img width=\"3006\"
alt=\"Screenshot 2024-11-06 at 12 36
19\"\r\nsrc=\"https://github.com/user-attachments/assets/660893c3-f6b5-4b06-b8de-50a61a6bdb98\">\r\n\r\n###
Default navigation mode - hide new menu\r\n\r\n<img width=\"3002\"
alt=\"Screenshot 2024-11-06 at 12 35
43\"\r\nsrc=\"https://github.com/user-attachments/assets/674c5a08-0084-40e5-ae34-a56c363cacce\">\r\n\r\n##
🎥
Demo\r\n\r\n\r\nhttps://github.com/user-attachments/assets/104e6074-0401-4fd2-a8e6-8b05f2c070d7\r\n\r\n---------\r\n\r\nCo-authored-by:
Marco Antonio Ghiani <[email protected]>\r\nCo-authored-by:
kibanamachine
<[email protected]>","sha":"9d38922401d0bbd0d95d750f68fec77ca22758fb","branchLabelMapping":{"^v9.0.0$":"main","^v8.17.0$":"8.x","^v(\\d+).(\\d+).\\d+$":"$1.$2"}},"sourcePullRequest":{"labels":["release_note:skip","v9.0.0","backport:prev-minor","ci:project-deploy-observability","Team:obs-ux-logs","Team:obs-ux-management","Project:OneDiscover"],"number":198987,"url":"https://github.com/elastic/kibana/pull/198987","mergeCommit":{"message":"[One
Discover] Add app menu actions for Observability projects
(#198987)\n\n## 📓 Summary\r\n\r\nCloses #182230 \r\n\r\nThis work
introduces a new observability root profile and uses the
new\r\nextension point to register custom actions on the app
menu.\r\nThe registered actions and link will appear only with the new
project\r\nnavigation enabled on an Observability project:\r\n- A link
to the data sets quality page\r\n- On the alerts sub menu...\r\n-
replace the default search rule creation with the observability
custom\r\nthreshold rule\r\n - add an entry to directly create an SLO
for the current search\r\n\r\nTo access the SLO capabilities without
breaking the dependencies\r\nhierarchy of the new sustainable
architecture, the feature is registered\r\nby the common plugin
`discover-shared` in SLO and consumed then by\r\nDiscover using the IoC
principle.\r\n\r\n## 🖼️ Screenshots\r\n\r\n### Observability project
solution - show new menu\r\n\r\n<img width=\"3004\" alt=\"Screenshot
2024-11-06 at 12 37
02\"\r\nsrc=\"https://github.com/user-attachments/assets/d70b532d-1889-4d5b-b2ee-de2f048560f4\">\r\n\r\n###
Search project solution - hide new menu\r\n\r\n<img width=\"3006\"
alt=\"Screenshot 2024-11-06 at 12 36
19\"\r\nsrc=\"https://github.com/user-attachments/assets/660893c3-f6b5-4b06-b8de-50a61a6bdb98\">\r\n\r\n###
Default navigation mode - hide new menu\r\n\r\n<img width=\"3002\"
alt=\"Screenshot 2024-11-06 at 12 35
43\"\r\nsrc=\"https://github.com/user-attachments/assets/674c5a08-0084-40e5-ae34-a56c363cacce\">\r\n\r\n##
🎥
Demo\r\n\r\n\r\nhttps://github.com/user-attachments/assets/104e6074-0401-4fd2-a8e6-8b05f2c070d7\r\n\r\n---------\r\n\r\nCo-authored-by:
Marco Antonio Ghiani <[email protected]>\r\nCo-authored-by:
kibanamachine
<[email protected]>","sha":"9d38922401d0bbd0d95d750f68fec77ca22758fb"}},"sourceBranch":"main","suggestedTargetBranches":[],"targetPullRequestStates":[{"branch":"main","label":"v9.0.0","labelRegex":"^v9.0.0$","isSourceBranch":true,"state":"MERGED","url":"https://github.com/elastic/kibana/pull/198987","number":198987,"mergeCommit":{"message":"[One
Discover] Add app menu actions for Observability projects
(#198987)\n\n## 📓 Summary\r\n\r\nCloses #182230 \r\n\r\nThis work
introduces a new observability root profile and uses the
new\r\nextension point to register custom actions on the app
menu.\r\nThe registered actions and link will appear only with the new
project\r\nnavigation enabled on an Observability project:\r\n- A link
to the data sets quality page\r\n- On the alerts sub menu...\r\n-
replace the default search rule creation with the observability
custom\r\nthreshold rule\r\n - add an entry to directly create an SLO
for the current search\r\n\r\nTo access the SLO capabilities without
breaking the dependencies\r\nhierarchy of the new sustainable
architecture, the feature is registered\r\nby the common plugin
`discover-shared` in SLO and consumed then by\r\nDiscover using the IoC
principle.\r\n\r\n## 🖼️ Screenshots\r\n\r\n### Observability project
solution - show new menu\r\n\r\n<img width=\"3004\" alt=\"Screenshot
2024-11-06 at 12 37
02\"\r\nsrc=\"https://github.com/user-attachments/assets/d70b532d-1889-4d5b-b2ee-de2f048560f4\">\r\n\r\n###
Search project solution - hide new menu\r\n\r\n<img width=\"3006\"
alt=\"Screenshot 2024-11-06 at 12 36
19\"\r\nsrc=\"https://github.com/user-attachments/assets/660893c3-f6b5-4b06-b8de-50a61a6bdb98\">\r\n\r\n###
Default navigation mode - hide new menu\r\n\r\n<img width=\"3002\"
alt=\"Screenshot 2024-11-06 at 12 35
43\"\r\nsrc=\"https://github.com/user-attachments/assets/674c5a08-0084-40e5-ae34-a56c363cacce\">\r\n\r\n##
🎥
Demo\r\n\r\n\r\nhttps://github.com/user-attachments/assets/104e6074-0401-4fd2-a8e6-8b05f2c070d7\r\n\r\n---------\r\n\r\nCo-authored-by:
Marco Antonio Ghiani <[email protected]>\r\nCo-authored-by:
kibanamachine
<[email protected]>","sha":"9d38922401d0bbd0d95d750f68fec77ca22758fb"}}]}]
BACKPORT-->

---------

Co-authored-by: kibanamachine <[email protected]>
CAWilson94 pushed a commit to CAWilson94/kibana that referenced this issue Nov 18, 2024
…ic#198987)

## 📓 Summary

Closes elastic#182230 

This work introduces a new observability root profile and uses the new
extension point to register custom actions on the app menu.
The registered actions and link will appear only with the new project
navigation enabled on an Observability project:
- A link to the data sets quality page
- On the alerts sub menu...
- replace the default search rule creation with the observability custom
threshold rule
  - add an entry to directly create an SLO for the current search

To access the SLO capabilities without breaking the dependencies
hierarchy of the new sustainable architecture, the feature is registered
by the common plugin `discover-shared` in SLO and consumed then by
Discover using the IoC principle.

## 🖼️ Screenshots

### Observability project solution - show new menu

<img width="3004" alt="Screenshot 2024-11-06 at 12 37 02"
src="https://github.com/user-attachments/assets/d70b532d-1889-4d5b-b2ee-de2f048560f4">

### Search project solution - hide new menu

<img width="3006" alt="Screenshot 2024-11-06 at 12 36 19"
src="https://github.com/user-attachments/assets/660893c3-f6b5-4b06-b8de-50a61a6bdb98">

### Default navigation mode - hide new menu

<img width="3002" alt="Screenshot 2024-11-06 at 12 35 43"
src="https://github.com/user-attachments/assets/674c5a08-0084-40e5-ae34-a56c363cacce">

## 🎥  Demo


https://github.com/user-attachments/assets/104e6074-0401-4fd2-a8e6-8b05f2c070d7

---------

Co-authored-by: Marco Antonio Ghiani <[email protected]>
Co-authored-by: kibanamachine <[email protected]>
CAWilson94 pushed a commit to CAWilson94/kibana that referenced this issue Nov 18, 2024
…ic#198987)

## 📓 Summary

Closes elastic#182230 

This work introduces a new observability root profile and uses the new
extension point to register custom actions on the app menu.
The registered actions and link will appear only with the new project
navigation enabled on an Observability project:
- A link to the data sets quality page
- On the alerts sub menu...
- replace the default search rule creation with the observability custom
threshold rule
  - add an entry to directly create an SLO for the current search

To access the SLO capabilities without breaking the dependencies
hierarchy of the new sustainable architecture, the feature is registered
by the common plugin `discover-shared` in SLO and consumed then by
Discover using the IoC principle.

## 🖼️ Screenshots

### Observability project solution - show new menu

<img width="3004" alt="Screenshot 2024-11-06 at 12 37 02"
src="https://github.com/user-attachments/assets/d70b532d-1889-4d5b-b2ee-de2f048560f4">

### Search project solution - hide new menu

<img width="3006" alt="Screenshot 2024-11-06 at 12 36 19"
src="https://github.com/user-attachments/assets/660893c3-f6b5-4b06-b8de-50a61a6bdb98">

### Default navigation mode - hide new menu

<img width="3002" alt="Screenshot 2024-11-06 at 12 35 43"
src="https://github.com/user-attachments/assets/674c5a08-0084-40e5-ae34-a56c363cacce">

## 🎥  Demo


https://github.com/user-attachments/assets/104e6074-0401-4fd2-a8e6-8b05f2c070d7

---------

Co-authored-by: Marco Antonio Ghiani <[email protected]>
Co-authored-by: kibanamachine <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Project:OneDiscover Enrich Discover with contextual awareness Team:obs-ux-logs Observability Logs User Experience Team
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants