diff --git a/Vostok.Hosting/VostokHost.cs b/Vostok.Hosting/VostokHost.cs index cf649fc4..ec7515d4 100644 --- a/Vostok.Hosting/VostokHost.cs +++ b/Vostok.Hosting/VostokHost.cs @@ -177,7 +177,7 @@ public Task StopAsync(bool ensureSuccess = true) public VostokHost RegisterSigtermCancellation() { #if NET6_0_OR_GREATER - // Saving PosixSignalRegistration to variable, because of IDisposable inheritance, + // Saving PosixSignalRegistration reference to nameof(VostokHost) field, because of IDisposable inheritance, // and GC will collect if not assigned. On Dispose and finalize handler will unregister. if (sigtermRegistration == null) { diff --git a/Vostok.Hosting/VostokHost_Extensions.cs b/Vostok.Hosting/VostokHost_Extensions.cs index 07718923..d6626bf5 100644 --- a/Vostok.Hosting/VostokHost_Extensions.cs +++ b/Vostok.Hosting/VostokHost_Extensions.cs @@ -48,7 +48,9 @@ public static VostokHost WithConsoleCancellation([NotNull] this VostokHost vosto return vostokHost; } - [Obsolete("Use VostokHost.RegisterSigtermCancellation instead of this")] + /// + /// Makes same as + /// public static VostokHost WithSigtermCancellation([NotNull] this VostokHost vostokHost) => vostokHost.RegisterSigtermCancellation(); }