diff --git a/.github/workflows/dev.yml b/.github/workflows/dev.yml index c90948941..b71c5d984 100644 --- a/.github/workflows/dev.yml +++ b/.github/workflows/dev.yml @@ -69,6 +69,5 @@ jobs: '{ballista,docs}/**/*.md' \ '!ballista/CHANGELOG.md' \ README.md \ - CONTRIBUTING.md \ - 'ballista/**/*.{ts,tsx}' + CONTRIBUTING.md git diff --exit-code diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 454235617..db1b7fc92 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -72,44 +72,6 @@ jobs: /github/home/target/release/ballista-scheduler /github/home/target/release/ballista-executor - react-build: - name: React build - runs-on: ubuntu-latest # proprietary github image, not ubuntu:latest - container: - image: ubuntu:latest # actual ubuntu:latest that ubuntu publishes - env: - DEBIAN_FRONTEND: "noninteractive" - steps: - - uses: actions/checkout@v3 - - name: Install dependencies - run: | - cat /etc/*-release - apt-get -qq update - apt-get -qq upgrade - apt-get -qq install -y curl - curl -fsSL https://deb.nodesource.com/setup_18.x | bash - apt-get -qq update - apt-get -qq install -y nodejs - npm install -g yarn - which node - which npm - which yarn - node --version - npm --version - yarn --version - - name: Run yarn build - run: | - cd ballista/scheduler/ui - pwd - yarn install - yarn build - - name: Save artifacts - uses: actions/upload-artifact@v4 - with: - name: react-artifacts - path: | - ballista/scheduler/ui/build - # test the crate linux-test: name: Test Workspace on AMD64 Rust ${{ matrix.rust }} @@ -338,7 +300,7 @@ jobs: docker: name: Docker - needs: [linux-build-lib, react-build] + needs: [linux-build-lib] runs-on: ubuntu-latest permissions: contents: read @@ -350,11 +312,6 @@ jobs: with: name: rust-artifacts path: target/release - - name: Restore react artifacts - uses: actions/download-artifact@v4 - with: - name: react-artifacts - path: ballista/scheduler/ui/build - name: Build and push Docker image run: | echo "github user is $DOCKER_USER" @@ -468,7 +425,6 @@ jobs: env: CARGO_HOME: "/github/home/.cargo" CARGO_TARGET_DIR: "/github/home/target" - # Coverage job was failing. https://github.com/apache/arrow-datafusion/issues/590 tracks re-instating it # coverage: diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 66de725ac..9a77fef38 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -41,8 +41,6 @@ This section describes how you can get started with Ballista development. Ballista contains components implemented in the following programming languages: - Rust (Scheduler and Executor processes, Client library) -- Python (Python bindings) -- Javascript (Scheduler Web UI) ### Rust Environment @@ -95,10 +93,6 @@ for the executor becomes `BALLISTA_EXECUTOR_SCHEDULER_HOST` Refer to the instructions in the Python Bindings [README](./python/README.md) -### Javascript Environment - -Refer to the instructions in the Scheduler Web UI [README](./ballista/scheduler/ui/README.md) - ## Integration Tests The integration tests can be executed by running the following command from the root of the repository. diff --git a/README.md b/README.md index 4b149f5d1..80c108178 100644 --- a/README.md +++ b/README.md @@ -70,7 +70,7 @@ See the [architecture guide](docs/source/contributors-guide/architecture.md) for - DataFrame and SQL APIs available from Python and Rust. - Clients can connect to a Ballista cluster using [Flight SQL][flight-sql]. - JDBC support via Arrow Flight SQL JDBC Driver -- Scheduler web interface and REST UI for monitoring query progress and viewing query plans and metrics. +- Scheduler REST UI for monitoring query progress and viewing query plans and metrics. - Support for Docker, Docker Compose, and Kubernetes deployment, as well as manual deployment on bare metal. ## Performance @@ -105,5 +105,4 @@ Please see the [Contribution Guide](CONTRIBUTING.md) for information about contr [datafusion]: https://github.com/apache/arrow-datafusion [flight]: https://arrow.apache.org/blog/2019/10/13/introducing-arrow-flight/ [flight-sql]: https://arrow.apache.org/blog/2022/02/16/introducing-arrow-flight-sql/ -[ballista-talk]: https://www.youtube.com/watch?v=ZZHQaOap9pQ [user-guide]: https://datafusion.apache.org/ballista/ diff --git a/ballista/scheduler/ui/.dockerignore b/ballista/scheduler/ui/.dockerignore deleted file mode 100644 index dd87e2d73..000000000 --- a/ballista/scheduler/ui/.dockerignore +++ /dev/null @@ -1,2 +0,0 @@ -node_modules -build diff --git a/ballista/scheduler/ui/.gitignore b/ballista/scheduler/ui/.gitignore deleted file mode 100644 index 15a75a078..000000000 --- a/ballista/scheduler/ui/.gitignore +++ /dev/null @@ -1,23 +0,0 @@ -# See https://help.github.com/articles/ignoring-files/ for more about ignoring files. - -# dependencies -node_modules/ -/.pnp -.pnp.js - -# testing -/coverage - -# production -build/ - -# misc -.DS_Store -.env.local -.env.development.local -.env.test.local -.env.production.local - -npm-debug.log* -yarn-debug.log* -yarn-error.log* diff --git a/ballista/scheduler/ui/README.md b/ballista/scheduler/ui/README.md deleted file mode 100644 index 4e72825c5..000000000 --- a/ballista/scheduler/ui/README.md +++ /dev/null @@ -1,61 +0,0 @@ - - -# Ballista UI - -## Start project from source - -### Run scheduler/executor - -First, run scheduler from project: - -```shell -$ cd ballista/scheduler -$ RUST_LOG=info cargo run --release -... - Finished release [optimized] target(s) in 11.92s - Running `/path-to-project/target/release/ballista-scheduler` -``` - -and run executor in new terminal: - -```shell -$ cd ballista/executor -$ RUST_LOG=info cargo run --release - Finished release [optimized] target(s) in 0.09s - Running `/path-to-project/target/release/ballista-executor` -``` - -### Run Client project - -```shell -$ cd ballista/scheduler/ui -$ yarn -Resolving packages... -$ yarn start -Starting the development server... -``` - -Now access to http://localhost:3000/ - -**NOTE**: If you get an error when running the `yarn start` command above, make sure -to use the `lts` version of npm. - -You can install it by running: `npm install --lts`. This should fix any errors that -may occur when trying to start the Ballista UI project. diff --git a/ballista/scheduler/ui/index.d.ts b/ballista/scheduler/ui/index.d.ts deleted file mode 100644 index be0f38ba0..000000000 --- a/ballista/scheduler/ui/index.d.ts +++ /dev/null @@ -1,18 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. - -declare module "@chakra-ui/icons"; diff --git a/ballista/scheduler/ui/package.json b/ballista/scheduler/ui/package.json deleted file mode 100644 index 1bf27a8a8..000000000 --- a/ballista/scheduler/ui/package.json +++ /dev/null @@ -1,60 +0,0 @@ -{ - "name": "scheduler-ui", - "version": "0.1.0", - "private": true, - "dependencies": { - "@chakra-ui/icons": "^2.1.1", - "@chakra-ui/react": "^2.8.2", - "@emotion/react": "^11.11.3", - "@emotion/styled": "^11.11.0", - "@testing-library/jest-dom": "^6.2.1", - "@testing-library/react": "^14.1.2", - "@testing-library/user-event": "^14.5.2", - "@types/jest": "^29.5.11", - "@types/node": "^20.11.5", - "@types/react": "^18.2.48", - "@types/react-dom": "^18.2.18", - "framer-motion": "^11.0.2", - "js-file-download": "^0.4.12", - "react": "^18.2.0", - "react-dom": "^18.2.0", - "react-icons": "^5.0.1", - "react-inlinesvg": "^4.1.1", - "react-router-dom": "^6.21.3", - "react-scripts": "5.0.1", - "react-table": "^7.8.0", - "react-timeago": "^7.2.0", - "typescript": "^5.3.3", - "web-vitals": "^3.5.1" - }, - "scripts": { - "start": "react-scripts --openssl-legacy-provider start", - "build": "react-scripts --openssl-legacy-provider build", - "test": "react-scripts test", - "eject": "react-scripts eject" - }, - "eslintConfig": { - "extends": [ - "react-app", - "react-app/jest" - ] - }, - "browserslist": { - "production": [ - ">0.2%", - "not dead", - "not op_mini all" - ], - "development": [ - "last 1 chrome version", - "last 1 firefox version", - "last 1 safari version" - ] - }, - "devDependencies": { - "@types/react-table": "^7.7.19", - "@types/react-timeago": "^4.1.7", - "prettier": "^3.2.4", - "http-proxy-middleware": "^2.0.6" - } -} diff --git a/ballista/scheduler/ui/public/favicon.ico b/ballista/scheduler/ui/public/favicon.ico deleted file mode 100644 index a11777cc4..000000000 Binary files a/ballista/scheduler/ui/public/favicon.ico and /dev/null differ diff --git a/ballista/scheduler/ui/public/index.html b/ballista/scheduler/ui/public/index.html deleted file mode 100644 index d902333f0..000000000 --- a/ballista/scheduler/ui/public/index.html +++ /dev/null @@ -1,62 +0,0 @@ - - - - - - - - - - - - - - - Ballista UI - - - -
- - - diff --git a/ballista/scheduler/ui/public/logo192.png b/ballista/scheduler/ui/public/logo192.png deleted file mode 100644 index fc44b0a37..000000000 Binary files a/ballista/scheduler/ui/public/logo192.png and /dev/null differ diff --git a/ballista/scheduler/ui/public/logo512.png b/ballista/scheduler/ui/public/logo512.png deleted file mode 100644 index a4e47a654..000000000 Binary files a/ballista/scheduler/ui/public/logo512.png and /dev/null differ diff --git a/ballista/scheduler/ui/public/manifest.json b/ballista/scheduler/ui/public/manifest.json deleted file mode 100644 index 080d6c77a..000000000 --- a/ballista/scheduler/ui/public/manifest.json +++ /dev/null @@ -1,25 +0,0 @@ -{ - "short_name": "React App", - "name": "Create React App Sample", - "icons": [ - { - "src": "favicon.ico", - "sizes": "64x64 32x32 24x24 16x16", - "type": "image/x-icon" - }, - { - "src": "logo192.png", - "type": "image/png", - "sizes": "192x192" - }, - { - "src": "logo512.png", - "type": "image/png", - "sizes": "512x512" - } - ], - "start_url": ".", - "display": "standalone", - "theme_color": "#000000", - "background_color": "#ffffff" -} diff --git a/ballista/scheduler/ui/public/robots.txt b/ballista/scheduler/ui/public/robots.txt deleted file mode 100644 index dc045698d..000000000 --- a/ballista/scheduler/ui/public/robots.txt +++ /dev/null @@ -1,20 +0,0 @@ -# Licensed to the Apache Software Foundation (ASF) under one -# or more contributor license agreements. See the NOTICE file -# distributed with this work for additional information -# regarding copyright ownership. The ASF licenses this file -# to you under the Apache License, Version 2.0 (the -# "License"); you may not use this file except in compliance -# with the License. You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, -# software distributed under the License is distributed on an -# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -# KIND, either express or implied. See the License for the -# specific language governing permissions and limitations -# under the License. - -# https://www.robotstxt.org/robotstxt.html -User-agent: * -Disallow: diff --git a/ballista/scheduler/ui/react-table-config.d.ts b/ballista/scheduler/ui/react-table-config.d.ts deleted file mode 100644 index 2c9994f91..000000000 --- a/ballista/scheduler/ui/react-table-config.d.ts +++ /dev/null @@ -1,146 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. - -import { - UseColumnOrderInstanceProps, - UseColumnOrderState, - UseExpandedHooks, - UseExpandedInstanceProps, - UseExpandedOptions, - UseExpandedRowProps, - UseExpandedState, - UseFiltersColumnOptions, - UseFiltersColumnProps, - UseFiltersInstanceProps, - UseFiltersOptions, - UseFiltersState, - UseGlobalFiltersColumnOptions, - UseGlobalFiltersInstanceProps, - UseGlobalFiltersOptions, - UseGlobalFiltersState, - UseGroupByCellProps, - UseGroupByColumnOptions, - UseGroupByColumnProps, - UseGroupByHooks, - UseGroupByInstanceProps, - UseGroupByOptions, - UseGroupByRowProps, - UseGroupByState, - UsePaginationInstanceProps, - UsePaginationOptions, - UsePaginationState, - UseResizeColumnsColumnOptions, - UseResizeColumnsColumnProps, - UseResizeColumnsOptions, - UseResizeColumnsState, - UseRowSelectHooks, - UseRowSelectInstanceProps, - UseRowSelectOptions, - UseRowSelectRowProps, - UseRowSelectState, - UseRowStateCellProps, - UseRowStateInstanceProps, - UseRowStateOptions, - UseRowStateRowProps, - UseRowStateState, - UseSortByColumnOptions, - UseSortByColumnProps, - UseSortByHooks, - UseSortByInstanceProps, - UseSortByOptions, - UseSortByState, -} from "react-table"; - -declare module "react-table" { - // take this file as-is, or comment out the sections that don't apply to your plugin configuration - - export interface TableOptions< - D extends Record - > extends UseExpandedOptions, - UseFiltersOptions, - UseGlobalFiltersOptions, - UseGroupByOptions, - UsePaginationOptions, - UseResizeColumnsOptions, - UseRowSelectOptions, - UseRowStateOptions, - UseSortByOptions, - // note that having Record here allows you to add anything to the options, this matches the spirit of the - // underlying js library, but might be cleaner if it's replaced by a more specific type that matches your - // feature set, this is a safe default. - Record {} - - export interface Hooks< - D extends Record = Record - > extends UseExpandedHooks, - UseGroupByHooks, - UseRowSelectHooks, - UseSortByHooks {} - - export interface TableInstance< - D extends Record = Record - > extends UseColumnOrderInstanceProps, - UseExpandedInstanceProps, - UseFiltersInstanceProps, - UseGlobalFiltersInstanceProps, - UseGroupByInstanceProps, - UsePaginationInstanceProps, - UseRowSelectInstanceProps, - UseRowStateInstanceProps, - UseSortByInstanceProps {} - - export interface TableState< - D extends Record = Record - > extends UseColumnOrderState, - UseExpandedState, - UseFiltersState, - UseGlobalFiltersState, - UseGroupByState, - UsePaginationState, - UseResizeColumnsState, - UseRowSelectState, - UseRowStateState, - UseSortByState {} - - export interface ColumnInterface< - D extends Record = Record - > extends UseFiltersColumnOptions, - UseGlobalFiltersColumnOptions, - UseGroupByColumnOptions, - UseResizeColumnsColumnOptions, - UseSortByColumnOptions {} - - export interface ColumnInstance< - D extends Record = Record - > extends UseFiltersColumnProps, - UseGroupByColumnProps, - UseResizeColumnsColumnProps, - UseSortByColumnProps {} - - export interface Cell< - D extends Record = Record, - V = any - > extends UseGroupByCellProps, - UseRowStateCellProps {} - - export interface Row< - D extends Record = Record - > extends UseExpandedRowProps, - UseGroupByRowProps, - UseRowSelectRowProps, - UseRowStateRowProps {} -} diff --git a/ballista/scheduler/ui/src/App.css b/ballista/scheduler/ui/src/App.css deleted file mode 100644 index bea95535e..000000000 --- a/ballista/scheduler/ui/src/App.css +++ /dev/null @@ -1,18 +0,0 @@ -/* - Licensed to the Apache Software Foundation (ASF) under one - or more contributor license agreements. See the NOTICE file - distributed with this work for additional information - regarding copyright ownership. The ASF licenses this file - to you under the Apache License, Version 2.0 (the - "License"); you may not use this file except in compliance - with the License. You may obtain a copy of the License at - - http://www.apache.org/licenses/LICENSE-2.0 - - Unless required by applicable law or agreed to in writing, - software distributed under the License is distributed on an - "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - KIND, either express or implied. See the License for the - specific language governing permissions and limitations - under the License. -*/ diff --git a/ballista/scheduler/ui/src/App.test.tsx b/ballista/scheduler/ui/src/App.test.tsx deleted file mode 100644 index 20dca216e..000000000 --- a/ballista/scheduler/ui/src/App.test.tsx +++ /dev/null @@ -1,26 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. - -import React from "react"; -import { render, screen } from "@testing-library/react"; -import App from "./App"; - -test("renders learn react link", () => { - render(); - const linkElement = screen.getByText(/learn react/i); - expect(linkElement).toBeInTheDocument(); -}); diff --git a/ballista/scheduler/ui/src/App.tsx b/ballista/scheduler/ui/src/App.tsx deleted file mode 100644 index c66fb37f7..000000000 --- a/ballista/scheduler/ui/src/App.tsx +++ /dev/null @@ -1,107 +0,0 @@ -// Licensed to the Apache Software Foundation (ASF) under one -// or more contributor license agreements. See the NOTICE file -// distributed with this work for additional information -// regarding copyright ownership. The ASF licenses this file -// to you under the Apache License, Version 2.0 (the -// "License"); you may not use this file except in compliance -// with the License. You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, -// software distributed under the License is distributed on an -// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY -// KIND, either express or implied. See the License for the -// specific language governing permissions and limitations -// under the License. - -import React, { useState, useEffect } from "react"; -import { - Box, - Grid, - Tab, - TabList, - TabPanel, - TabPanels, - Tabs, - VStack, -} from "@chakra-ui/react"; -import { Header } from "./components/Header"; -import { Summary } from "./components/Summary"; -import { ExecutorsList } from "./components/ExecutorsList"; -import { QueriesList } from "./components/QueriesList"; -import { Footer } from "./components/Footer"; -import "./App.css"; - -const App: React.FunctionComponent = () => { - const [schedulerState, setSchedulerState] = useState(undefined); - const [jobs, setJobs] = useState(undefined); - const [executors, setExecutors] = useState(undefined); - - function getSchedulerState() { - return fetch(`/api/state`, { - method: "POST", - headers: { - Accept: "application/json", - }, - }) - .then((res) => res.json()) - .then((res) => setSchedulerState(res)); - } - - function getJobs() { - return fetch(`/api/jobs`, { - method: "POST", - headers: { - Accept: "application/json", - }, - }) - .then((res) => res.json()) - .then((res) => setJobs(res)); - } - - function getExecutors() { - return fetch(`/api/executors`, { - method: "POST", - headers: { - Accept: "application/json", - }, - }) - .then((res) => res.json()) - .then((res) => setExecutors(res)); - } - - useEffect(() => { - getSchedulerState(); - getJobs(); - getExecutors(); - }, []); - - return ( - - - -
- - - - Jobs - Executors - - - - - - - - - - -