-
Notifications
You must be signed in to change notification settings - Fork 4
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
[WOR-850] Delete billing profile during billing project deletion (GCP) #2715
Conversation
Future.successful() | ||
case (None, false) => | ||
logger.info( | ||
s"Deleting billing project $projectName, but no associated billing profile record to delete (could be a legacy project)" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Once we have backfilled billing profiles for existing GCP billing projects, we can get rid of this case.
@@ -184,10 +184,10 @@ class BillingProjectOrchestrator(ctx: RawlsRequestContext, | |||
) | |||
) | |||
} | |||
billingProfileId <- billingRepository.getBillingProfileId(projectName) | |||
projectLifecycle = billingProfileId match { | |||
azureManagedAppCoordinates <- billingRepository.getAzureManagedAppCoordinates(projectName) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Needed to change how we decide if the billing project is an Azure one. Note that we don't store a cloudPlatform.
…g projects. (#2698) * Create profile model for GCP projects. * rename * Refactoring * Try removing the prefix * Test removal of prefix. * Store the billing profile ID in the billing project. * Split tests, mock repo. * Code review feedback. * [WOR-850] Delete billing profile during billing project deletion (GCP) (#2715) * [WOR-852] Update billing profile when updating billing account (#2736) * add missing implicits to pact tests * add null values to expected createProfile request * specify GCP as billing project's cloud platform after updating billing account --------- Co-authored-by: Marcus Talbott <[email protected]>
Ticket: https://broadworkbench.atlassian.net/browse/WOR-850
This PR adds the code for GCP billing project deletion to also delete the associated billing profile, if it exists. Note that this is against a feature branch (which creates the billing profile during GCP billing project creation).
Tested running Rawls locally to create and delete GCP billing projects.