Skip to content

Commit b883a06

Browse files
authored
Workaround to fix dse builds (#392)
* Workaround to fix dse builds
1 parent 8bbe9fa commit b883a06

File tree

1 file changed

+38
-22
lines changed

1 file changed

+38
-22
lines changed

Jenkinsfile

Lines changed: 38 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,22 @@ def initializeEnvironment() {
2828
sh label: 'Download Apache Cassandra or DataStax Enterprise', script: '''#!/bin/bash -lex
2929
. ${CCM_ENVIRONMENT_SHELL} ${CASSANDRA_VERSION}
3030
'''
31+
32+
if (env.CASSANDRA_VERSION.split('-')[0] == 'dse') {
33+
env.DSE_FIXED_VERSION = env.CASSANDRA_VERSION.split('-')[1]
34+
sh label: 'Update environment for DataStax Enterprise', script: '''#!/bin/bash -le
35+
cat >> ${HOME}/environment.txt << ENVIRONMENT_EOF
36+
CCM_PATH=${HOME}/ccm
37+
CCM_CASSANDRA_VERSION=${DSE_FIXED_VERSION} # maintain for backwards compatibility
38+
CCM_VERSION=${DSE_FIXED_VERSION}
39+
CCM_SERVER_TYPE=dse
40+
DSE_VERSION=${DSE_FIXED_VERSION}
41+
CCM_IS_DSE=true
42+
CCM_BRANCH=${DSE_FIXED_VERSION}
43+
DSE_BRANCH=${DSE_FIXED_VERSION}
44+
ENVIRONMENT_EOF
45+
'''
46+
}
3147

3248
sh label: 'Display Node.js and environment information', script: '''#!/bin/bash -le
3349
# Load CCM environment variables
@@ -225,10 +241,10 @@ pipeline {
225241
choices: ['2.1', // Legacy Apache Cassandra
226242
'3.11', // Current Apache Cassandra
227243
'4.0', // Development Apache Cassandra
228-
'dse-5.1', // Legacy DataStax Enterprise
229-
'dse-6.0', // Previous DataStax Enterprise
230-
'dse-6.7', // Current DataStax Enterprise
231-
'dse-6.8', // Development DataStax Enterprise
244+
'dse-5.1.35', // Legacy DataStax Enterprise
245+
'dse-6.0.18', // Previous DataStax Enterprise
246+
'dse-6.7.17', // Current DataStax Enterprise
247+
'dse-6.8.30', // Development DataStax Enterprise
232248
'ALL'],
233249
description: '''Apache Cassandra and DataStax Enterprise server version to use for adhoc <b>BUILD-AND-EXECUTE-TESTS</b> <strong>ONLY!</strong>
234250
<table style="width:100%">
@@ -320,10 +336,10 @@ pipeline {
320336
values '2.1', // Legacy Apache Cassandra
321337
'3.11', // Current Apache Cassandra
322338
'4.0', // Development Apache Cassandra
323-
'dse-5.1', // Legacy DataStax Enterprise
324-
'dse-6.0', // Previous DataStax Enterprise
325-
'dse-6.7', // Current DataStax Enterprise
326-
'dse-6.8' // Development DataStax Enterprise
339+
'dse-5.1.35', // Legacy DataStax Enterprise
340+
'dse-6.0.18', // Previous DataStax Enterprise
341+
'dse-6.7.17', // Current DataStax Enterprise
342+
'dse-6.8.30' // Development DataStax Enterprise
327343
}
328344
axis {
329345
name 'NODEJS_VERSION'
@@ -339,7 +355,7 @@ pipeline {
339355
}
340356
axis {
341357
name 'CASSANDRA_VERSION'
342-
values '3.11', '4.0', 'dse-5.1', 'dse-6.8'
358+
values '3.11', '4.0', 'dse-5.1.35', 'dse-6.8.30'
343359
}
344360
}
345361
exclude {
@@ -349,7 +365,7 @@ pipeline {
349365
}
350366
axis {
351367
name 'CASSANDRA_VERSION'
352-
values '2.1', '4.0', 'dse-5.1', 'dse-6.0', 'dse-6.7'
368+
values '2.1', '4.0', 'dse-5.1.35', 'dse-6.0.18', 'dse-6.7.17'
353369
}
354370
}
355371
exclude {
@@ -359,7 +375,7 @@ pipeline {
359375
}
360376
axis {
361377
name 'CASSANDRA_VERSION'
362-
values '2.1', '3.11', 'dse-6.0', 'dse-6.8'
378+
values '2.1', '3.11', 'dse-6.0.18', 'dse-6.8.30'
363379
}
364380
}
365381
}
@@ -408,7 +424,7 @@ pipeline {
408424
}
409425
stage('Execute-Examples') {
410426
when {
411-
expression { env.CASSANDRA_VERSION == 'dse-6.7' }
427+
expression { env.CASSANDRA_VERSION == 'dse-6.7.17' }
412428
}
413429
steps {
414430
executeExamples()
@@ -449,10 +465,10 @@ pipeline {
449465
values '2.1', // Legacy Apache Cassandra
450466
'3.11', // Current Apache Cassandra
451467
'4.0', // Development Apache Cassandra
452-
'dse-5.1', // Legacy DataStax Enterprise
453-
'dse-6.0', // Previous DataStax Enterprise
454-
'dse-6.7', // Current DataStax Enterprise
455-
'dse-6.8' // Development DataStax Enterprise
468+
'dse-5.1.35', // Legacy DataStax Enterprise
469+
'dse-6.0.18', // Previous DataStax Enterprise
470+
'dse-6.7.17', // Current DataStax Enterprise
471+
'dse-6.8.30' // Development DataStax Enterprise
456472
}
457473
axis {
458474
name 'NODEJS_VERSION'
@@ -468,7 +484,7 @@ pipeline {
468484
}
469485
axis {
470486
name 'CASSANDRA_VERSION'
471-
values '2.1', '3.11', '4.0', 'dse-5.1', 'dse-6.0', 'dse-6.7'
487+
values '2.1', '3.11', '4.0', 'dse-5.1.35', 'dse-6.0.18', 'dse-6.7.17'
472488
}
473489
}
474490
}
@@ -517,7 +533,7 @@ pipeline {
517533
}
518534
stage('Execute-Examples') {
519535
when {
520-
expression { env.CASSANDRA_VERSION == 'dse-6.7' }
536+
expression { env.CASSANDRA_VERSION == 'dse-6.7.17' }
521537
}
522538
steps {
523539
executeExamples()
@@ -556,10 +572,10 @@ pipeline {
556572
values '2.1', // Legacy Apache Cassandra
557573
'3.11', // Current Apache Cassandra
558574
'4.0', // Development Apache Cassandra
559-
'dse-5.1', // Legacy DataStax Enterprise
560-
'dse-6.0', // Previous DataStax Enterprise
561-
'dse-6.7', // Current DataStax Enterprise
562-
'dse-6.8' // Development DataStax Enterprise
575+
'dse-5.1.35', // Legacy DataStax Enterprise
576+
'dse-6.0.18', // Previous DataStax Enterprise
577+
'dse-6.7.17', // Current DataStax Enterprise
578+
'dse-6.8.30' // Development DataStax Enterprise
563579
}
564580
axis {
565581
name 'NODEJS_VERSION'

0 commit comments

Comments
 (0)