diff --git a/ZB.MOM.WW.GalaxyRepository/src/ZB.MOM.WW.GalaxyRepository/DependencyInjection/GalaxyRepositoryServiceCollectionExtensions.cs b/ZB.MOM.WW.GalaxyRepository/src/ZB.MOM.WW.GalaxyRepository/DependencyInjection/GalaxyRepositoryServiceCollectionExtensions.cs index b69895d..38596c9 100644 --- a/ZB.MOM.WW.GalaxyRepository/src/ZB.MOM.WW.GalaxyRepository/DependencyInjection/GalaxyRepositoryServiceCollectionExtensions.cs +++ b/ZB.MOM.WW.GalaxyRepository/src/ZB.MOM.WW.GalaxyRepository/DependencyInjection/GalaxyRepositoryServiceCollectionExtensions.cs @@ -36,10 +36,12 @@ public static class GalaxyRepositoryServiceCollectionExtensions ArgumentNullException.ThrowIfNull(configuration); ArgumentException.ThrowIfNullOrWhiteSpace(sectionPath); + // Bind only — this shared lib ships no validator, so a .ValidateOnStart() here + // would be a silent no-op. The consuming application owns option validation + // (e.g. the sidecar's ConfigPreflight / validated-options layer). services .AddOptions() - .Bind(configuration.GetSection(sectionPath)) - .ValidateOnStart(); + .Bind(configuration.GetSection(sectionPath)); services.AddSingleton(sp => new GalaxyRepository(sp.GetRequiredService>().Value));