protected override void ProcessRecord()
        {
            AutoScaleParameters parameters = new AutoScaleParameters(this.BatchContext, this.Id, null,
                                                                     this.AutoScaleFormula, this.AdditionalBehaviors);

            BatchClient.EnableAutoScale(parameters);
        }
Пример #2
0
        public override void ExecuteCmdlet()
        {
            AutoScaleParameters parameters = new AutoScaleParameters(this.BatchContext, this.Id, null,
                                                                     this.AutoScaleFormula, this.AdditionalBehaviors);

            BatchClient.EnableAutoScale(parameters);
        }
Пример #3
0
        public static void EnableAutoScale(BatchController controller, BatchAccountContext context, string poolId)
        {
            BatchClient client = new BatchClient(controller.BatchManagementClient, controller.ResourceManagementClient);

            string formula = "$TargetDedicated=2";
            AutoScaleParameters parameters = new AutoScaleParameters(context, poolId, null, formula);

            client.EnableAutoScale(parameters);
        }
Пример #4
0
        public static void EnableAutoScale(BatchController controller, BatchAccountContext context, string poolId)
        {
            RequestInterceptor interceptor = CreateHttpRecordingInterceptor();

            BatchClientBehavior[] behaviors = new BatchClientBehavior[] { interceptor };
            BatchClient           client    = new BatchClient(controller.BatchManagementClient, controller.ResourceManagementClient);

            string formula = "$TargetDedicated=2";
            AutoScaleParameters parameters = new AutoScaleParameters(context, poolId, null, formula, behaviors);

            client.EnableAutoScale(parameters);
        }