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

Ability to disable billing for selected services #136

Merged
merged 3 commits into from
Mar 6, 2024

Conversation

Kidswiss
Copy link
Contributor

@Kidswiss Kidswiss commented Mar 5, 2024

Summary

With this commit it's possible to disable the billing for selected services.

It works by deploying a separate config map containing this information in the appcat-control namespace. This config map is then read by the service composition function and removes the billing accordingly.

For more detailed information please have a look at the docs in the commit.

Checklist

  • Categorize the PR by setting a good title and adding one of the labels:
    bug, enhancement, documentation, change, breaking, dependency
    as they show up in the changelog
  • Update tests.
  • Link this PR to related issues.

Kidswiss added 2 commits March 5, 2024 16:12
By default mergo doesn't allow merging a non empty value with an
empty value. For example if a field is a string "hello" it would not
override it, if the to be merged object contains the same field with "".

This works well until someone wants to override a true boolean with a
false boolean, in which case the merge doesn't happen.

By setting `mergo.WithOverwriteWithEmptyValue`, we can force mergo to
merge empty values into noni empty values.

darccio/mergo#249
With this commit it's possible to disable the billing for selected
services.

It works by deploying a separate config map containing this information
in the `appcat-control` namespace. This config map is then read by the
service composition function and removes the billing accordingly.

For more detailed information please have a look at the docs in the
commit.
@Kidswiss Kidswiss added the enhancement New feature or request label Mar 5, 2024
@Kidswiss Kidswiss requested review from a team, TheBigLee, wejdross and zugao and removed request for a team March 5, 2024 15:19
Copy link
Collaborator

@zugao zugao left a comment

Choose a reason for hiding this comment

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

There are a couple of things to check

Copy link
Collaborator

@zugao zugao left a comment

Choose a reason for hiding this comment

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

LGTM

@Kidswiss Kidswiss merged commit 2360074 into master Mar 6, 2024
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants