-
Notifications
You must be signed in to change notification settings - Fork 13
feat: blue green deployment update #368
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
feat: blue green deployment update #368
Conversation
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.
Pull request overview
This PR integrates blue-green deployment enhancements from the cf go-client library, adding configurable monitoring for newly deployed applications. The deployment is considered successful when the new application version reaches a running state within specified timeout and check interval parameters.
- Adds
app_deployed_running_timeoutandapp_deployed_running_check_intervalattributes to configure deployment monitoring - Updates go-cfclient/v3 dependency to a pre-release version with extended blue-green deployment support
- Refactors strategy handling to use dedicated methods for blue-green vs. other strategies
Reviewed changes
Copilot reviewed 5 out of 6 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| go.mod | Adds temporary replace directive for unreleased go-cfclient/v3 version with blue-green deployment enhancements |
| go.sum | Updates checksums for the new go-cfclient/v3 pseudo-version |
| cloudfoundry/provider/types_app.go | Adds AppDeployedRunningTimeout and AppDeployedRunningCheckInterval fields to AppType struct and includes them in CopyConfigAttributes |
| cloudfoundry/provider/resource_app.go | Adds schema definitions, validators, and implementation logic for the new blue-green deployment configuration attributes |
| examples/resources/cloudfoundry_app/resource.tf | Updates example to demonstrate usage of new blue-green deployment timeout and check interval attributes |
| docs/resources/app.md | Documents the new optional attributes with their valid ranges and usage context |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
|
This pull request is stale because it has been open 15 days with no activity. Remove stale label or comment or this will be closed in 5 days. |
| }, | ||
| }, | ||
| "app_deployed_running_timeout": schema.Int64Attribute{ | ||
| MarkdownDescription: "Timeout in minutes to wait for app to be running after updating deployment with 'blue-green' strategy. The default is 5 minutes. Min value is 1 minute. Used only when strategy is set to 'blue-green'.", |
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.
@SylwekLewan-dev The default value of 5 minutes?
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.
The default values are already defined in client: https://github.com/cloudfoundry/go-cfclient/pull/496/files
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.
Added explicit constants in provider as well
|
@SylwekLewan-dev your contribution to the goclient is part of the official release. Can you switch from the commit to the latest release in your PR? |
|
Removed replace section from go.mod and synced to new go-cfclient |
Purpose
Does this introduce a breaking change?
Pull Request Type
What kind of change does this Pull Request introduce?
How to Test
go test ./...What to Check
Verify that the following are valid:
Other Information
Checklist for reviewer
The following organizational tasks must be completed before merging this PR: