/// <summary>Führt anwendungsspezifische Aufgaben durch, die mit der Freigabe, der Zurückgabe oder dem Zurücksetzen von nicht verwalteten Ressourcen zusammenhängen.</summary>
        public void Dispose()
        {
            var           proxy   = client.CreateProxy <IIpcWinSvcWatchDog>(watchDogName);
            ServiceConfig Section = JsonSettingsSection.GetSection <ServiceConfig>("GenericService_ServiceConfiguration");

            if (Section.UseExtConfig)
            {
                var cp = Process.GetCurrentProcess();
                proxy.RegisterRegularShutdown(cp.MachineName, Section.ServiceName, cp.ProcessName, cp.Id);
            }

            OnDisposed();
        }
        /// <summary>Initializes this deferred initializable object</summary>
        public void Initialize()
        {
            var           proxy   = client.CreateProxy <IIpcWinSvcWatchDog>(watchDogName);
            ServiceConfig Section = JsonSettingsSection.GetSection <ServiceConfig>("GenericService_ServiceConfiguration");

            if (Section.UseExtConfig)
            {
                var cp = Process.GetCurrentProcess();
                proxy.RegisterService(cp.MachineName, Section.ServiceName, cp.ProcessName, cp.Id);
            }
            else
            {
                LogEnvironment.LogEvent("Unable to register a service that is using xml-configuration", LogSeverity.Error);
            }

            Initialized = true;
        }