Skip to content

Commit 4de31d1

Browse files
committed
dashboard: change the default instance type for GCE builders
This change increases the default resources allocated to builders running on GCE. Testing has shown a reduction in all.bash build times for the machines with larger resources. A few unit tests that use the default sizes have also been updated throughout the repository. Updates golang/go#17104 Change-Id: I92ba4509bf667da432f011d8f61d2dea7dac5fc4 Reviewed-on: https://go-review.googlesource.com/c/build/+/413420 Reviewed-by: Alex Rakoczy <[email protected]> Reviewed-by: Dmitri Shuralyov <[email protected]>
1 parent bcadfe3 commit 4de31d1

File tree

3 files changed

+18
-18
lines changed

3 files changed

+18
-18
lines changed

buildlet/ec2_test.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -363,7 +363,7 @@ func TestConfigureVM(t *testing.T) {
363363
vmName: "base_vm",
364364
hostType: "host-foo-bar",
365365
opts: &VMOpts{},
366-
wantInstanceType: "e2-highcpu-2",
366+
wantInstanceType: "e2-standard-8",
367367
wantName: "base_vm",
368368
wantBuildletName: "base_vm",
369369
wantBuildletImage: "gcr.io/symbolic-datum-552/gobuilder-arm64-aws",
@@ -390,7 +390,7 @@ func TestConfigureVM(t *testing.T) {
390390
},
391391
wantDesc: "test description",
392392
wantImageID: "awesome_image",
393-
wantInstanceType: "e2-highcpu-2",
393+
wantInstanceType: "e2-standard-8",
394394
wantName: "base-vm",
395395
wantZone: "sa-west",
396396
wantBuildletName: "base-vm",

dashboard/builders.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -1384,9 +1384,9 @@ func (c *HostConfig) MachineType() string {
13841384
// so their /workdir tmpfs can be larger. The COS
13851385
// image has no swap, so we want to make sure the
13861386
// /workdir fits completely in memory.
1387-
return "e2-standard-4" // 4 vCPUs, 16 GB mem
1387+
return "e2-standard-16" // 16 vCPUs, 64 GB mem
13881388
}
1389-
return "e2-highcpu-2"
1389+
return "e2-standard-8" // 8 vCPUs, 32 GB mem
13901390
}
13911391

13921392
// IsEC2 returns true if the machine type is an EC2 arm64 type.

internal/coordinator/pool/ec2_test.go

+14-14
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@ func TestEC2BuildletGetBuildlet(t *testing.T) {
3131
// set to default gce type because there is no way to set the machine
3232
// type from outside of the buildenv package.
3333
{
34-
Type: "e2-standard-4",
35-
CPU: 4,
34+
Type: "e2-standard-16",
35+
CPU: 16,
3636
},
3737
})
3838
l.SetCPULimit(20)
@@ -175,9 +175,9 @@ func TestEC2BuildletGetBuildletLogger(t *testing.T) {
175175
cpuUsed: 0,
176176
entries: make(map[string]*entry),
177177
types: map[string]*cloud.InstanceType{
178-
"e2-highcpu-2": {
179-
Type: "e2-highcpu-2",
180-
CPU: 4,
178+
"e2-standard-8": {
179+
Type: "e2-standard-8",
180+
CPU: 8,
181181
},
182182
},
183183
},
@@ -200,9 +200,9 @@ func TestEC2BuildletGetBuildletLogger(t *testing.T) {
200200
cpuUsed: 0,
201201
entries: make(map[string]*entry),
202202
types: map[string]*cloud.InstanceType{
203-
"e2-highcpu-2": {
204-
Type: "e2-highcpu-2",
205-
CPU: 4,
203+
"e2-standard-8": {
204+
Type: "e2-standard-8",
205+
CPU: 8,
206206
},
207207
},
208208
},
@@ -225,9 +225,9 @@ func TestEC2BuildletGetBuildletLogger(t *testing.T) {
225225
cpuUsed: 0,
226226
entries: make(map[string]*entry),
227227
types: map[string]*cloud.InstanceType{
228-
"e2-highcpu-2": {
229-
Type: "e2-highcpu-2",
230-
CPU: 4,
228+
"e2-standard-8": {
229+
Type: "e2-standard-8",
230+
CPU: 8,
231231
},
232232
},
233233
},
@@ -250,9 +250,9 @@ func TestEC2BuildletGetBuildletLogger(t *testing.T) {
250250
cpuUsed: 0,
251251
entries: make(map[string]*entry),
252252
types: map[string]*cloud.InstanceType{
253-
"e2-highcpu-2": {
254-
Type: "e2-highcpu-2",
255-
CPU: 4,
253+
"e2-standard-8": {
254+
Type: "e2-standard-8",
255+
CPU: 8,
256256
},
257257
},
258258
},

0 commit comments

Comments
 (0)