[low-code cdk] decouple parsing the yaml manifest from the declarative source implementation #19095
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What
The current way that
YamlDeclarativeSource
is structured and implemented couples parsing and resolving a YAML file and the implementation to run connector commands likeread
,spec
, andcheck
.YAML parsing can really just function as a subclass of the underlying declarative implementation made up of the
ConnectorDefinition
manifest file. And this will allow us to start using theManifestDeclarativeSource
from the connector builder UI.How
This is mostly moving the implementation to a new superclass that
YamlDeclarativeSource
will then inherit from. AndYamlDeclarativeSource
only needs to override the constructor to parse a YAML file and the remaining flow should be the same. The PR also looks large, but I reorganized the tests so a bulk of our testing and edge cases is against the already parsed manifest and only behavior relevant to yaml parsing is in the existing tests.Recommended reading order
manifest_declarative_source.py
yaml_declarative_source.py
test_manifest_declarative_source.py
test_yaml_declarative_source.py