示例#1
0
        private void FinalizePsdkApplicationBlocks()
        {
            if (confServiceContract != null)
            {
                ConfServiceFactory.ReleaseConfService(confServiceContract);
            }
            // Cleanup code
            eventBrokerService.Deactivate();

            eventBrokerService.Dispose();

            // Close Connection if opened (check status of protocol object)
            IProtocol protocol = protocolManagementService[configServerId];

            if (protocol.State == ChannelState.Opened) // Close only if the protocol state is opened
            {
                try
                {
                    protocol.Close();
                }
                catch (Exception ex)
                {
                    Console.Write(ex.Message + "\n" + ex.StackTrace + "\n");
                }
            }

            protocolManagementService.Unregister(configServerId);
        }
示例#2
0
        private static void FinalizePSDKApplicationBlocks()
        {
            ConfServiceFactory.ReleaseConfService(confService);

            // Cleanup code
            eventBrokerService.Deactivate();

            eventBrokerService.Dispose();

            // Close Connection if opened (check status of protocol object)
            IProtocol protocol = protocolManagementService[CONFIGSERVER_IDENTIFIER];

            if (protocol.State == ChannelState.Opened) // Close only if the protocol state is opened
            {
                try
                {
                    protocol.Close();
                }
                catch (Exception ex)
                {
                    log.Error(ex.Message, ex);
                }
            }
            protocolManagementService.Unregister(CONFIGSERVER_IDENTIFIER);
        }
示例#3
0
        public void FinalizePSDKApplicationBlocks()
        {
            // Cleanup code
            _mEventBroker.Deactivate();

            _mEventBroker.Dispose();


            try
            {
                _messageServerProtocol.Close();
            }
            catch (Exception ex)
            {
                Console.Write(ex.Message + "\n" + ex.StackTrace + "\n");
            }

            _messageServerProtocol.Dispose();
            _messageServerProtocol = null;
        }
示例#4
0
        public void FinalizePSDKApplicationBlocks()
        {
            // Cleanup code
            eventBrokerService.Deactivate();

            eventBrokerService.Dispose();

            // Close Connection if opened (check status of protocol object)
            IProtocol protocol = protocolManagementService[ISERVER_IDENTIFIER];

            if (protocol.State == ChannelState.Opened) // Close only if the protocol state is opened
            {
                try
                {
                    protocol.Close();
                }
                catch (Exception ex)
                {
                    LogException(ex);
                }
            }

            protocolManagementService.Unregister(ISERVER_IDENTIFIER);
        }
示例#5
0
        private void FinalizePSDKApplicationBlocks()
        {
            // Cleanup code
            eventBrokerService.Deactivate();

            eventBrokerService.Dispose();

            // Close Connection if opened (check status of protocol object)
            IProtocol protocol = protocolManagementService[OCS_IDENTIFIER];

            if (protocol.State == ChannelState.Opened) // Close only if the protocol state is opened
            {
                try
                {
                    protocol.Close();
                }
                catch (Exception ex)
                {
                    Console.Write(ex.Message + "\n" + ex.StackTrace + "\n");
                }
            }

            protocolManagementService.Unregister(OCS_IDENTIFIER);
        }