A massive chunk of work with lots of changes (sorry). A lot of the changes have to do with trying to create a good structure with "interfaces", and trying to tame imports and exports to not do strange things. Otherwise, a lot of small fixes on documentations and overloads across the board.
On the bigger things, like in the next .NET SDK - we're changing up how the client is built from one step to two steps, to make it easier to integrate with other frameworks and allow us to do an initial asynchronous call to the Runtime while booting up to get some configuration going from the start. A lot of work has gone into the dependency inversion system, which internally is using InversifyJS (with some hacks), but should easily support a root container from any kind of DI package for TS. A little work on how we deal with decorators, also made it easy to create our own injection decorators that don't rely on reflect-metadata. It's not perfect but I think it's better than requiring users to import this special package once.
Added
Dependency injection of services to EventHandlers
Tenant-specific dependency injection system using InversifyJS internally - exposed as custom interfaces mimicking .NET setup.
Metadata decorator factory for using in the SDK that keeps data on the classes. This allows a little more flexibility on using different versions of the SDK to declare e.g. event types since we no longer depend on a global registry to keep track of them.
disconnect() on the client that stops all processors and waits for them to finish before returning.
Changed
Removed index.ts files in directories, and changed to _exports.ts to help us avoid wrong import statements.
Split up the .build() call to create the client into .setup() + .connect(), to simplify integrations with other frameworks and setting up the configuration.
Interface for working with Aggregate Roots - this is now more in line with the apis for the other artefacts.
Fixed
import files directly within packages.
Removed
Extension methods in the protobuf project, they seem very tied to how things are imported and exported.
The old IContainer interface and usage in the client. The new setup with multiple containers is easier to work with and makes more sense.
Summary
A massive chunk of work with lots of changes (sorry). A lot of the changes have to do with trying to create a good structure with "interfaces", and trying to tame imports and exports to not do strange things. Otherwise, a lot of small fixes on documentations and overloads across the board.
On the bigger things, like in the next .NET SDK - we're changing up how the client is built from one step to two steps, to make it easier to integrate with other frameworks and allow us to do an initial asynchronous call to the Runtime while booting up to get some configuration going from the start. A lot of work has gone into the dependency inversion system, which internally is using InversifyJS (with some hacks), but should easily support a root container from any kind of DI package for TS. A little work on how we deal with decorators, also made it easy to create our own injection decorators that don't rely on
reflect-metadata
. It's not perfect but I think it's better than requiring users to import this special package once.Added
disconnect()
on the client that stops all processors and waits for them to finish before returning.Changed
index.ts
files in directories, and changed to_exports.ts
to help us avoid wrongimport
statements..build()
call to create the client into.setup()
+.connect()
, to simplify integrations with other frameworks and setting up the configuration.Fixed
import
files directly within packages.Removed
IContainer
interface and usage in the client. The new setup with multiple containers is easier to work with and makes more sense.