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

[Greedy LAD] Add new functionality for Latest Available Data views #6432

Merged
merged 23 commits into from
Mar 17, 2023

Conversation

jvigliotta
Copy link
Contributor

@jvigliotta jvigliotta commented Mar 15, 2023

Closes #6449

Describe your changes:

Have added a method to the Telemetry API that will allow you to turn off "Greedy LAD". Greedy LAD functionality has been enabled by default in the Telemetry API. When a Telemetry Collection is used with a strategy of 'latest', if Greedy LAD is active (which it is by default), then the Telemetry Collection will no longer drop data that falls before the start bound if no new data has come in to replace existing data. It will continue to hold onto the data until new data comes in.

All Submissions:

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same update/change?
  • Is this change backwards compatible? For example, developers won't need to change how they are calling the API or how they've extended core plugins such as Tables or Plots.
    It's backwards compatible, but it does change some default functionality to add more visibility to data, but it is able to be turned off.

Author Checklist

  • Changes address original issue?
  • Tests included and/or updated with changes?
  • Command line build passes?
  • Has this been smoke tested?
  • Testing instructions included in associated issue OR is this a dependency/testcase change?

Reviewer Checklist

  • Changes appear to address issue?
  • Reviewer has tested changes by following the provided instructions?
  • Changes appear not to be breaking changes?
  • Appropriate automated tests included?
  • Code style and in-line documentation are appropriate?
  • Has associated issue been labelled unverified? (only applicable if this PR closes the issue)
  • Has associated issue been labelled bug? (only applicable if this PR is for a bug fix)

@jvigliotta jvigliotta requested a review from akhenry March 15, 2023 05:15
@codecov
Copy link

codecov bot commented Mar 15, 2023

Codecov Report

Merging #6432 (59764e7) into master (25c0dab) will decrease coverage by 0.04%.
The diff coverage is 57.57%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #6432      +/-   ##
==========================================
- Coverage   54.83%   54.79%   -0.04%     
==========================================
  Files         626      626              
  Lines       26591    26616      +25     
  Branches     2403     2403              
==========================================
+ Hits        14580    14585       +5     
- Misses      11348    11368      +20     
  Partials      663      663              
Flag Coverage Δ *Carryforward flag
e2e-ci 39.35% <ø> (+0.02%) ⬆️ Carriedforward from 25c0dab
e2e-full 51.08% <ø> (-0.01%) ⬇️ Carriedforward from 25c0dab
e2e-stable 54.79% <57.57%> (-0.07%) ⬇️
unit 49.19% <36.36%> (-0.06%) ⬇️

*This pull request uses carry forward flags. Click here to find out more.

Impacted Files Coverage Δ
src/api/telemetry/TelemetryAPI.js 85.82% <50.00%> (-0.83%) ⬇️
src/api/telemetry/TelemetryCollection.js 86.03% <59.25%> (-3.35%) ⬇️

... and 6 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 25c0dab...59764e7. Read the comment docs.

@unlikelyzero
Copy link
Collaborator

@jvigliotta do you have an issue for this bad boy?

Copy link
Contributor

@akhenry akhenry left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks really good, thank you.

I don't think the notifications are scalable. We have displays with like 50 LAD views in them, so I think we need to ship this initially with no notifications until we come up with a better UI solution to this.

I suspect that we can simplify things by creating a separate class for handling LAD telemetry, like a LADTelemetryHandler or something, but that's a problem for another time.

src/api/telemetry/TelemetryCollection.js Outdated Show resolved Hide resolved
@jvigliotta
Copy link
Contributor Author

@jvigliotta do you have an issue for this bad boy?

I do not! I'll work with @akhenry to get one, I don't have access to the original

@jvigliotta jvigliotta requested a review from akhenry March 16, 2023 17:40
this.emit('dataInsideTimeBounds');
this.openmct.notifications.info(`Latest available data for "${this.domainObject.name}" is no longer outside of current time bounds`);
if (this.dataOutsideTimeBounds) {
this.dataOutsideTimeBounds = false;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this flag actually used for anything any more?

@jvigliotta jvigliotta requested a review from akhenry March 16, 2023 18:30
@jvigliotta
Copy link
Contributor Author

jvigliotta commented Mar 16, 2023

follow up for tests: #6451

@akhenry akhenry merged commit 39463c5 into master Mar 17, 2023
@akhenry akhenry deleted the lad-strategy-latest branch March 17, 2023 02:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Greedy LAD] Have the ability to have data before the start bound IF it's a strategy 'latest' request
3 participants