Skip to content

Update pipelines to support -rc for dab versions#1558

Merged
abhishekkumams merged 61 commits intomainfrom
dev/abhishekkuma/update_pipelines_to_support_rc
Jul 4, 2023
Merged

Update pipelines to support -rc for dab versions#1558
abhishekkumams merged 61 commits intomainfrom
dev/abhishekkuma/update_pipelines_to_support_rc

Conversation

@abhishekkumams
Copy link
Copy Markdown
Contributor

Why make this change?

What is this change?

  • updating bash script in the pipeline that sets the dabVersion to add -rc suffix in case it's not a stable release, to identify as a release candidate.

How was this tested?

  • By running pipelines and checking pipeline logs.

@abhishekkumams abhishekkumams linked an issue Jun 29, 2023 that may be closed by this pull request
abhishekkumams and others added 26 commits July 3, 2023 16:04
## Why make this change?

The original config system has a lot of areas where it doesn't provide
concrete types for what we need, due to the flexible nature of the JSON
file, and instead forces the code to check at runtime (is the property a
bool or an object?) and then have branching logic based on that.

This results in duplication of code, as well as hidden assumptions for
what the "expanded" version of shorthand properties (by shorthand
properties I mean properties like `"rest": false` on the `runtime`).

With this change we reduce the config C# type system to only handle the
fully expanded objects, resulting in a clearer structure for what the
types are between JSON and C#, reduce the amount of type casting that
needs to be done when checking the config, and unblocking at ability to
tackle more complex config features, such as #722.

## What is this change?

- Full rewrite of the config type system and "loader" process
- This includes a set of custom `JsonConverter` classes for parts of the
config serializer/deserializer, so that we can expand the config and
apply the defaults as expected. The result of this is that if you
deserialize then serialize the resulting config can look different as we
_always_ serialize to the expanded version
- Leveraging a file system abstraction for easier testing
- Unit tests can generate a mock `RuntimeConfig` and write it to a mock
file system, meaning they are a lot more isolated from each other
- Integration tests can load the "base" `RuntimeConfig` for the DB and
then write out a config (with test-specific features) to the mock file
system, which is then given to the test runner to use, rather than
writing to disk (although some tests will still write to disk)
- Refactored engine to use the new types
- Introduced [Snapshot
Testing](https://jestjs.io/docs/en/snapshot-testing/) via
[Snapshooter](https://github.com/SwissLife-OSS/snapshooter) to make it
easier to see the broad impact of refactors to underlying object
structures
- Refactored the CLI to be a bit more compartmentalised in the code,
relying less on callbacks, making for easier testing of specific
commands

## How was this tested?

- [x] Integration Tests
- [x] Unit Tests
Comment thread .pipelines/build-pipelines.yml
Copy link
Copy Markdown
Contributor

@severussundar severussundar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@abhishekkumams abhishekkumams merged commit a52f103 into main Jul 4, 2023
@abhishekkumams abhishekkumams deleted the dev/abhishekkuma/update_pipelines_to_support_rc branch July 4, 2023 09:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

update pipelines to accommodate -rc

4 participants