-
Notifications
You must be signed in to change notification settings - Fork 198
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
Crossplane Support #6268
Comments
@Cliftonz I ❤️ this idea! It came up a few times in the past and we really appreciate the write up! Curious if this is something you'd be interested to help out with? We don't have much experience with Crossplane and we would love to help out get this off the ground, especially if there's a concrete use case in mind. Technically, I think this won't be too difficult to support and might not require as much heavy lifting as you might think. I think Wing can simply synthesize K8S YAML that includes Crossplane resources, and we should be able to reuse the logic we have in our cloud library to produce AWS/GCP/Azure resources for the cloud APIs. So basically adding a new platform for |
I can help with getting you guys getting off of the ground and giving advise but I do not have the space to actually implement anything. I would recommend reaching out to upbound.io they should be able to help and may be willing to help further and provide better resources. |
Hi, This issue hasn't seen activity in 90 days. Therefore, we are marking this issue as stale for now. It will be closed after 7 days. |
Keep open |
Use Case
As infrastructure as code (IaC) continues to transform how organizations deploy and manage their infrastructure, there is a significant push towards more integrated and developer-friendly environments. Currently, developers managing Kubernetes infrastructure, especially those constructing entire control planes with Crossplane, must often work with multiple tools and languages, including YAML, Go, JSON, Helm, ytt, kustomize, thema, and cuelang. This can be cumbersome and detracts from the development experience, particularly for those who are not familiar with these formats or who prefer more concise and expressive programming languages.
By enabling Winglang to compile directly to Crossplane-compatible code, developers can leverage a single, more comfortable language to define entire control planes on Kubernetes. This capability dramatically simplifies the management of complex cloud resources and multi-cloud environments by abstracting the underlying implementation details and allowing developers to focus more on the business logic and less on the intricacies of Kubernetes resource definitions.
Winglang's expressive syntax and type-safe characteristics make it an ideal candidate for this role. It enables developers to:
This enhancement not only makes Winglang a more versatile tool within the Kubernetes ecosystem but also promotes its adoption among developers who prefer its user-friendly syntax and robust features. The ability to define full control planes without leaving a comfortable and familiar programming environment is a powerful incentive for adopting Winglang in cloud-native development projects.
Proposed Solution
The proposed solution involves the following key steps:
Type Conversion:
Compiler Extension:
Integration Testing:
Documentation and Examples:
Implementation Notes
Implementation Notes:
Dependency Management: Careful management of dependencies will be crucial, especially concerning the specific versions of Kubernetes and Crossplane APIs that are supported. This will require analyzing providers on the upbound marketplace.
Handling Eventual Consistency: Crossplane operates on an eventual consistency model, where the state of the system is not immediately reflected after a command is issued. This requires careful handling in Winglang's compilation strategy. The compiler must be designed to effectively manage and track the state changes that occur over time within the Kubernetes environment. Implementing logic in Winglang to poll and verify the status of resources after they are deployed will be critical to ensure that the desired state is achieved and maintained.
State Interpretation and Feedback: Since Crossplane does not provide execution plans like some other infrastructure as code tools, Winglang will need to incorporate its own mechanisms to predict and interpret the outcomes of deployments on Kubernetes clusters. This might involve generating logs or other outputs that provide users with detailed feedback on the deployment process, potential discrepancies, and how they are resolved over time.
Resource Status Tracking: Enhancing Winglang to include features that can interpret and manage the lifecycle of Kubernetes and Crossplane resources will be essential. This could involve integrating with Kubernetes APIs to fetch resource statuses or subscribing to event streams that notify the system of changes in resource states. Winglang could then provide users with real-time feedback on the status of their deployments, helping them manage their infrastructure more effectively.
Error Handling and Rollbacks: Given the asynchronous nature of resource management in Kubernetes and Crossplane, robust error handling mechanisms will need to be implemented. This includes providing strategies for rollback or remediation when deployments do not proceed as expected. Winglang could offer built-in support for rollback strategies that automatically revert changes in the event of failures, based on predefined policies or user input.
Continuous Monitoring and Adjustment: Winglang should include capabilities for continuous monitoring of resource states to ensure that the infrastructure remains in the desired state over time. This includes detecting drift from the desired state and automatically applying necessary adjustments. Implementing these features will help ensure that the infrastructure managed by Winglang remains robust and stable even as underlying conditions change.
Component
Compiler
Community Notes
The text was updated successfully, but these errors were encountered: