public void AddService(ServiceNameEnum service)
 {
     if (!_serviceAvailable.Contains(service))
     {
         _serviceAvailable.Add(service);
     }
 }
        public Uri GetUri(ServiceNameEnum serviceName)
        {
            Uri retVal = null;

            if (_testDataServices.ContainsKey(serviceName))
            {
                var testDataService = _testDataServices[serviceName];
                retVal = testDataService.ServiceUri;
            }
            return(retVal);
        }
        private void Initialize(ServiceNameEnum service)
        {
            switch (service)
            {
            case ServiceNameEnum.AppConfig:
                Database.SetInitializer(
                    new SetupMigrateDatabaseToLatestVersion
                    <EFAppConfigRepository, VirtoCommerce.Foundation.Data.AppConfig.Migrations.Configuration>());
                break;

            case ServiceNameEnum.Catalog:
                Database.SetInitializer(
                    new SetupMigrateDatabaseToLatestVersion
                    <EFCatalogRepository, VirtoCommerce.Foundation.Data.Catalogs.Migrations.Configuration>());
                break;

            case ServiceNameEnum.DynamicContent:
                Database.SetInitializer(
                    new SetupMigrateDatabaseToLatestVersion
                    <EFDynamicContentRepository, VirtoCommerce.Foundation.Data.Marketing.Migrations.Content.Configuration>());
                break;

            case ServiceNameEnum.Store:
                Database.SetInitializer(
                    new SetupMigrateDatabaseToLatestVersion
                    <EFStoreRepository, VirtoCommerce.Foundation.Data.Stores.Migrations.Configuration>());
                break;

            case ServiceNameEnum.Order:
                Database.SetInitializer(
                    new SetupMigrateDatabaseToLatestVersion
                    <EFOrderRepository, VirtoCommerce.Foundation.Data.Orders.Migrations.Configuration>());
                break;

            case ServiceNameEnum.Marketing:
                Database.SetInitializer(
                    new SetupMigrateDatabaseToLatestVersion
                    <EFMarketingRepository, VirtoCommerce.Foundation.Data.Marketing.Migrations.Promotion.Configuration>());
                break;
            }
        }
Beispiel #4
0
 /// <summary>
 /// Initializes a new instance of the <see cref="ConnectionServerMonitorServiceStatus" /> class.
 /// </summary>
 /// <param name="serviceName">Service name of the Connection Server. * PCOIP_SECURE_GATEWAY: PCoIP Secure Gateway service. * BLAST_SECURE_GATEWAY: BLAST Secure Gateway service. * SECURITY_GATEWAY_COMPONENT: Security Gateway Component service. (required).</param>
 /// <param name="status">Status of the service. * UP: The Windows service is UP and running. * DOWN: The Windows service is not UP. * UNKNOWN: The Windows service state is Unknown. (required).</param>
 public ConnectionServerMonitorServiceStatus(ServiceNameEnum serviceName = default(ServiceNameEnum), StatusEnum status = default(StatusEnum))
 {
     // to ensure "serviceName" is required (not null)
     if (serviceName == null)
     {
         throw new InvalidDataException("serviceName is a required property for ConnectionServerMonitorServiceStatus and cannot be null");
     }
     else
     {
         this.ServiceName = serviceName;
     }
     // to ensure "status" is required (not null)
     if (status == null)
     {
         throw new InvalidDataException("status is a required property for ConnectionServerMonitorServiceStatus and cannot be null");
     }
     else
     {
         this.Status = status;
     }
 }
Beispiel #5
0
 /// <summary>
 /// Initializes a new instance of the <see cref="GetCorporationsCorporationIdOutpostsOutpostIdService" /> class.
 /// </summary>
 /// <param name="discountPerGoodStanding">discount_per_good_standing number (required).</param>
 /// <param name="minimumStanding">minimum_standing number (required).</param>
 /// <param name="serviceName">service_name string (required).</param>
 /// <param name="surchargePerBadStanding">surcharge_per_bad_standing number (required).</param>
 public GetCorporationsCorporationIdOutpostsOutpostIdService(double?discountPerGoodStanding = default(double?), double?minimumStanding = default(double?), ServiceNameEnum serviceName = default(ServiceNameEnum), double?surchargePerBadStanding = default(double?))
 {
     // to ensure "discountPerGoodStanding" is required (not null)
     if (discountPerGoodStanding == null)
     {
         throw new InvalidDataException("discountPerGoodStanding is a required property for GetCorporationsCorporationIdOutpostsOutpostIdService and cannot be null");
     }
     else
     {
         this.DiscountPerGoodStanding = discountPerGoodStanding;
     }
     // to ensure "minimumStanding" is required (not null)
     if (minimumStanding == null)
     {
         throw new InvalidDataException("minimumStanding is a required property for GetCorporationsCorporationIdOutpostsOutpostIdService and cannot be null");
     }
     else
     {
         this.MinimumStanding = minimumStanding;
     }
     // to ensure "serviceName" is required (not null)
     if (serviceName == null)
     {
         throw new InvalidDataException("serviceName is a required property for GetCorporationsCorporationIdOutpostsOutpostIdService and cannot be null");
     }
     else
     {
         this.ServiceName = serviceName;
     }
     // to ensure "surchargePerBadStanding" is required (not null)
     if (surchargePerBadStanding == null)
     {
         throw new InvalidDataException("surchargePerBadStanding is a required property for GetCorporationsCorporationIdOutpostsOutpostIdService and cannot be null");
     }
     else
     {
         this.SurchargePerBadStanding = surchargePerBadStanding;
     }
 }
Beispiel #6
0
 /// <summary>
 /// Initializes a new instance of the <see cref="GetCorporationsCorporationIdOutpostsOutpostIdService" /> class.
 /// </summary>
 /// <param name="DiscountPerGoodStanding">discount_per_good_standing number (required).</param>
 /// <param name="MinimumStanding">minimum_standing number (required).</param>
 /// <param name="ServiceName">service_name string (required).</param>
 /// <param name="SurchargePerBadStanding">surcharge_per_bad_standing number (required).</param>
 public GetCorporationsCorporationIdOutpostsOutpostIdService(double?DiscountPerGoodStanding = default(double?), double?MinimumStanding = default(double?), ServiceNameEnum ServiceName = default(ServiceNameEnum), double?SurchargePerBadStanding = default(double?))
 {
     // to ensure "DiscountPerGoodStanding" is required (not null)
     if (DiscountPerGoodStanding == null)
     {
         throw new InvalidDataException("DiscountPerGoodStanding is a required property for GetCorporationsCorporationIdOutpostsOutpostIdService and cannot be null");
     }
     else
     {
         this.DiscountPerGoodStanding = DiscountPerGoodStanding;
     }
     // to ensure "MinimumStanding" is required (not null)
     if (MinimumStanding == null)
     {
         throw new InvalidDataException("MinimumStanding is a required property for GetCorporationsCorporationIdOutpostsOutpostIdService and cannot be null");
     }
     else
     {
         this.MinimumStanding = MinimumStanding;
     }
     // to ensure "ServiceName" is required (not null)
     if (ServiceName == null)
     {
         throw new InvalidDataException("ServiceName is a required property for GetCorporationsCorporationIdOutpostsOutpostIdService and cannot be null");
     }
     else
     {
         this.ServiceName = ServiceName;
     }
     // to ensure "SurchargePerBadStanding" is required (not null)
     if (SurchargePerBadStanding == null)
     {
         throw new InvalidDataException("SurchargePerBadStanding is a required property for GetCorporationsCorporationIdOutpostsOutpostIdService and cannot be null");
     }
     else
     {
         this.SurchargePerBadStanding = SurchargePerBadStanding;
     }
 }
        private DbContext GetDbContext(ServiceNameEnum service)
        {
            switch (service)
            {
            case ServiceNameEnum.AppConfig:
                return(new EFAppConfigRepository(TestDSAppConfigService.DatabaseName, new AppConfigEntityFactory()));

            case ServiceNameEnum.Catalog:
                return(new EFCatalogRepository(TestDSCatalogService.DatabaseName, new CatalogEntityFactory()));

            case ServiceNameEnum.DynamicContent:
                return(new EFDynamicContentRepository(TestDSDynamicContentService.DatabaseName, new DynamicContentEntityFactory()));

            case ServiceNameEnum.Store:
                return(new EFStoreRepository(TestDSStoreService.DatabaseName, new StoreEntityFactory()));

            case ServiceNameEnum.Order:
                return(new EFOrderRepository(TestDSOrderService.DatabaseName, new OrderEntityFactory()));

            case ServiceNameEnum.Marketing:
                return(new EFMarketingRepository(TestDSMarketingService.DatabaseName, new MarketingEntityFactory()));
            }
            return(null);
        }
        private TestDataService GetService(ServiceNameEnum service)
        {
            switch (service)
            {
            case ServiceNameEnum.AppConfig:
                return(new TestDataService(typeof(TestDSAppConfigService)));

            case ServiceNameEnum.Catalog:
                return(new TestDataService(typeof(TestDSCatalogService)));

            case ServiceNameEnum.DynamicContent:
                return(new TestDataService(typeof(TestDSDynamicContentService)));

            case ServiceNameEnum.Store:
                return(new TestDataService(typeof(TestDSStoreService)));

            case ServiceNameEnum.Order:
                return(new TestDataService(typeof(TestDSOrderService)));

            case ServiceNameEnum.Marketing:
                return(new TestDataService(typeof(TestDSMarketingService)));
            }
            return(null);
        }
		private DbContext GetDbContext(ServiceNameEnum service)
		{

			switch (service)
			{
				case ServiceNameEnum.AppConfig:
					return new EFAppConfigRepository(TestDSAppConfigService.DatabaseName, new AppConfigEntityFactory());
				case ServiceNameEnum.Catalog:
					return new EFCatalogRepository(TestDSCatalogService.DatabaseName, new CatalogEntityFactory());
				case ServiceNameEnum.DynamicContent:
					return new EFDynamicContentRepository(TestDSDynamicContentService.DatabaseName, new DynamicContentEntityFactory());
				case ServiceNameEnum.Store:
					return new EFStoreRepository(TestDSStoreService.DatabaseName, new StoreEntityFactory());
				case ServiceNameEnum.Order:
					return new EFOrderRepository(TestDSOrderService.DatabaseName, new OrderEntityFactory());
				case ServiceNameEnum.Marketing:
					return new EFMarketingRepository(TestDSMarketingService.DatabaseName, new MarketingEntityFactory());
			}
			return null;
		}
		public Uri GetUri(ServiceNameEnum serviceName)
		{
			Uri retVal = null;
			if (_testDataServices.ContainsKey(serviceName))
			{
				var testDataService = _testDataServices[serviceName];
				retVal = testDataService.ServiceUri;
			}
			return retVal;
		}
		public void AddService(ServiceNameEnum service)
		{
			if (!_serviceAvailable.Contains(service))
			{
				_serviceAvailable.Add(service);
			}
		}
		private TestDataService GetService(ServiceNameEnum service)
		{
			switch (service)
			{
				case ServiceNameEnum.AppConfig:
					return new TestDataService(typeof(TestDSAppConfigService));
				case ServiceNameEnum.Catalog:
					return new TestDataService(typeof(TestDSCatalogService));
				case ServiceNameEnum.DynamicContent:
					return new TestDataService(typeof(TestDSDynamicContentService));
				case ServiceNameEnum.Store:
					return new TestDataService(typeof(TestDSStoreService));
				case ServiceNameEnum.Order:
					return new TestDataService(typeof(TestDSOrderService));
				case ServiceNameEnum.Marketing:
					return new TestDataService(typeof(TestDSMarketingService));
			}
			return null;
		}
		private void Initialize(ServiceNameEnum service)
		{
			switch (service)
			{
				case ServiceNameEnum.AppConfig:
					Database.SetInitializer(
						new SetupMigrateDatabaseToLatestVersion
							<EFAppConfigRepository, VirtoCommerce.Foundation.Data.AppConfig.Migrations.Configuration>());
					break;
				case ServiceNameEnum.Catalog:
					Database.SetInitializer(
						new SetupMigrateDatabaseToLatestVersion
							<EFCatalogRepository, VirtoCommerce.Foundation.Data.Catalogs.Migrations.Configuration>());
					break;
				case ServiceNameEnum.DynamicContent:
										Database.SetInitializer(
						new SetupMigrateDatabaseToLatestVersion
							<EFDynamicContentRepository, VirtoCommerce.Foundation.Data.Marketing.Migrations.Content.Configuration>());
					break;
				case ServiceNameEnum.Store:
										Database.SetInitializer(
						new SetupMigrateDatabaseToLatestVersion
							<EFStoreRepository, VirtoCommerce.Foundation.Data.Stores.Migrations.Configuration>());
					break;
				case ServiceNameEnum.Order:
										Database.SetInitializer(
						new SetupMigrateDatabaseToLatestVersion
							<EFOrderRepository, VirtoCommerce.Foundation.Data.Orders.Migrations.Configuration>());
					break;
				case ServiceNameEnum.Marketing:
										Database.SetInitializer(
						new SetupMigrateDatabaseToLatestVersion
							<EFMarketingRepository, VirtoCommerce.Foundation.Data.Marketing.Migrations.Promotion.Configuration>());
					break;
			}
		}
Beispiel #14
0
 /// <summary>
 /// Initializes a new instance of the <see cref="UpdateGflagParameters" /> class.
 /// </summary>
 /// <param name="gflags">Specifies a list of gflags. These will be added to the existing flags for the service. The values will be overwritten if required. If no value for gflag is specified, this gflag will be reset to default value. If no gflag is specified, all gflags for this service will be reset to default value..</param>
 /// <param name="serviceName">Specifies the service name. &#39;kApollo&#39; is a service for reclaiming freed disk sectors on Nodes in the SnapFS distributed file system. &#39;kBridge&#39; is a service for managing the SnapFS distributed file system. &#39;kGenie&#39; is a service that is responsible for monitoring hardware health on the Cluster. &#39;kGenieGofer&#39; is a service that links the Genie service to other services on the Cluster. &#39;kMagneto&#39; is the data protection service of the Cohesity Data Platform. &#39;kIris&#39; is the service which serves REST API calls to the UI, CLI, and any scripts written by customers. &#39;kIrisProxy&#39; is a service that links the Iris service to other services on the Cluster. &#39;kScribe&#39; is the service responsible for storing filesystem metadata. &#39;kStats&#39; is the service that is responsible for retrieving and aggregating disk metrics across the Cluster. &#39;kYoda&#39; is an elastic search indexing service. &#39;kAlerts&#39; is a publisher and subscribing service for alerts. &#39;kKeychain&#39; is a service for managing disk encryption keys. &#39;kLogWatcher&#39; is a service that scans the log directory and reduces the number of logs if required. &#39;kStatsCollector&#39; is a service that periodically logs system stats. &#39;kGandalf&#39; is a distributed lock service and coordination manager. &#39;kNexus&#39; indicates the Nexus service. This is the service that is responsible for creation of Clusters and configuration of Nodes and networking. &#39;kNexusProxy&#39; is a service that links the Nexus service to other services on the Cluster. &#39;kStorageProxy&#39; is a service for accessing data on external entities. &#39;kTricorder&#39; is a diagnostic health testing service for Clusters. &#39;kRtClient&#39; is a reverse tunneling client service. &#39;kVaultProxy&#39; is a service for managing external targets that Clusters can be backed up to. &#39;kSmbProxy&#39; is an SMB protocol service. &#39;kBridgeProxy&#39; is the service that links the Bridge service to other services on the Cluster. &#39;kLibrarian&#39; is an elastic search indexing service. &#39;kGroot&#39; is a service for managing replication of SQL databases across multiple nodes in a Cluster. &#39;kEagleAgent&#39; is a service that is responsible for retrieving information on Cluster health. &#39;kAthena&#39; is a service for running distributed containerized applications on the Cohesity Data Platform. &#39;kBifrostBroker&#39; is a service for communicating with the Cohesity proxies for multitenancy. &#39;kSmb2Proxy&#39; is a new SMB protocol service. &#39;kOs&#39; can be specified in order to do a full reboot. &#39;kAtom&#39; is a service for receiving data for the Continuous Data Protection. (required).</param>
 public UpdateGflagParameters(List <Gflag> gflags = default(List <Gflag>), ServiceNameEnum serviceName = default(ServiceNameEnum))
 {
     this.Gflags      = gflags;
     this.ServiceName = serviceName;
     this.Gflags      = gflags;
 }