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

CMR-10287: Create feature toggle for cmr-validate-keyword default behavior change #2202

Merged
merged 4 commits into from
Dec 30, 2024

Conversation

jmaeng72
Copy link
Contributor

@jmaeng72 jmaeng72 commented Dec 20, 2024

Overview

What is the feature/fix?

CMR-10182 changed api behavior for ingesting collections by making cmr-validate-keywords default to true instead of its previous default behavior of false.

What is the Solution?

A feature toggle on top of this behavior change so we can control when this feature become public or not in all envs

What areas of the application does this impact?

Ingest

Checklist

  • I have updated/added unit and int tests that prove my fix is effective or that my feature works
  • New and existing unit and int tests pass locally and remotely
  • clj-kondo has been run locally and all errors corrected
  • I have removed unnecessary/dead code and imports in files I have changed
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have cleaned up integration tests by doing one or more of the following:
    • migrated any are2 tests to are3 in files I have changed
    • de-duped, consolidated, removed dead int tests
    • transformed applicable int tests into unit tests
    • refactored to reduce number of system state resets by updating fixtures (use-fixtures :each (ingest/reset-fixture {})) to be :once instead of :each

@jmaeng72 jmaeng72 self-assigned this Dec 20, 2024
@codecov-commenter
Copy link

codecov-commenter commented Dec 20, 2024

Codecov Report

Attention: Patch coverage is 30.00000% with 7 lines in your changes missing coverage. Please review.

Project coverage is 29.35%. Comparing base (fe3fde2) to head (1e73262).

Files with missing lines Patch % Lines
ingest-app/src/cmr/ingest/api/collections.clj 25.00% 6 Missing ⚠️
ingest-app/src/cmr/ingest/config.clj 50.00% 0 Missing and 1 partial ⚠️

❗ There is a different number of reports uploaded between BASE (fe3fde2) and HEAD (1e73262). Click for more details.

HEAD has 9 uploads less than BASE
Flag BASE (fe3fde2) HEAD (1e73262)
12 3
Additional details and impacted files
@@             Coverage Diff             @@
##           master    #2202       +/-   ##
===========================================
- Coverage   58.23%   29.35%   -28.88%     
===========================================
  Files        1056      996       -60     
  Lines       71012    67665     -3347     
  Branches     2023     1157      -866     
===========================================
- Hits        41351    19865    -21486     
- Misses      27772    46694    +18922     
+ Partials     1889     1106      -783     

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

@@ -159,8 +159,10 @@ The following fields are validated:
* [Data Format](https://gcmd.earthdata.nasa.gov/kms/concepts/concept_scheme/dataformat?format=csv) - Archival and Distribution File Format, and GetData Format
* [ProcessingLevel] (https://gcmd.earthdata.nasa.gov/kms/concepts/concept_scheme/productlevelid?format=csv) - productlevelid

**Note**: cmr-validate-keywords is set to TRUE by default
**Note**: if cmr-validate-keywords header is not set explicitly, it will behave as if it was set to FALSE by default behind the scenes
Copy link
Contributor

Choose a reason for hiding this comment

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

Since this line probably won't be updated again until the feature toggle is removed, I'm wondering if we need to communicate here that work is being done to change it to default true in the various environments. Perhaps a note in parens?
Though I'm not sure how important that is or how quick we'll be getting that work done

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think we can leave it and I will make an update to this doc as soon as we toggle this feature on in PROD

@jmaeng72 jmaeng72 merged commit d59a69e into master Dec 30, 2024
6 checks passed
isja17 pushed a commit that referenced this pull request Dec 31, 2024
…avior change (#2202)

* add feature toggle
* update documentation to say default is false
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.

4 participants