Releases: uber-go/fx
Releases · uber-go/fx
v1.7.1
Fixed
- Make
fxtest.New
ensure that the app was created successfully. Previously,
it would return the app (similar tofx.New
, which expects the user to verify
the error). - Update dig container to defer acyclic validation until after Invoke. Application
startup time should improve proportional to the size of the dependency graph. - Fix a goroutine leak in
fxtest.Lifecycle
.
v1.7.0
v1.6.0
v1.5.0
v1.4.0
Add fx.Populate
to populate variables with values from the dependency injection container without requiring intermediate structs.
v1.3.0
v1.2.0
Add fx.NopLogger
which disables lifecycle output.
v1.1.0
v1.0.0
First stable release: no breaking changes will be made in the 1.x series.
- [Breaking] Rename
fx.Inject
tofx.Extract
. - [Breaking] Rename
fxtest.Must*
tofxtest.Require*
. - [Breaking] Remove
fx.Timeout
andfx.DefaultTimeout
. fx.Extract
now supportsfx.In
tags on target structs.
v1.0.0-rc2
- [Breaking] Lifecycle hooks now take a context.
- Add
fx.In
andfx.Out
which exposes optional and named types.
Modules should embed these types instead of relying ondig.In
anddig.Out
. - Add an
Err
method to retrieve the underlying errors during the dependency
graph construction. The same error is also returned fromStart
. - Graph resolution now happens as part of
fx.New
, rather than at the beginning
ofapp.Start
. This allows inspection of the graph errors throughapp.Err()
before the decision to start the app. - Add a
Logger
option, which allows users to send Fx's logs to different
sink. - Add
fxtest.App
, which redirects log output to the user'stesting.TB
and
provides some lifecycle helpers.