示例#1
0
        public string GetPrimaryActiveManager()
        {
            byte[] exBytes = null;
            string pam     = null;

            ClientServices.CallService(delegate
            {
                pam = this.m_wcfClient.GetPrimaryActiveManager(out exBytes);
            });
            if (exBytes != null)
            {
                Exception ex = (Exception)Serialization.BytesToObject(exBytes);
                ExTraceGlobals.ThirdPartyClientTracer.TraceError <Exception>((long)this.GetHashCode(), "GetPAM fails: {0}", ex);
                throw ex;
            }
            ExTraceGlobals.ThirdPartyClientTracer.TraceDebug <string>((long)this.GetHashCode(), "GetPAM returns: {0}", pam);
            return(pam);
        }
示例#2
0
        public void ImmediateDismountMailboxDatabase(Guid dbId)
        {
            Exception serverEx = null;

            byte[] exBytes = null;
            ClientServices.CallService(delegate
            {
                exBytes = this.m_wcfClient.ImmediateDismountMailboxDatabase(dbId);
                if (exBytes != null)
                {
                    serverEx = (Exception)Serialization.BytesToObject(exBytes);
                }
            });
            if (serverEx != null)
            {
                ExTraceGlobals.ThirdPartyClientTracer.TraceError <Guid, Exception>((long)this.GetHashCode(), "ImmediateDismountMailboxDatabase({0}) fails: {1}", dbId, serverEx);
                throw serverEx;
            }
        }
示例#3
0
        public void ChangeActiveServer(Guid dbId, string newNode)
        {
            Exception serverEx = null;

            byte[] exBytes = null;
            ClientServices.CallService(delegate
            {
                exBytes = this.m_wcfClient.ChangeActiveServer(dbId, newNode);
                if (exBytes != null)
                {
                    serverEx = (Exception)Serialization.BytesToObject(exBytes);
                }
            });
            if (serverEx != null)
            {
                ExTraceGlobals.ThirdPartyClientTracer.TraceError <Guid, string, Exception>((long)this.GetHashCode(), "ChangeActiveServer({0},{1}) fails: {2}", dbId, newNode, serverEx);
                throw serverEx;
            }
        }