// Token: 0x060005E9 RID: 1513 RVA: 0x00016650 File Offset: 0x00014850
 public IDistributedStoreKey GetBaseKey(DxStoreKeyAccessMode mode, CachedChannelFactory <IDxStoreAccess> channelFactory = null, string nodeName = null, bool isPrivate = false)
 {
     return(this.RunOperationAndTranslateException <DxStoreKey>(OperationCategory.GetBaseKey, string.Empty, delegate()
     {
         channelFactory = (channelFactory ?? this.GetFactory(nodeName, null));
         IDxStoreAccessClient dxStoreAccessClient;
         if (this.GroupConfig.Settings.IsUseHttpTransportForClientCommunication)
         {
             dxStoreAccessClient = new HttpStoreAccessClient(this.GroupConfig.Self, HttpClient.TargetInfo.BuildFromNode(nodeName, this.GroupConfig), this.GroupConfig.Settings.StoreAccessHttpTimeoutInMSec);
         }
         else
         {
             dxStoreAccessClient = new WcfStoreAccessClient(channelFactory, null);
         }
         DxStoreAccessRequest.CheckKey checkKey = new DxStoreAccessRequest.CheckKey();
         checkKey.Initialize(string.Empty, isPrivate, this.ConfigProvider.Self);
         DxStoreAccessReply.CheckKey checkKey2 = dxStoreAccessClient.CheckKey(checkKey, null);
         if (checkKey2.ReadResult.IsStale)
         {
             throw new DxStoreInstanceStaleStoreException();
         }
         if (!checkKey2.IsExist)
         {
             throw new DxStoreKeyNotFoundException(string.Empty);
         }
         DxStoreKey.BaseKeyParameters baseParameters = new DxStoreKey.BaseKeyParameters
         {
             Client = dxStoreAccessClient,
             KeyFactory = this,
             Self = this.ConfigProvider.Self,
             IsPrivate = isPrivate,
             DefaultReadOptions = new ReadOptions(),
             DefaultWriteOptions = new WriteOptions()
         };
         return new DxStoreKey(string.Empty, mode, baseParameters);
     }, false));
 }
Beispiel #2
0
 // Token: 0x060005B2 RID: 1458 RVA: 0x000156F9 File Offset: 0x000138F9
 public DxStoreKey(string keyFullName, DxStoreKeyAccessMode mode, DxStoreKey.BaseKeyParameters baseParameters)
 {
     this.FullKeyName    = keyFullName;
     this.Mode           = mode;
     this.BaseParameters = baseParameters;
 }