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

Fix/5246-change-log-level-for-business-logs #6067

Merged
merged 9 commits into from
May 22, 2023

Conversation

EugeneTseitlin
Copy link
Contributor

@EugeneTseitlin EugeneTseitlin commented May 20, 2023

Close: #5246

PR Details

🤖 Generated by Copilot at 8f4e49f

Summary

🧪📝🚧

Improved the billing service to handle subscription plan limitations more gracefully. Added a test case and logging for the validation of plan features. Removed validation errors that could block the code generation process in billing.service.ts.

Sing, O Muse, of the skillful coder who devised
A test case for the billing service, types imported,
To check the plan limitations for the workspaces wide,
And with a logger, errors and warnings reported.

Walkthrough

  • Import BillingFeature enum and entitlement types from @stigg/node-server-sdk to use in test case and service methods (link)
  • Declare and initialize logger variable to hold an instance of AmplicationLogger for logging purposes (link, link)
  • Add test case to check validateSubscriptionPlanLimitationsForWorkspace method when workspace has no entitlement to bypass code generation limitation (link)
  • Remove ValidationError import from billing.service.ts as it is no longer used to throw errors (link)
  • Replace throw new ValidationError statements with logger.info calls in validateSubscriptionPlanLimitationsForWorkspace method to log limitation errors instead of stopping code generation process (link, link, link, link)

PR Checklist

  • Tests for the changes have been added
  • npm test doesn't throw any error

IMPORTANT: Please review the CONTRIBUTING.md file for detailed contributing guidelines.

@EugeneTseitlin EugeneTseitlin changed the base branch from master to next May 20, 2023 17:41
@nx-cloud
Copy link

nx-cloud bot commented May 20, 2023

☁️ Nx Cloud Report

CI is running/has finished running commands for commit 3f7ee83. As they complete they will appear below. Click to see the status, the terminal output, and the build insights.

📂 See all runs for this branch


✅ Successfully ran 1 target

Sent with 💌 from NxCloud.

@EugeneTseitlin EugeneTseitlin self-assigned this May 20, 2023
@mulygottlieb mulygottlieb merged commit 3e8e269 into next May 22, 2023
8 checks passed
@mulygottlieb mulygottlieb deleted the fix/5246-change-log-level-for-business-logs branch May 22, 2023 06:56
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.

🐛 Bug Report: Wrong application log level is used for business logs
5 participants