grafana / explore-logs

Repo for the Loki log exploration app
GNU Affero General Public License v3.0
310 stars 14 forks source link

Logs panel: Share link to log line #772

Closed gtk-grafana closed 4 weeks ago

gtk-grafana commented 2 months ago

Allow users to share links to a specific log line within the logs panel.

zizzpudding commented 2 months ago

My concern about adding a button to the breadcrumb is that it might not be as discoverable as a button in the app. I like adding a toggle split button in the app (perhaps to the right of the Go to Explore) button.

Users can click on the share to copy the long link to the clipboard and click on the drop down menu to select a short link instead.

Do you think we should default to short link? or long link?

zizzpudding commented 2 months ago

Going by what has been done in the past. it looks like the short link is the default. There are also 4 different flavors of sharing the link. Shortened with a date/time filter Shortened without a date/time filter Long with a date/time filter Long without a date/time filter

I assume we want to default with the date/time filter as part of the URL. Especially if our main use case is sharing a log line(s) that was found. (not recreating the query for a different time frame).

Here's a quick screenshot of adding the button to the content rather than adding to the breadcrumb.

Image

gtk-grafana commented 2 months ago

I don't think we want users to copy a link without a time range, and I don't understand why we would provide a way to copy the long URL, it's already there in the browser if folks don't want a short url for some reason