Samuel Berthe
Samuel Berthe
The new [slog](https://pkg.go.dev/golang.org/x/exp/slog) library provides a `slog.LogValuer` interface for formatting attributes. Documentation here: https://pkg.go.dev/golang.org/x/exp/slog#hdr-Customizing_a_type_s_logging_behavior I think cockroachdb/errors should implement it. ```go type customError struct { ... } func (e customError)...
I'm opening an issue to investigate a bug from @GreyXor, shared in #45. # I have two services, `Config` and `Event`. Where `Event` is a dependency of `Config`. ```go type...
-> https://go.dev/play/ Link these examples into documentation, code comments, and xxxx_example_test.go files
Debugging IoC is a pain. An OTEL plugin listening to lifecycle events would be very nice. Requires #73. I imagine an API similar to this: ```go import ( "github.com/samber/do/v2" "github.com/samber/do/observability/otel/v2"...
Currently, we listen to the following events: - AfterRegistration - AfterShutdown I would add: - BeforeRegistration - BeforeShutdown - BeforeClone - AfterClone - BeforeInvocation - AfterInvocation
We should be able to add multiple callbacks for each hook: ```go type InjectorOpts struct { HookAfterRegistration []func(scope *Scope, serviceName string) HookAfterShutdown []func(scope *Scope, serviceName string) Logf []func(format string, args...
`AfterRegistration` and `AfterShutdown` are currently defined globally. It would be nice to listen events at the scope level. In a big project, having tons of libs and modules, a developer...
Add such method: ```go injector.AddAfterRegistrationListener(...) injector.RemoveAfterRegistrationListener(...) ``` These methods should support variadic parameters.

Example: ``` uptimerobot_uptime{c1_name="probe",c2_url="https://a.b.c.com/",c3_type="1",c4_sub_type="",c5_keyword_type="None",c6_keyword_value="",c7_http_username="None",c8_port="",c9_interval="60",c10_days="1"} 100 uptimerobot_uptime{c1_name="probe",c2_url="https://a.b.c.com/",c3_type="1",c4_sub_type="",c5_keyword_type="None",c6_keyword_value="",c7_http_username="None",c8_port="",c9_interval="60",c10_days="7"} 99.6 uptimerobot_uptime{c1_name="probe",c2_url="https://a.b.c.com/",c3_type="1",c4_sub_type="",c5_keyword_type="None",c6_keyword_value="",c7_http_username="None",c8_port="",c9_interval="60",c10_days="30"} 99.987 ```