File tree 3 files changed +17
-3
lines changed
src/main/java/com/microsoft/azure/vmagent/builders
3 files changed +17
-3
lines changed Original file line number Diff line number Diff line change 44
44
<dependency >
45
45
<groupId >io.jenkins.tools.bom</groupId >
46
46
<artifactId >bom-${jenkins.baseline}.x</artifactId >
47
- <version >4545.v56392b_7ca_7b_a_ </version >
47
+ <version >4570.v1b_c718dd3b_1e </version >
48
48
<scope >import</scope >
49
49
<type >pom</type >
50
50
</dependency >
151
151
<dependency >
152
152
<groupId >com.puppycrawl.tools</groupId >
153
153
<artifactId >checkstyle</artifactId >
154
- <version >10.21.4 </version >
154
+ <version >10.23.0 </version >
155
155
</dependency >
156
156
</dependencies >
157
157
<executions >
Original file line number Diff line number Diff line change 6
6
import com .microsoft .azure .vmagent .launcher .AzureInboundLauncher ;
7
7
import com .microsoft .azure .vmagent .launcher .AzureSSHLauncher ;
8
8
import com .microsoft .azure .vmagent .util .Constants ;
9
+ import com .microsoft .azure .vmagent .availability .NoAvailabilityRequired ;
9
10
10
11
public class AzureVMTemplateBuilder extends AzureVMTemplateFluent <AzureVMTemplateBuilder > {
11
12
12
13
private AzureVMTemplateFluent <?> fluent ;
13
14
14
15
public AzureVMTemplateBuilder () {
15
16
this .fluent = this ;
17
+ fluent .withMaxVirtualMachinesLimit ("10" );
16
18
}
17
19
18
20
public AzureVMTemplateBuilder (AzureVMAgentTemplate template ) {
@@ -96,7 +98,7 @@ public AzureVMAgentTemplate build() {
96
98
fluent .getDescription (),
97
99
fluent .getLabels (),
98
100
fluent .getLocation (),
99
- null ,
101
+ new NoAvailabilityRequired () ,
100
102
fluent .getVirtualMachineSize (),
101
103
fluent .getStorageAccountNameReferenceType (),
102
104
fluent .getStorageAccountType (),
Original file line number Diff line number Diff line change 12
12
13
13
public class AzureVMTemplateFluent <T extends AzureVMTemplateFluent <T >> {
14
14
15
+ private String maxVirtualMachinesLimit ;
16
+
15
17
private String name ;
16
18
17
19
private String description ;
@@ -57,6 +59,7 @@ public class AzureVMTemplateFluent<T extends AzureVMTemplateFluent<T>> {
57
59
private List <AzureTagPair > cloudTags ;
58
60
59
61
public AzureVMTemplateFluent () {
62
+ maxVirtualMachinesLimit = "10" ;
60
63
location = "Japan West" ;
61
64
virtualMachineSize = "Standard_A0" ;
62
65
storageAccountType = "Standard_LRS" ;
@@ -73,6 +76,11 @@ public AzureVMTemplateFluent() {
73
76
}
74
77
75
78
//CHECKSTYLE:OFF
79
+ public T withMaxVirtualMachinesLimit (String maxVirtualMachinesLimit ) {
80
+ this .maxVirtualMachinesLimit = maxVirtualMachinesLimit ;
81
+ return (T ) this ;
82
+ }
83
+
76
84
public T withName (String name ) {
77
85
this .name = name ;
78
86
return (T ) this ;
@@ -208,6 +216,10 @@ public T withAdminCredential(String credentialsId) {
208
216
}
209
217
//CHECKSTYLE:ON
210
218
219
+ public String getMaxVirtualMachinesLimit () {
220
+ return maxVirtualMachinesLimit ;
221
+ }
222
+
211
223
public String getName () {
212
224
return name ;
213
225
}
You can’t perform that action at this time.
0 commit comments