-
Notifications
You must be signed in to change notification settings - Fork 99
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
fix bug by keeping track of interval within the explorer #1266
fix bug by keeping track of interval within the explorer #1266
Conversation
Signed-off-by: Derek Ho <dxho@amazon.com>
Signed-off-by: Derek Ho <dxho@amazon.com>
Signed-off-by: Derek Ho <dxho@amazon.com>
@@ -389,13 +393,15 @@ export const Explorer = ({ | |||
getVisualizations(); | |||
getAvailableFields(`search source=${curIndex}`); | |||
} else { | |||
findAutoInterval(startTime, endTime); | |||
if (!selectedIntervalRef.current || selectedIntervalRef.current.text === 'Auto') { | |||
findAutoInterval(startingTime, endingTime); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what's the difference between startingTime and startTime?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I may need someone more familiar with this component/code (@mengweieric ?) - but from what I can tell this explorer is rendered by both Application analytics and event analytics - for event analytics startTime is undefined, resulting in auto interval not getting picked up. In either case startingTime should be already set above based on the query so I think(?) this is a more general implementation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes confirmed. Event analytics previously does not use any passed in start/starting time, I think later there's live tail introduced with starting/ending time for differentiating existing start/end time just for reusing the exiting data fetching
dashboards-observability/public/components/event_analytics/explorer/explorer.tsx
Outdated
Show resolved
Hide resolved
dashboards-observability/public/components/event_analytics/explorer/explorer.tsx
Outdated
Show resolved
Hide resolved
dashboards-observability/public/components/event_analytics/explorer/explorer.tsx
Outdated
Show resolved
Hide resolved
dashboards-observability/public/components/event_analytics/explorer/explorer.tsx
Outdated
Show resolved
Hide resolved
Signed-off-by: Derek Ho <dxho@amazon.com>
Codecov Report
@@ Coverage Diff @@
## 2.4 #1266 +/- ##
=========================================
Coverage 70.27% 70.27%
Complexity 292 292
=========================================
Files 42 42
Lines 2395 2395
Branches 248 248
=========================================
Hits 1683 1683
Misses 571 571
Partials 141 141
Flags with carried forward coverage won't be shown. Click here to find out more. Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
Signed-off-by: Derek Ho <dxho@amazon.com>
Signed-off-by: Derek Ho <dxho@amazon.com>
The base branch was changed.
Signed-off-by: Derek Ho <dxho@amazon.com>
CI failed, retrying. not sure why recently bootstrap often fails |
Signed-off-by: Derek Ho dxho@amazon.com
Description
Keeps track of interval selected in the explorer and timechart header so that the interval is not reset whenever the query changes
Issues Resolved
#1249
Check List
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.