Skip to content

Commit a265d08

Browse files
authored
Merge branch 'develop' into validate_stale_conn
2 parents 9afa1c4 + 8a4aee2 commit a265d08

File tree

384 files changed

+57249
-2984
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

384 files changed

+57249
-2984
lines changed

.github/workflows/analysis.yml

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -53,15 +53,6 @@ jobs:
5353
path: ~/.m2
5454
key: ${{ runner.os }}-m2-${{ hashFiles('**/pom.xml') }}
5555
restore-keys: ${{ runner.os }}-m2
56-
- name: Check style and spell
57-
uses: zhicwu/checkstyle-action@master
58-
with:
59-
github_token: ${{ secrets.GITHUB_TOKEN }}
60-
reporter: 'github-pr-check'
61-
# added,diff_context,file,nofilter
62-
filter_mode: 'added'
63-
if: github.event_name == 'pull_request_target' || github.event.inputs.pr != ''
64-
continue-on-error: true
6556
- name: Update sonar config
6657
run: |
6758
sed -i -e 's|^\(.*<sonar.projectKey>\).*\(</sonar.projectKey>\)$|\1ClickHouse_clickhouse-jdbc\2|' \
@@ -73,5 +64,6 @@ jobs:
7364
SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }}
7465
run: |
7566
find . -type f -name "log4j.*" -exec rm -fv '{}' \;
76-
mvn -q --batch-mode -Panalysis verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar
67+
mvn -q --batch-mode --global-toolchains .github/toolchains.xml -Drelease \
68+
-Panalysis verify org.sonarsource.scanner.maven:sonar-maven-plugin:sonar
7769
continue-on-error: true

.github/workflows/benchmark.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -61,8 +61,8 @@ jobs:
6161
run: |
6262
mvn --batch-mode --update-snapshots -q -DskipTests install
6363
cd clickhouse-benchmark
64-
mvn --batch-mode --update-snapshots install
65-
java -DclickhouseVersion="21.8" -jar target/benchmarks.jar -rf text -p client=clickhouse-jdbc Basic
64+
java -DclickhouseVersion="21.8" -jar target/benchmarks.jar -rf text \
65+
-p client=clickhouse-http-jdbc -p client=clickhouse-grpc-jdbc -p type=default Basic
6666
echo "BENCHMARK_REPORT<<EOF" >> $GITHUB_ENV
6767
cat jmh-result.text >> $GITHUB_ENV
6868
echo "EOF" >> $GITHUB_ENV
@@ -97,9 +97,9 @@ jobs:
9797
continue-on-error: true
9898
- name: Update version and group id
9999
run: |
100-
find . -type f -name "pom.xml" -exec sed -i -e 's|${revision}|${{ github.event.inputs.version }}|g' \
100+
find . -type f -name "pom.xml" -exec sed -i -e 's|${revision}|${{ github.event.inputs.driver }}|g' \
101101
-e 's|^\( <version>\).*\(</version>\)$|\1${{ github.event.inputs.driver }}\2|' \
102-
-e 's|${parent.groupId}|com.clickhouse|g' '{}' \;
102+
-e 's|${parent.groupId}|com.clickhouse|g' -e 's|${project.parent.groupId}|com.clickhouse|g' '{}' \;
103103
find . -type f -name "log4j.*" -exec rm -fv '{}' \;
104104
continue-on-error: true
105105
- name: Install driver as needed

.github/workflows/build.yml

Lines changed: 29 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,11 +32,10 @@ jobs:
3232
runs-on: ubuntu-latest
3333
strategy:
3434
matrix:
35-
java: [8, 11, 17]
3635
# most recent LTS releases as well as latest stable builds
3736
clickhouse: ["21.3", "21.8", "latest"]
3837
fail-fast: false
39-
name: Build using JDK ${{ matrix.java }} against ClickHouse ${{ matrix.clickhouse }}
38+
name: Build against ClickHouse ${{ matrix.clickhouse }}
4039
steps:
4140
- name: Check out Git repository
4241
uses: actions/checkout@v2
@@ -45,10 +44,34 @@ jobs:
4544
git fetch --no-tags --prune --progress --no-recurse-submodules --depth=1 \
4645
origin pull/${{ github.event.inputs.pr }}/merge:merged-pr && git checkout merged-pr
4746
if: github.event.inputs.pr != ''
48-
- name: Set up JDK ${{ matrix.java }}
49-
uses: actions/setup-java@v1
47+
- name: Install JDK 11
48+
uses: AdoptOpenJDK/install-jdk@v1
5049
with:
51-
java-version: ${{ matrix.java }}
50+
version: '11'
51+
targets: 'JDK11_HOME'
52+
- name: Setup Toolchain
53+
shell: bash
54+
run: |
55+
mkdir -p $HOME/.m2 \
56+
&& cat << EOF > $HOME/.m2/toolchains.xml
57+
<?xml version="1.0" encoding="UTF8"?>
58+
<toolchains>
59+
<toolchain>
60+
<type>jdk</type>
61+
<provides>
62+
<version>11</version>
63+
</provides>
64+
<configuration>
65+
<jdkHome>${{ env.JDK11_HOME }}</jdkHome>
66+
</configuration>
67+
</toolchain>
68+
</toolchains>
69+
EOF
70+
- name: Install JDK 8 and Maven
71+
uses: actions/setup-java@v2
72+
with:
73+
distribution: 'temurin'
74+
java-version: 8
5275
# Step that does that actual cache save and restore
5376
- name: Cache maven dependencies
5477
uses: actions/cache@v2
@@ -57,6 +80,6 @@ jobs:
5780
key: ${{ runner.os }}-build-${{ hashFiles('**/pom.xml') }}
5881
restore-keys: |
5982
${{ runner.os }}-build-
60-
- name: Build with Maven
83+
- name: Build
6184
run: |
6285
mvn --batch-mode --update-snapshots -Drelease -DclickhouseVersion=${{ matrix.clickhouse }} verify

.github/workflows/release.yml

Lines changed: 28 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -16,15 +16,39 @@ jobs:
1616
steps:
1717
- name: Check out Git repository
1818
uses: actions/checkout@v2
19-
- name: Install Java and Maven
20-
uses: actions/setup-java@v1
19+
- name: Install JDK 11
20+
uses: AdoptOpenJDK/install-jdk@v1
2121
with:
22+
version: '11'
23+
targets: 'JDK11_HOME'
24+
- name: Setup Toolchain
25+
shell: bash
26+
run: |
27+
mkdir -p $HOME/.m2 \
28+
&& cat << EOF > $HOME/.m2/toolchains.xml
29+
<?xml version="1.0" encoding="UTF8"?>
30+
<toolchains>
31+
<toolchain>
32+
<type>jdk</type>
33+
<provides>
34+
<version>11</version>
35+
</provides>
36+
<configuration>
37+
<jdkHome>${{ env.JDK11_HOME }}</jdkHome>
38+
</configuration>
39+
</toolchain>
40+
</toolchains>
41+
EOF
42+
- name: Install JDK 8 and Maven
43+
uses: actions/setup-java@v2
44+
with:
45+
distribution: 'temurin'
2246
java-version: 8
23-
- name: Update pom files and reduce logs
47+
- name: Update Configuration
2448
run: |
2549
find . -type f -name "pom.xml" -exec sed -i -e 's|${revision}|${{ github.event.inputs.version }}|g' \
2650
-e 's|^\( <version>\).*\(</version>\)$|\1${{ github.event.inputs.version }}\2|' \
27-
-e 's|${parent.groupId}|com.clickhouse|g' '{}' \;
51+
-e 's|${parent.groupId}|com.clickhouse|g' -e 's|${project.parent.groupId}|com.clickhouse|g' '{}' \;
2852
find . -type f -name "log4j.*" -exec rm -fv '{}' \;
2953
- name: Release Maven package
3054
uses: samuelmeuli/action-maven-publish@v1

.github/workflows/third_party_libs.yml

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,19 +19,18 @@ jobs:
1919
- name: Install Java and Maven
2020
uses: actions/setup-java@v1
2121
with:
22-
java-version: 9
22+
java-version: 11
2323
- name: Update pom files and reduce logs
2424
run: |
2525
find . -type f -name "pom.xml" -exec sed -i -e 's|${revision}|${{ github.event.inputs.version }}|g' \
2626
-e 's|^\( <version>\).*\(</version>\)$|\1${{ github.event.inputs.version }}\2|' \
27-
-e 's|${parent.groupId}|com.clickhouse|g' '{}' \;
27+
-e 's|${parent.groupId}|com.clickhouse|g' -e 's|${project.parent.groupId}|com.clickhouse|g' '{}' \;
2828
find . -type f -name "log4j.*" -exec rm -fv '{}' \;
2929
- name: Release Maven package
3030
uses: samuelmeuli/action-maven-publish@v1
3131
with:
32-
directory: third-party-libraries
32+
directory: ./third-party-libraries/
3333
maven_profiles: release
34-
maven_args: -q --batch-mode
3534
gpg_private_key: ${{ secrets.GPG_PRIVATE_KEY }}
3635
gpg_passphrase: ${{ secrets.GPG_PASSPHRASE }}
3736
nexus_username: ${{ secrets.SONATYPE_USER }}

.github/workflows/timezone.yml

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -43,20 +43,27 @@ jobs:
4343
git fetch --no-tags --prune --progress --no-recurse-submodules --depth=1 \
4444
origin pull/${{ github.event.inputs.pr }}/merge:merged-pr && git checkout merged-pr
4545
if: github.event.inputs.pr != ''
46-
- name: Set up JDK 11
46+
- name: Set up JDK 8
4747
uses: actions/setup-java@v1
4848
with:
49-
java-version: 11
49+
java-version: 8
5050
- name: Cache maven dependencies
5151
uses: actions/cache@v2
5252
with:
5353
path: ~/.m2/repository
5454
key: ${{ runner.os }}-build-${{ hashFiles('**/pom.xml') }}
5555
restore-keys: |
5656
${{ runner.os }}-build-
57-
- name: Test using Maven
57+
- name: Install dependencies
5858
run: |
5959
mvn --batch-mode --update-snapshots \
60+
--projects clickhouse-client -DskipTests \
61+
--also-make install
62+
- name: Test JDBC driver
63+
run: |
64+
mvn --batch-mode --update-snapshots \
65+
--projects clickhouse-jdbc \
6066
-DclickhouseTimezone=${{ matrix.serverTz }} \
6167
-DclickhouseVersion=21.8 \
62-
-Duser.timezone=${{ matrix.clientTz }} verify
68+
-Duser.timezone=${{ matrix.clientTz }} \
69+
--also-make clean verify

LICENSE

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
Copyright 2016-2021 Yandex LLC
21

32
Apache License
43
Version 2.0, January 2004
@@ -188,7 +187,7 @@ Copyright 2016-2021 Yandex LLC
188187
same "printed page" as the copyright notice for easier
189188
identification within third-party archives.
190189

191-
Copyright 2016-2021 Yandex LLC
190+
Copyright [yyyy] [name of copyright owner]
192191

193192
Licensed under the Apache License, Version 2.0 (the "License");
194193
you may not use this file except in compliance with the License.

0 commit comments

Comments
 (0)