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

Add More Customization to Relative Date Format #25815

Closed
Tracked by #179200 ...
pickypg opened this issue Nov 16, 2018 · 5 comments
Closed
Tracked by #179200 ...

Add More Customization to Relative Date Format #25815

pickypg opened this issue Nov 16, 2018 · 5 comments
Labels
Feature:FieldFormatters Feature:Lens Feature:Visualizations Generic visualization features (in case no more specific feature label is available) release_note:enhancement Team:Visualizations Visualization editors, elastic-charts and infrastructure

Comments

@pickypg
Copy link
Member

pickypg commented Nov 16, 2018

Relates to #13784, but this is a specific example.

Describe the feature:

A field formatter that took the difference from a date field versus now where now is shared (aka the Date Formatter's Relative Date formatter). As a step further though, we should be able to control how fine grained the display is. For example, it currently jumps from "a few seconds ago" to "a minute ago" then minute increments until the hour mark (et cetera). It might be nice to see "15 seconds ago" or even "1 m 15 s ago".

Describe a specific use case for the feature:

When showing log events, it would be nice to see how long ago a certain event occurred and as time passes into hours, it would be nice to get a more exact timeframe.

Elasticsearch does not support this through script fields using Kibana because Elasticsearch intentionally makes it very hard to get ahold of now dynamically (because each shard / field would see a different now, which would be wrong).

We could solve this differently by supporting script params within Kibana (#19716) and providing the ability to tell ES what "now" is at search time, which would allow the script field to do all of this, but that would be a nice to have versus direct UI support.

@pickypg pickypg added release_note:enhancement Feature:Visualizations Generic visualization features (in case no more specific feature label is available) Team:Visualizations Visualization editors, elastic-charts and infrastructure labels Nov 16, 2018
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-app

@ghudgins
Copy link
Contributor

ghudgins commented Jul 5, 2022

There are interesting workaround ideas using a runtime field to compute this duration...for example this gives you "now" in milliseconds double now = System.currentTimeMillis();

@pickypg
Copy link
Member Author

pickypg commented Jul 5, 2022

I would suggest that Kibana provide now as a script parameter rather than try to determine it at runtime from Elasticsearch itself. That provides the most consistent experience and it's much more performant as well.

@ghudgins
Copy link
Contributor

ghudgins commented Aug 2, 2022

Related issue that should help in visualizations - #112851

@timductive
Copy link
Member

Closing this because it's not planned to be resolved in the foreseeable future. It will be tracked in our Icebox and will be re-opened if our priorities change. Feel free to re-open if you think it should be melted sooner.

@timductive timductive closed this as not planned Won't fix, can't repro, duplicate, stale Mar 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:FieldFormatters Feature:Lens Feature:Visualizations Generic visualization features (in case no more specific feature label is available) release_note:enhancement Team:Visualizations Visualization editors, elastic-charts and infrastructure
Projects
None yet
Development

No branches or pull requests

5 participants