File tree 2 files changed +35
-1
lines changed
2 files changed +35
-1
lines changed Original file line number Diff line number Diff line change @@ -150,6 +150,9 @@ jobs:
150
150
- name : Compile and test
151
151
timeout-minutes : 90
152
152
run : |
153
+ . .github/workflows/utils.sh
154
+ jvm_timezone=$(random_timezone)
155
+ echo "JVM timezone is set to $jvm_timezone"
153
156
set -o pipefail
154
157
155
158
case ${{ inputs.module }} in
@@ -217,7 +220,7 @@ jobs:
217
220
218
221
build_maven_parameter="${build_maven_parameter:+$build_maven_parameter }${{ inputs.custom-maven-parameter }}"
219
222
220
- mvn --no-snapshot-updates -B -DskipTests -pl $compile_modules -am install && mvn --no-snapshot-updates -B $build_maven_parameter -pl $modules -DspecifiedParallelism=${{ inputs.parallelism }} verify
223
+ mvn --no-snapshot-updates -B -DskipTests -pl $compile_modules -am install && mvn --no-snapshot-updates -B $build_maven_parameter -pl $modules -DspecifiedParallelism=${{ inputs.parallelism }} -Duser.timezone=$jvm_timezone verify
221
224
222
225
- name : Print JVM thread dumps when cancelled
223
226
if : ${{ failure() }}
Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env bash
2
+ # ###############################################################################
3
+ # Licensed to the Apache Software Foundation (ASF) under one
4
+ # or more contributor license agreements. See the NOTICE file
5
+ # distributed with this work for additional information
6
+ # regarding copyright ownership. The ASF licenses this file
7
+ # to you under the Apache License, Version 2.0 (the
8
+ # "License"); you may not use this file except in compliance
9
+ # with the License. You may obtain a copy of the License at
10
+ #
11
+ # http://www.apache.org/licenses/LICENSE-2.0
12
+ #
13
+ # Unless required by applicable law or agreed to in writing, software
14
+ # distributed under the License is distributed on an "AS IS" BASIS,
15
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16
+ # See the License for the specific language governing permissions and
17
+ # limitations under the License.
18
+ # ###############################################################################
19
+
20
+ function random_timezone() {
21
+ local rnd=$( expr $RANDOM % 25)
22
+ local hh=$( expr $rnd / 2)
23
+ local mm=$( expr $rnd % 2 \* 3) " 0"
24
+ local sgn=$( expr $RANDOM % 2)
25
+ if [ $sgn -eq 0 ]
26
+ then
27
+ echo " GMT+$hh :$mm "
28
+ else
29
+ echo " GMT-$hh :$mm "
30
+ fi
31
+ }
You can’t perform that action at this time.
0 commit comments