-
Notifications
You must be signed in to change notification settings - Fork 301
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
add managed environment POC #3021
base: master
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #3021 +/- ##
===========================================
+ Coverage 51.35% 75.76% +24.41%
===========================================
Files 204 202 -2
Lines 21446 21331 -115
Branches 2729 2740 +11
===========================================
+ Hits 11014 16162 +5148
+ Misses 9834 4362 -5472
- Partials 598 807 +209 ☔ View full report in Codecov by Sentry. |
Code Review Agent Run #763fc1Actionable Suggestions - 0Review Details
|
Changelist by BitoThis pull request implements the following key changes.
|
Code Review Agent Run #089365Actionable Suggestions - 0Review Details
|
Why are the changes needed?
Task environments can quickly become unwieldy for large, complex codebases. There are well over a dozen commonly used configurations, from
container_image
tosecret_requests
that will be similar among many tasks, albeit arbitrarily different for some edge cases.It is challenging to manage such environment configurations that contain a large number of such configurations while still being able to uniquely override the configurations for individual tasks, and extend a set of configurations to define entirely new environments.
This PR accomplishes both of these critical features in an intuitive manner.
What changes were proposed in this pull request?
These PR contributes a
Environment
class. AnEnvironment
contains a dictionary of configurations. These configurations are applied toflytekit.task
at registration time.However, the configurations of an
Environment
may be defined during the creation of theEnvironment
, or during the creation of the task to be authored with an `Environment.As a non-limiting example:
Additionally, one may create deep copies of an
Environment
This allows for an organization to modularly define reusable environments once for an entire project, or, perhaps even define reusable environments for the entire organization.
How was this patch tested?
Tests to be added. I have personally been using this pattern for the last year with Flyte, and with KFP for over three years.
Check all the applicable boxes
Summary by Bito
Introduction of a new Environment class in Flytekit for managing task configurations, providing modular and reusable functionality. The system enables creating, extending, and updating environment configurations with inheritance capabilities. This implementation focuses on improving configuration management flexibility and maintainability through a structured approach, allowing for complex configuration management through a reusable framework.Unit tests added: True
Estimated effort to review (1-5, lower is better): 1