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 OCP Engine with filter for OLS tarballx #197

Merged
merged 1 commit into from
Apr 19, 2024

Conversation

epapbak
Copy link
Collaborator

@epapbak epapbak commented Apr 17, 2024

Description

  • Add OCPEngine , which is basically the ICM engine with a filter for when openshift_lightspeed.json file is found in ht tarball's root directory.
  • Add corresponding unit tests
  • Add ols label value in StatsWatcher, so that metrics are updated with the ols archive type when possible

Cons of this approach: Our OCP engine used to use be the ICM engine, used directly. We now lose the updates made there if the process method is ever updated. But this is supposed to be temporary, so let's not delve on that.

Fixes CCXDEV-12725 partially (config update needed in ccx-data-pipeline)

Type of change

  • New feature (non-breaking change which adds functionality)

Testing steps

Updated UTs

Checklist

  • pre-commit run -a passes
  • updated documentation wherever necessary
  • added or modified tests if necessary
  • updated schemas and validators in insights-data-schemas in case of input/output change

@epapbak epapbak force-pushed the CCXDEV-12725 branch 2 times, most recently from a323788 to 3031c75 Compare April 17, 2024 13:02
@codecov-commenter
Copy link

codecov-commenter commented Apr 17, 2024

Codecov Report

Attention: Patch coverage is 89.74359% with 4 lines in your changes are missing coverage. Please review.

Project coverage is 85.00%. Comparing base (01d71d5) to head (82d3a4a).

Files Patch % Lines
ccx_messaging/watchers/stats_watcher.py 25.00% 3 Missing ⚠️
ccx_messaging/engines/ocp_engine.py 97.14% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #197      +/-   ##
==========================================
+ Coverage   84.69%   85.00%   +0.31%     
==========================================
  Files          33       34       +1     
  Lines        1078     1114      +36     
==========================================
+ Hits          913      947      +34     
- Misses        165      167       +2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@epapbak epapbak force-pushed the CCXDEV-12725 branch 2 times, most recently from 18bab9e to 082594a Compare April 17, 2024 13:07
@epapbak epapbak marked this pull request as ready for review April 17, 2024 13:23
@joselsegura
Copy link
Collaborator

The OLS team announced today that they will be starting to send their archives with a different User-Agent.

If it is possible, probably we can filter them out because the service header, so please wait until tomorrow before merging and using this engine.

@epapbak
Copy link
Collaborator Author

epapbak commented Apr 17, 2024

The OLS team announced today that they will be starting to send their archives with a different User-Agent.

If it is possible, probably we can filter them out because the service header, so please wait until tomorrow before merging and using this engine.

I'm not 100% sure tomorrow they'll have a different service header that we will be able to use, but it makes sense to wait and see indeed.

@epapbak epapbak changed the title Add OCP Engine with filter for OLS tarballs Draft: Add OCP Engine with filter for OLS tarballx Apr 17, 2024
@epapbak epapbak changed the title Draft: Add OCP Engine with filter for OLS tarballx Add OCP Engine with filter for OLS tarballx Apr 17, 2024
@epapbak epapbak marked this pull request as draft April 17, 2024 14:41
@epapbak epapbak marked this pull request as ready for review April 18, 2024 14:39
@epapbak epapbak merged commit e07fc58 into RedHatInsights:main Apr 19, 2024
8 checks passed
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.

5 participants