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

Update jobs_current_version_uuid_index and jobs_symlink_target_uuid_index to ignore NULL values #2186

Merged
merged 1 commit into from
Oct 13, 2022

Conversation

collado-mike
Copy link
Collaborator

Problem

Most jobs don't have a symlink target and jobs don't have a current version until they've had at least one successful run. The indices recently added will always write to the index, even when the indexed values are null.

Solution

Avoid writing to the indices when indexed values are null

Checklist

  • You've signed-off your work
  • Your changes are accompanied by tests (if relevant)
  • Your change contains a small diff and is self-contained
  • You've updated any relevant documentation (if relevant)
  • You've updated the CHANGELOG.md with details about your change under the "Unreleased" section (if relevant, depending on the change, this may not be necessary)
  • You've versioned your .sql database schema migration according to Flyway's naming convention (if relevant)
  • You've included a header in any source code files (if relevant)

@collado-mike collado-mike requested a review from phixMe October 13, 2022 18:17
@boring-cyborg boring-cyborg bot added the api API layer changes label Oct 13, 2022
…ndex to ignore NULL values

Signed-off-by: Michael Collado <collado.mike@gmail.com>
@collado-mike collado-mike force-pushed the fix/update_indices_for_nulls branch from ad1fafd to c581ebc Compare October 13, 2022 18:18
Copy link
Member

@phixMe phixMe left a comment

Choose a reason for hiding this comment

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

Thanks

@codecov
Copy link

codecov bot commented Oct 13, 2022

Codecov Report

Merging #2186 (c581ebc) into main (a458374) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##               main    #2186   +/-   ##
=========================================
  Coverage     76.60%   76.60%           
  Complexity     1136     1136           
=========================================
  Files           219      219           
  Lines          5287     5287           
  Branches        420      420           
=========================================
  Hits           4050     4050           
  Misses          765      765           
  Partials        472      472           

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@collado-mike collado-mike merged commit cf48c5d into main Oct 13, 2022
@collado-mike collado-mike deleted the fix/update_indices_for_nulls branch October 13, 2022 18:37
jonathanpmoraes pushed a commit to nubank/NuMarquez that referenced this pull request Feb 6, 2025
…ndex to ignore NULL values (MarquezProject#2186)

Signed-off-by: Michael Collado <collado.mike@gmail.com>

Signed-off-by: Michael Collado <collado.mike@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api API layer changes
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants