Skip to content

[FEATURE]: Add clickhouse SSL\TLS connection #726

[FEATURE]: Add clickhouse SSL\TLS connection

[FEATURE]: Add clickhouse SSL\TLS connection #726

Workflow file for this run

name: benchmark
on:
push:
branches:
- "master"
pull_request:
branches:
- "master"
jobs:
build:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- name: Set up JDK
uses: actions/setup-java@v1
with:
java-version: 8
- run: sed -i 's/TRACE/INFO/g' clickhouse-native-jdbc/src/test/resources/simplelogger.properties
- run: sed -i 's/DEBUG/INFO/g' clickhouse-native-jdbc/src/test/resources/simplelogger.properties
- name: Install libasyncProfiler (remove this once async-profiler available on maven-central)
run: |
wget -O /tmp/async-profiler-1.8.3-linux-x64.tar.gz \
https://github.com/jvm-profiling-tools/async-profiler/releases/download/v1.8.3/async-profiler-1.8.3-linux-x64.tar.gz
tar -C /tmp -xzf /tmp/async-profiler-1.8.3-linux-x64.tar.gz
- name: Run benchmarks
env:
NETTY_RESOURCE_LEAK_DETECT_LEVEL: DISABLED
run: |
mvn -B -Pbenchmark clean integration-test -DskipITs -pl :clickhouse-native-jdbc -am | tee output.log
echo "BENCHMARK_REPORT<<EOF" >> $GITHUB_ENV
echo "`cat output.log | grep -E '^Benchmark\s.*\sUnits$' -A 300 | grep -E '.*\s(Units|ms/op)$'`" >> $GITHUB_ENV
echo "EOF" >> $GITHUB_ENV
- run: tar -czf benchmark-reports.tgz -C clickhouse-native-jdbc reports
- name: Upload reports
uses: actions/upload-artifact@v2
with:
name: benchmark-reports
path: benchmark-reports.tgz
retention-days: 30
- name: Comment PR
if: github.event_name == 'pull_request'
uses: actions/github-script@v6
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const issue_number = context.issue.number;
const owner = context.repo.owner;
const repo = context.repo.repo;
const contentWithLineNumbers = `${process.env.BENCHMARK_REPORT}`
.split('\n')
.map((line, idx) => `${idx + 1}. ${line}`)
.join('\n');
const body = `
<details>
<summary>BENCHMARK_REPORT</summary>
<pre style="display:block; white-space:pre-wrap; background-color: #f5f5f5; padding: 10px; border: 1px solid #ccc; border-radius: 4px; font-family: monospace;">
${contentWithLineNumbers}
</pre>
</details>
`;
github.rest.issues.createComment({
issue_number,
owner,
repo,
body
});