├── collector
├── .gitkeep
├── hits
│ └── .gitkeep
├── numbers
│ ├── .gitkeep
│ ├── 2023-12-27-numbers.json
│ ├── 2023-03-13-numbers.json
│ ├── 2024-03-04-numbers.json
│ ├── 2023-01-11-numbers.json
│ ├── 2023-03-06-numbers.json
│ ├── 2023-11-01-numbers.json
│ ├── 2024-02-07-numbers.json
│ ├── 2024-02-12-numbers.json
│ ├── 2024-04-29-numbers.json
│ ├── 2022-11-18-numbers.json
│ ├── 2022-12-03-numbers.json
│ ├── 2022-12-14-numbers.json
│ ├── 2023-02-22-numbers.json
│ ├── 2023-03-27-numbers.json
│ ├── 2023-04-12-numbers.json
│ ├── 2023-04-24-numbers.json
│ ├── 2023-04-26-numbers.json
│ ├── 2024-02-14-numbers.json
│ ├── 2024-02-19-numbers.json
│ ├── 2024-04-08-numbers.json
│ ├── 2024-05-22-numbers.json
│ ├── 2024-05-27-numbers.json
│ ├── 2024-07-22-numbers.json
│ ├── 2022-11-26-numbers.json
│ ├── 2023-01-09-numbers.json
│ ├── 2023-11-20-numbers.json
│ ├── 2023-11-29-numbers.json
│ ├── 2023-12-04-numbers.json
│ ├── 2023-12-20-numbers.json
│ ├── 2024-01-01-numbers.json
│ ├── 2024-01-10-numbers.json
│ ├── 2024-02-05-numbers.json
│ ├── 2024-02-21-numbers.json
│ ├── 2024-03-20-numbers.json
│ ├── 2024-04-17-numbers.json
│ ├── 2024-04-24-numbers.json
│ ├── 2024-05-15-numbers.json
│ ├── 2024-05-20-numbers.json
│ ├── 2024-05-29-numbers.json
│ ├── 2024-06-03-numbers.json
│ ├── 2024-06-05-numbers.json
│ ├── 2024-06-10-numbers.json
│ ├── 2024-06-19-numbers.json
│ ├── 2024-06-24-numbers.json
│ ├── 2024-07-08-numbers.json
│ ├── 2024-07-17-numbers.json
│ ├── 2024-07-24-numbers.json
│ ├── 2022-11-17-numbers.json
│ ├── 2022-12-11-numbers.json
│ ├── 2022-12-18-numbers.json
│ ├── 2023-10-23-numbers.json
│ ├── 2023-10-30-numbers.json
│ ├── 2023-11-27-numbers.json
│ ├── 2024-03-27-numbers.json
│ ├── 2024-04-22-numbers.json
│ ├── 2024-06-12-numbers.json
│ ├── 2024-06-17-numbers.json
│ ├── 2024-06-26-numbers.json
│ ├── 2024-07-01-numbers.json
│ ├── 2024-07-10-numbers.json
│ ├── 2022-07-20-numbers.json
│ ├── 2022-12-22-numbers.json
│ ├── 2023-01-16-numbers.json
│ ├── 2023-01-18-numbers.json
│ ├── 2023-01-25-numbers.json
│ ├── 2023-02-20-numbers.json
│ ├── 2023-07-31-numbers.json
│ ├── 2023-12-18-numbers.json
│ ├── 2024-03-25-numbers.json
│ ├── 2024-04-10-numbers.json
│ ├── 2024-05-01-numbers.json
│ ├── 2024-07-03-numbers.json
│ ├── 2024-07-15-numbers.json
│ ├── 2022-11-14-numbers.json
│ ├── 2022-11-24-numbers.json
│ ├── 2022-12-02-numbers.json
│ ├── 2022-12-07-numbers.json
│ ├── 2022-12-13-numbers.json
│ ├── 2022-12-28-numbers.json
│ ├── 2023-04-10-numbers.json
│ ├── 2023-04-17-numbers.json
│ ├── 2023-07-05-numbers.json
│ ├── 2023-07-17-numbers.json
│ ├── 2023-07-26-numbers.json
│ ├── 2023-08-07-numbers.json
│ ├── 2023-09-04-numbers.json
│ ├── 2023-09-13-numbers.json
│ ├── 2023-09-18-numbers.json
│ ├── 2023-10-04-numbers.json
│ ├── 2023-12-11-numbers.json
│ ├── 2024-01-08-numbers.json
│ ├── 2024-05-06-numbers.json
│ ├── 2024-05-13-numbers.json
│ ├── 2022-07-08-numbers.json
│ ├── 2022-07-10-numbers.json
│ ├── 2022-07-15-numbers.json
│ ├── 2022-07-21-numbers.json
│ ├── 2022-08-18-numbers.json
│ ├── 2022-09-15-numbers.json
│ ├── 2022-10-16-numbers.json
│ ├── 2022-10-25-numbers.json
│ ├── 2022-11-11-numbers.json
│ ├── 2022-12-01-numbers.json
│ ├── 2022-12-19-numbers.json
│ ├── 2023-01-23-numbers.json
│ ├── 2023-02-13-numbers.json
│ ├── 2023-03-20-numbers.json
│ ├── 2023-03-29-numbers.json
│ ├── 2023-08-28-numbers.json
│ ├── 2023-08-30-numbers.json
│ ├── 2023-09-11-numbers.json
│ ├── 2023-10-03-numbers.json
│ ├── 2023-10-09-numbers.json
│ ├── 2022-07-22-numbers.json
│ ├── 2022-07-27-numbers.json
│ ├── 2022-08-03-numbers.json
│ ├── 2022-08-04-numbers.json
│ ├── 2022-08-29-numbers.json
│ ├── 2022-08-31-numbers.json
│ ├── 2022-09-19-numbers.json
│ └── 2022-09-20-numbers.json
├── ontime
│ └── .gitkeep
├── hits-reload
│ └── .gitkeep
└── ontime-reload
│ └── .gitkeep
├── reload
├── .gitkeep
└── tpch
│ ├── region.sh
│ ├── nation.sh
│ ├── partsupp.sh
│ ├── supplier.sh
│ ├── customer.sh
│ ├── part.sh
│ ├── orders.sh
│ └── lineitem.sh
├── benchmarks
├── .gitkeep
└── numbers.yaml
├── front
├── src
│ ├── pages
│ │ └── css
│ │ │ ├── share.module.scss
│ │ │ ├── styles.module.scss
│ │ │ └── compare.module.scss
│ ├── vite-env.d.ts
│ ├── assets
│ │ ├── CONSTANT_VAR.ts
│ │ ├── graph
│ │ │ └── fork-me.png
│ │ └── icon
│ │ │ ├── icon.ts
│ │ │ └── link.tsx
│ ├── componnent
│ │ ├── ShareButton
│ │ │ ├── index.module.scss
│ │ │ └── index.tsx
│ │ ├── Fallback
│ │ │ └── index.tsx
│ │ └── Layout
│ │ │ ├── index.module.scss
│ │ │ └── footer.module.scss
│ ├── main.tsx
│ ├── index.css
│ ├── App.tsx
│ ├── api
│ │ └── index.ts
│ ├── utils
│ │ └── device-type.ts
│ ├── App.scss
│ ├── service
│ │ └── index.ts
│ └── router
│ │ └── index.tsx
├── .env.production
├── .env
├── README.md
├── tsconfig.node.json
├── .gitignore
├── tsconfig.json
├── index.html
├── package.json
└── vite.config.ts
├── .gitignore
├── .github
├── actions
│ └── setup-bendsql
│ │ └── action.yaml
└── workflows
│ ├── reload.hits.yaml
│ └── reuse.reload.yaml
├── README.md
└── go.mod
/collector/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/reload/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/benchmarks/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/collector/hits/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/collector/numbers/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/collector/ontime/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/collector/hits-reload/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/collector/ontime-reload/.gitkeep:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/front/src/pages/css/share.module.scss:
--------------------------------------------------------------------------------
1 |
--------------------------------------------------------------------------------
/front/.env.production:
--------------------------------------------------------------------------------
1 | VITE_APP_BASEN_URL=/json
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # ignore the perf tool
2 | script/perf-tool
--------------------------------------------------------------------------------
/front/src/vite-env.d.ts:
--------------------------------------------------------------------------------
1 | ///
2 |
--------------------------------------------------------------------------------
/front/.env:
--------------------------------------------------------------------------------
1 | VITE_APP_BASEN_URL=https://datafuselabs.github.io/databend-perf/json
--------------------------------------------------------------------------------
/front/README.md:
--------------------------------------------------------------------------------
1 | # develop
2 | yarn
3 | yarn dev
4 |
5 | # deploy
6 | yarn run build
--------------------------------------------------------------------------------
/front/src/assets/CONSTANT_VAR.ts:
--------------------------------------------------------------------------------
1 | export const ICON_LINSK = '//at.alicdn.com/t/font_2976183_ycvsowfaqti.js'; // alibaba iconfont
--------------------------------------------------------------------------------
/front/src/assets/graph/fork-me.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/databendlabs/databend-perf/HEAD/front/src/assets/graph/fork-me.png
--------------------------------------------------------------------------------
/front/tsconfig.node.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "composite": true,
4 | "module": "esnext",
5 | "moduleResolution": "node"
6 | },
7 | "include": ["vite.config.ts"]
8 | }
9 |
--------------------------------------------------------------------------------
/front/src/componnent/ShareButton/index.module.scss:
--------------------------------------------------------------------------------
1 | .share{
2 | position: absolute;
3 | right: -1px;
4 | top: -1px;
5 | border-bottom-left-radius: 50%;
6 | .icon {
7 | font-size: 20px;
8 | }
9 | }
--------------------------------------------------------------------------------
/front/src/assets/icon/icon.ts:
--------------------------------------------------------------------------------
1 | import { createFromIconfontCN } from '@ant-design/icons';
2 | import { ICON_LINSK } from '../CONSTANT_VAR';
3 | const IconFont = createFromIconfontCN({
4 | scriptUrl: ICON_LINSK
5 | });
6 | export default IconFont;
7 |
--------------------------------------------------------------------------------
/front/src/main.tsx:
--------------------------------------------------------------------------------
1 | import React from 'react'
2 | import ReactDOM from 'react-dom'
3 | import './index.css'
4 | import App from './App'
5 |
6 | ReactDOM.render(
7 |
8 |
9 | ,
10 | document.getElementById('root')
11 | )
12 |
--------------------------------------------------------------------------------
/front/src/assets/icon/link.tsx:
--------------------------------------------------------------------------------
1 | const LinkIcon = ()=>{
2 | return
3 | }
4 | export default LinkIcon;
--------------------------------------------------------------------------------
/front/src/pages/css/styles.module.scss:
--------------------------------------------------------------------------------
1 | .allChartWrap{
2 | .content{
3 | position: relative;
4 | border: 1px solid #d9d9d9;
5 | height: 100%;
6 | padding-bottom: 20px;
7 | padding-right: 10px;
8 | border-radius: 6px;
9 | .title{
10 | padding-left: 20px;
11 | padding-top: 20px;
12 | padding-right: 50px;
13 | }
14 | }
15 | }
--------------------------------------------------------------------------------
/front/.gitignore:
--------------------------------------------------------------------------------
1 | # Logs
2 | logs
3 | *.log
4 | npm-debug.log*
5 | yarn-debug.log*
6 | yarn-error.log*
7 | pnpm-debug.log*
8 | lerna-debug.log*
9 |
10 | node_modules
11 | dist
12 | dist-ssr
13 | *.local
14 |
15 | # Editor directories and files
16 | .vscode/*
17 | !.vscode/extensions.json
18 | .idea
19 | .DS_Store
20 | *.suo
21 | *.ntvs*
22 | *.njsproj
23 | *.sln
24 | *.sw?
25 |
--------------------------------------------------------------------------------
/front/src/index.css:
--------------------------------------------------------------------------------
1 | body {
2 | margin: 0;
3 | font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen',
4 | 'Ubuntu', 'Cantarell', 'Fira Sans', 'Droid Sans', 'Helvetica Neue',
5 | sans-serif;
6 | -webkit-font-smoothing: antialiased;
7 | -moz-osx-font-smoothing: grayscale;
8 | }
9 |
10 | code {
11 | font-family: source-code-pro, Menlo, Monaco, Consolas, 'Courier New',
12 | monospace;
13 | }
14 |
--------------------------------------------------------------------------------
/front/src/componnent/Fallback/index.tsx:
--------------------------------------------------------------------------------
1 | import { FC, ReactElement } from 'react';
2 | import LogoLightVertical from '../../assets/logo/logo-light-vertical';
3 | const Fallback: FC = (): ReactElement=> {
4 | return (
5 |
6 |
7 | ...
8 |
9 | );
10 | };
11 | export default Fallback;
--------------------------------------------------------------------------------
/front/src/App.tsx:
--------------------------------------------------------------------------------
1 | import { Suspense } from 'react'
2 | import { HashRouter as Router } from 'react-router-dom'
3 | import 'antd/dist/antd.min.css'
4 | import { AppRouters } from './router';
5 | import './assets/fonts/fonts.css';
6 | import './App.scss';
7 | import Fallback from './componnent/Fallback';
8 |
9 | function App() {
10 | return (
11 |
12 | }>
13 |
14 |
15 |
16 | )
17 | }
18 | export default App
19 |
--------------------------------------------------------------------------------
/front/src/api/index.ts:
--------------------------------------------------------------------------------
1 | import service from "../service";
2 |
3 | export function getCategories(): Promise {
4 | return service.get('/index.json');
5 | }
6 | export function getApiListByCategory(category: string): Promise {
7 | return service.get(`${category}/${category}.json`);
8 | }
9 | export function getGraph(category: string, which: string): Promise {
10 | return service.get(`${category}/${which}`);
11 | }
12 | export function getLatestByCategory(category:string): Promise {
13 | return service.get(`${category}/latest.json`);
14 | }
--------------------------------------------------------------------------------
/.github/actions/setup-bendsql/action.yaml:
--------------------------------------------------------------------------------
1 | name: Setup BendSQL
2 | description: setup bendsql for perf test
3 |
4 | runs:
5 | using: composite
6 | steps:
7 | - name: Get BendSQL from release
8 | shell: bash
9 | run: |
10 | sudo curl -L -o /usr/share/keyrings/datafuselabs-keyring.gpg https://repo.databend.rs/deb/datafuselabs.gpg
11 | sudo curl -L -o /etc/apt/sources.list.d/datafuselabs.list https://repo.databend.rs/deb/datafuselabs.list
12 | sudo apt update
13 | sudo apt install -y bendsql
14 | bendsql --version
15 |
--------------------------------------------------------------------------------
/.github/workflows/reload.hits.yaml:
--------------------------------------------------------------------------------
1 | name: Reload hits
2 |
3 | on:
4 | pull_request:
5 | branches:
6 | - main
7 | paths:
8 | - "reload/hits.sh"
9 | push:
10 | branches:
11 | - main
12 | paths:
13 | - "reload/hits.sh"
14 | schedule:
15 | # Runs at 08:25 UTC on Wed.
16 | - cron: '25 8 * * 3'
17 | workflow_dispatch: {}
18 |
19 | concurrency:
20 | group: "reload"
21 |
22 | jobs:
23 | reload-hits:
24 | uses: ./.github/workflows/reuse.reload.yaml
25 | secrets: inherit
26 | with:
27 | script: ./reload/hits.sh
28 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # Databend Performance Monitoring & Benchmarking
2 |
3 | This repository contains these primary dirs:
4 |
5 | - [`collector`](./collector): stores performance data (benchmark & reload) for nightly release.
6 | - [`benchmarks`](./benchmarks): contains the benchmark suite defined by the yaml format.
7 | - [`reload`](./reload): contains the reload suite defined by the yaml format.
8 |
9 |
10 | perf.databend.rs is deprecated. We moved them to: [hits perf](https://benchmark.databend.com/clickbench/release/hits.html) and [TPCH-1000 perf](https://benchmark.databend.com/clickbench/release/tpch1000.html)
11 |
12 |
--------------------------------------------------------------------------------
/front/src/utils/device-type.ts:
--------------------------------------------------------------------------------
1 | interface DeviceType {
2 | type: 'mobile' | 'pc';
3 | isPhone: boolean;
4 | }
5 | function isMoible(UA: string) {
6 | return !!/(Android|webOS|iPhone|iPod|tablet|BlackBerry|Mobile)/i.test(UA);
7 | }
8 |
9 | export function deviceType(): DeviceType {
10 | let type: DeviceType["type"] = 'pc';
11 | let detaultDeviceType: DeviceType = { type, isPhone: false }
12 | const UA = navigator.userAgent??'';
13 | if (isMoible(UA)) {
14 | type = 'mobile';
15 | return {
16 | type, isPhone: true
17 | };
18 | } else {
19 | return detaultDeviceType;
20 | }
21 | }
22 |
--------------------------------------------------------------------------------
/front/tsconfig.json:
--------------------------------------------------------------------------------
1 | {
2 | "compilerOptions": {
3 | "target": "ESNext",
4 | "useDefineForClassFields": true,
5 | "lib": ["DOM", "DOM.Iterable", "ESNext"],
6 | "allowJs": false,
7 | "skipLibCheck": true,
8 | "esModuleInterop": false,
9 | "allowSyntheticDefaultImports": true,
10 | "strict": true,
11 | "forceConsistentCasingInFileNames": true,
12 | "module": "ESNext",
13 | "moduleResolution": "Node",
14 | "resolveJsonModule": true,
15 | "isolatedModules": true,
16 | "noEmit": true,
17 | "jsx": "react-jsx"
18 | },
19 | "include": ["src"],
20 | "references": [{ "path": "./tsconfig.node.json" }]
21 | }
22 |
--------------------------------------------------------------------------------
/front/src/App.scss:
--------------------------------------------------------------------------------
1 | body {
2 | @include pm;
3 | font-family: 'Roboto', sans-serif;
4 | }
5 | #databend-collapse {
6 | path {
7 | fill: currentColor;
8 | }
9 | }
10 | .ant-menu-item-selected{
11 | background-color: unset!important;
12 | }
13 | .ant-menu-item-selected {
14 | a{
15 | color: #2775f6!important;
16 | &.out-link{
17 | color: #fff!important;
18 | }
19 | }
20 |
21 | }
22 | .ant-menu-horizontal>.ant-menu-item:hover{
23 | background-color: unset!important;
24 | }
25 | .ant-picker-panels{
26 | @include media{
27 | display: flex;
28 | flex-direction: column;
29 | }
30 | }
31 | .ant-table-wrapper{
32 | @include media{
33 | overflow-x: auto;
34 | }
35 | }
--------------------------------------------------------------------------------
/front/src/pages/css/compare.module.scss:
--------------------------------------------------------------------------------
1 | .compareTitle {
2 | text-align: center;
3 | margin-bottom: 20px;
4 | font-weight: bold;
5 | line-height: 30px;
6 | font-size: 12px;
7 | display: flex;
8 | justify-content: center;
9 | .commonli{
10 | color: green;
11 | margin-right: 20px;
12 | i{
13 | display: inline-block;
14 | width: 8px;
15 | height: 8px;
16 | border-radius: 50%;
17 | background-color: green;
18 | margin-right: 5px;
19 | }
20 | &.degradation{
21 | color: red;
22 | i{
23 | background-color: red;
24 | }
25 | }
26 | }
27 | @include media{
28 | text-align: left;
29 | flex-direction: column;
30 | }
31 | }
--------------------------------------------------------------------------------
/reload/tpch/region.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -e
4 |
5 | cat <
2 |
3 |
4 |
5 |
6 |
7 | Databend performance data
8 |
9 |
10 |
11 |
12 |
15 |
16 |
17 |
--------------------------------------------------------------------------------
/reload/tpch/supplier.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -e
4 |
5 | cat < {
13 | if (response.status && response.status === 200) {
14 | return Promise.resolve(response.data);
15 | } else {
16 | return Promise.reject(response.data);
17 | }
18 | },
19 | // error
20 | (error: any) => {
21 | if (error === undefined || error.code === 'ECONNABORTED') {
22 | message.warning('timeout');
23 | return Promise.reject(error);
24 | }
25 | }
26 | );
27 |
28 | // axios instance
29 | axiosInstance.interceptors.request.use(
30 | (config: AxiosRequestConfig) => {
31 | // Request to intercept
32 | return config;
33 | },
34 | (error: any) => {
35 | return Promise.reject(error);
36 | }
37 | );
38 |
39 | export default axiosInstance;
--------------------------------------------------------------------------------
/benchmarks/numbers.yaml:
--------------------------------------------------------------------------------
1 | metadata:
2 | table: numbers
3 |
4 | statements:
5 | - name: Q1
6 | query: "SELECT avg(number) FROM numbers_mt(10000000000);"
7 | - name: Q2
8 | query: "SELECT sum(number) FROM numbers_mt(10000000000);"
9 | - name: Q3
10 | query: "SELECT min(number) FROM numbers_mt(10000000000);"
11 | - name: Q4
12 | query: "SELECT max(number) FROM numbers_mt(10000000000);"
13 | - name: Q5
14 | query: "SELECT count(number) FROM numbers_mt(10000000000);"
15 | # TODO(flaneur2020): recover this after numbers cluster issue get resolved
16 | #- name: Q6
17 | # query: "SELECT sum(number+number+number) FROM numbers_mt(10000000000);"
18 | #- name: Q7
19 | # query: "SELECT sum(number) / count(number) FROM numbers_mt(10000000000);"
20 | #- name: Q8
21 | # query: "SELECT sum(number) / count(number), max(number), min(number) FROM numbers_mt(10000000000);"
22 | # - name: Q9
23 | # query: "SELECT number FROM numbers_mt(10000000000) ORDER BY number DESC LIMIT 10;"
24 | #- name: Q10
25 | # query: "SELECT max(number), sum(number) FROM numbers_mt(10000000000) GROUP BY number % 3, number % 4, number % 5 LIMIT 10;"
26 |
--------------------------------------------------------------------------------
/front/src/router/index.tsx:
--------------------------------------------------------------------------------
1 |
2 | import { lazy } from "react";
3 | import { useRoutes } from "react-router-dom";
4 | import PerfLayout from "../componnent/Layout";
5 | const Graphs = lazy(()=> import('../pages/graphs'));
6 | const Compare = lazy(()=> import('../pages/compare'));
7 | const Status = lazy(()=> import('../pages/status'));
8 | const Share = lazy(()=> import('../pages/share'));
9 | interface IRouteObject {
10 | children?: IRouteObject[];
11 | element?: React.ReactNode;
12 | index?: boolean;
13 | path?: string;
14 | to?: string;
15 | label?: string;
16 | isShow?: boolean;
17 | icon?: React.ReactNode;
18 | }
19 | export const allRouter: IRouteObject[] = [
20 | {
21 | path: '/',
22 | element: ,
23 | children: [
24 | {
25 | path: '',
26 | element:
27 | },
28 | {
29 | path: 'compare',
30 | element:
31 | }
32 | ,
33 | {
34 | path: 'status',
35 | element:
36 | },
37 | {
38 | path: 'share',
39 | element:
40 | }
41 | ]
42 | },
43 | ]
44 |
45 | export const AppRouters = () => useRoutes(allRouter);
--------------------------------------------------------------------------------
/front/src/componnent/ShareButton/index.tsx:
--------------------------------------------------------------------------------
1 | // Copyright 2022 Databend Labs.
2 | import { Button, notification } from 'antd';
3 | import { FC, ReactElement } from 'react';
4 | import IconFont from '../../assets/icon/icon';
5 | import { copyToClipboard } from '../../utils/tools';
6 | import styles from './index.module.scss';
7 | interface IProps {
8 | category: string;
9 | graph: string;
10 | type?: string;
11 | title?: string;
12 | }
13 | const ShareButton: FC = ({category, graph, type, title}): ReactElement=> {
14 | // @ts-ignore
15 | const share = ()=>{
16 | copyToClipboard(`${window.location.origin}/#/share?category=${category}&graph=${graph}&type=${type}&title=${title}`);
17 | notification.open({
18 | message: 'Tips',
19 | duration: 1.5,
20 | placement: 'topLeft',
21 | description:
22 | 'The share link is already in the clipboard'
23 | });
24 | }
25 | return (
26 |
29 | );
30 | };
31 | ShareButton.defaultProps = {
32 | type: 'line',
33 | title: '',
34 | }
35 | export default ShareButton;
--------------------------------------------------------------------------------
/reload/tpch/lineitem.sh:
--------------------------------------------------------------------------------
1 | #!/bin/bash
2 |
3 | set -e
4 |
5 | cat <