-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Introduce configuration version 2 (#208)
### What This PR adds a new version (`"2"`) of the deployment configuration data format. This version of the configuration is capable of expressing array types in collections and arguments. Since this is the first time a new version is introduced there are a lot of changes the only purpose of which is to distinguish between versions. Only the infrastructure-related shell of the connector is aware of different versions of deployment configurations existing. The core of the connector only works with a single internal version. This PR is also the one to introduce tests of array types. In hindsight this ought to have been possible in the previous PR that introduced the internal types and transformations (#191). Note that there is not yet any automated way to upgrade a configuration to a newer version, but this will be introduced shortly. This PR also adds a changelog entry. ### How The file `version2.rs` is a duplicate of `version1.rs`, which has been adapted to use the new data types (incidentally these are just the ones of the internal model). `configuration.sql` now exists as `version1.sql` and `version2.sql` respectively, since these have different capabilities. This is because `version2.sql` introduces the ability to introspect array types. `configuration.rs` now exposes `RawConfiguration` and `Configuration` types which are enums of all the supported versions (currently 1 and "2"). One big wart on the implementation is that serde and schemars are unable to derive trait implementations for these types correctly, since they only support strings as enum tags, and we used a number literal for version 1. Once we drop support of version 1 completely we can remove the manually implemented instances. The various `Connector` trait implementations now explicitly work on the internal representation of a configuration, `RuntimeConfiguration`. --------- Co-authored-by: Daniel Harvey <[email protected]>
- Loading branch information
1 parent
a04bb82
commit 734b0ee
Showing
78 changed files
with
26,017 additions
and
655 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.