public bool Start(out string operationResultMessage)
        {
            // This will start the integration client.
            if (Arbiter == null)
            {
                operationResultMessage = "Arbiter not assigned.";
                return false;
            }

            if (IsStarted)
            {
                operationResultMessage = "Adapter already started.";
                return false;
            }

            if (_integrationClient == null)
            {
                _integrationClient = new TransportIntegrationClient(_integrationUri);
            }

            if (_integrationClient != null && _integrationClientId.IsEmpty == false)
            {
                _integrationClient.SetArbiterSubscriptionClientId(_integrationClientId);
            }

            _integrationClient.MandatoryRequestMessageReceiverID = this.SubscriptionClientID;

            _integrationClient.ConnectionStatusChangedEvent += new TransportIntegrationClient.ConnectionStatusChangedDelegate(_integrationClient_ConnectionStatusChangedEvent);
            Arbiter.AddClient(_integrationClient);
            _integrationClientId = _integrationClient.SubscriptionClientID;

            _isStarted = true;

            ChangeOperationalState(OperationalStateEnum.Initialized);

            operationResultMessage = string.Empty;
            return true;
        }
        public override bool ArbiterUnInitialize()
        {
            RegisterSourceMessage register = new RegisterSourceMessage(false);
            register.RequestResponce = false;
            this.Send(register);

            if (_integrationClient != null)
            {
                lock (this)
                {
                    if (Arbiter != null)
                    {
                        Arbiter.RemoveClient(_integrationClient);
                    }

                    _integrationClient.ConnectionStatusChangedEvent -= new TransportIntegrationClient.ConnectionStatusChangedDelegate(_integrationClient_ConnectionStatusChangedEvent);
                    _integrationClient = null;
                }
            }

            return base.ArbiterUnInitialize();
        }