You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
### 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]>
0 commit comments