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
There are some scenarios, such as platform support, where a component factory is expected to fail. The component test template always assumes that the factory is going to succeed, meaning on unsupported platforms the test will fail.
Perhaps a template could be added to mdatagen that will generate another component_test.go under different build tags that expects the factory to error out?
Alternatives
Perhaps we think factories should never error out and simply fail every scrape with an unsupported platform error? I would think we should prefer failing fast at the configuration stage for something like this though.
EDIT: Discussion in the Collector SIG on May 21, 2025 leaned almost unanimously in favour of factories failing fast.