Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/datafuselabs/databend into โ€ฆ
Browse files Browse the repository at this point in the history
โ€ฆfix-agg-index
  • Loading branch information
RinChanNOWWW committed Oct 11, 2023
2 parents 13db9bc + 7e796c0 commit 7083c76
Show file tree
Hide file tree
Showing 158 changed files with 3,978 additions and 2,985 deletions.
9 changes: 2 additions & 7 deletions .github/workflows/bindings.python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,8 @@ on:
pull_request:
branches:
- main
paths-ignore:
- "docs/**"
- "website/**"
- "**.md"
- "docker/**"
- "scripts/setup/**"
- ".devcontainer/**"
paths:
- "src/**"
workflow_call:
inputs:
tag:
Expand Down
67 changes: 58 additions & 9 deletions .github/workflows/dev.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,32 +8,81 @@ on:
- reopened
branches:
- main
paths-ignore:
- "docs/**"
- "website/**"
- "**.md"
- "docker/**"
- "scripts/setup/**"
- ".devcontainer/**"
merge_group:
types:
- checks_requested

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}-${{ github.event_name }}
cancel-in-progress: true

jobs:
changes:
runs-on: ubuntu-latest
outputs:
any_src_changed: ${{ steps.src.outputs.any_changed }}
steps:
- uses: actions/checkout@v4
- name: Check Source File Changes
uses: tj-actions/changed-files@v39
id: src
with:
files_ignore: |
.github/**
docs/**
website/**
**.md
docker/**
scripts/setup/**
.devcontainer/**
- name: Output Source File Changes
run: |
if [[ "${{ steps.src.outputs.any_changed }}" == "true" ]]; then
echo "these src files changed:" >> $GITHUB_STEP_SUMMARY
for line in ${{ steps.src.outputs.all_changed_files }}; do
echo "- $line" >> $GITHUB_STEP_SUMMARY
done
else
echo "no src file changes detected" >> $GITHUB_STEP_SUMMARY
fi
linux:
needs: changes
if: needs.changes.outputs.any_src_changed == 'true'
uses: ./.github/workflows/reuse.linux.yml
secrets: inherit
with:
build_profile: debug
runner_provider: gcp

linux_hive:
needs: changes
if: needs.changes.outputs.any_src_changed == 'true'
uses: ./.github/workflows/reuse.linux.hive.yml
secrets: inherit
with:
build_profile: debug
runner_provider: gcp

ready:
if: always()
runs-on: ubuntu-latest
needs:
- changes
- linux
- linux_hive
steps:
- name: Check Ready to Merge
uses: actions/github-script@v6
env:
SRC_CHANGED: ${{ needs.changes.outputs.any_src_changed }}
LINUX_BUILD_RESULT: ${{ needs.linux.result }}
with:
script: |
if (process.env.SRC_CHANGED == 'false') {
core.info('No source file changes detected, skipping');
return;
}
if (process.env.LINUX_BUILD_RESULT == 'success') {
core.info('Linux build succeeded, ready to merge');
return;
}
core.setFailed('Build failed, not ready to merge');
32 changes: 24 additions & 8 deletions .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ on:
- edited
- ready_for_review
- converted_to_draft
merge_group:

permissions:
pull-requests: write
Expand All @@ -17,17 +18,23 @@ permissions:
jobs:
title:
runs-on: ubuntu-latest
if: '!github.event.pull_request.draft'
steps:
- name: Check PR title if not sematic
uses: actions/github-script@v6
id: check
with:
script: |
if (!context.payload.pull_request) {
core.info('PR payload is null');
core.setOutput('title', 'ignore');
return;
}
const title = context.payload.pull_request.title;
const regex = /^(rfc|feat|fix|refactor|ci|docs|chore)(\([a-z0-9-]+\))?:/;
const m = title.match(regex);
if (!m) {
core.setFailed('PR title is not semantic');
core.error('PR title is not semantic');
core.setOutput('title', 'not-semantic');
return;
}
const prType = m[1];
Expand Down Expand Up @@ -63,15 +70,16 @@ jobs:
issue_number: context.issue.number,
labels: [label],
});
core.setOutput('title', 'semantic');
- name: Delete Comment
if: success()
if: steps.check.outputs.title == 'semantic'
uses: everpcpc/comment-on-pr-action@v1
with:
token: ${{ github.token }}
identifier: 'pr-assistant-title'
delete: true
- name: Comment on PR
if: failure()
if: steps.check.outputs.title == 'not-semantic'
uses: everpcpc/comment-on-pr-action@v1
with:
token: ${{ github.token }}
Expand Down Expand Up @@ -102,26 +110,34 @@ jobs:
cla:
runs-on: ubuntu-latest
if: '!github.event.pull_request.draft'
steps:
- name: Check CLA if not signed
uses: actions/github-script@v6
id: check
with:
script: |
if (!context.payload.pull_request) {
core.info('PR payload is null');
core.setOutput('cla', 'ignore');
return;
}
const body = context.payload.pull_request.body;
const regex = /I hereby agree to the terms of the CLA available at: https:\/\/databend\.rs\/dev\/policies\/cla\//;
if (!regex.test(body)) {
core.setFailed('CLA is not signed');
core.error('CLA is not signed');
core.setOutput('cla', 'not-signed');
} else {
core.setOutput('cla', 'signed');
}
- name: Delete Comment
if: success()
if: steps.check.outputs.cla == 'signed'
uses: everpcpc/comment-on-pr-action@v1
with:
token: ${{ github.token }}
identifier: 'pr-assistant-cla'
delete: true
- name: Comment on PR
if: failure()
if: steps.check.outputs.cla == 'not-signed'
uses: everpcpc/comment-on-pr-action@v1
with:
token: ${{ github.token }}
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@ on:
tags:
- "v*"
schedule:
# Release at 00:00 UTC+8
- cron: "0 16 * * *"
- cron: "0 22 * * *"
workflow_dispatch:
inputs:
tags:
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/reuse.linux.yml
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,6 @@ jobs:
- "standalone"
- "crdb"
- "duckdb"
- "tpch"
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/test_sqllogic_standalone_linux
Expand Down Expand Up @@ -222,6 +221,7 @@ jobs:
- "base"
- "ydb"
- "tpcds"
- "tpch"
format:
- "parquet"
- "native"
Expand Down Expand Up @@ -280,10 +280,8 @@ jobs:
dirs:
- "base"
- "query"
- "cluster"
- "crdb"
- "duckdb"
- "tpch"
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/test_sqllogic_cluster_linux
Expand All @@ -299,13 +297,15 @@ jobs:

sqllogic_cluster_large:
name: sqllogic_cluster_${{ matrix.dirs }}
runs-on: [self-hosted, X64, Linux, 4c8g, "${{ inputs.runner_provider }}"]
runs-on: [self-hosted, X64, Linux, 8c16g, "${{ inputs.runner_provider }}"]
needs: [build, check]
strategy:
matrix:
dirs:
- "ydb"
- "tpcds"
# - "tpch"
- "cluster"
steps:
- uses: actions/checkout@v4
- uses: ./.github/actions/test_sqllogic_cluster_linux
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ docker run --net=host datafuselabs/databend
- [Connecting to Databend with BendSQL](https://databend.rs/doc/sql-clients/bendsql)
- [Connecting to Databend with JDBC](https://databend.rs/doc/sql-clients/jdbc)
- [Connecting to Databend with MySQL-Compatible Clients](https://databend.rs/doc/sql-clients/mysql)

</details>

<details>
Expand All @@ -129,7 +129,7 @@ docker run --net=host datafuselabs/databend
- [Querying Data in Staged Files](https://databend.rs/doc/load-data/transform/querying-stage)
- [Transforming Data During a Load](https://databend.rs/doc/load-data/transform/data-load-transform)
- [How to Unload Data from Databend](https://databend.rs/doc/load-data/unload)

</details>

<details>
Expand Down Expand Up @@ -223,7 +223,7 @@ docker run --net=host datafuselabs/databend

- [How to Create Data Masking Policy](https://databend.rs/doc/sql-commands/ddl/mask-policy/create-mask-policy)
- [How to Drop Data Masking Policy](https://databend.rs/doc/sql-commands/ddl/mask-policy/drop-mask-policy)

</details>

<details>
Expand Down Expand Up @@ -274,7 +274,7 @@ For general help in using Databend, please refer to the official documentation.

## License

Databend is released under a combination of two licenses: the [Apache License 2.0](licenses/Apache-2.0.txt) and the [Elastic License 2.0](licenses/Elastic.txt).
Databend is released under a combination of two licenses: the [Apache License 2.0](licenses/Apache-2.0.txt) and the [Elastic License 2.0](licenses/Elastic.txt).

When contributing to Databend, you can find the relevant license header in each file.

Expand Down
Loading

0 comments on commit 7083c76

Please sign in to comment.