CEP-28: Implement Bulk API endpoints and introduce the Sidecar Client to Support Cassandra Analytics

This commit implements the remaining endpoints needed to perform Bulk Analytics operations that allow
reading and writing data from Cassandra in Bulk. The new endpoints include:

- Endpoint to create snapshots
- Endpoint to clear a snapshot
- Endpoint to upload SSTable components
- Endpoint to clean up uploads for SSTable components
- Endpoint to import SSTable components
- Endpoint to retrieve gossip info
- Endpoint to retrieve the time skew for the server
- Endpoint to retrieve the ring information

Sidecar Client

Introduces the fully featured sidecar client to access Cassandra Sidecar endpoints.
It offers support for retries and Sidecar instance selection policies. The client
project itself is technology-agnostic, but we provide a vertx implementation for
the `HttpClient`. The Sidecar vertx-client can be published as a shaded-jar to be
consumed by clients where the dependencies can cause issues, especially in environments
where the dependencies are not always controlled by the consumers (for example Spark).

Patch by Doug, Francisco, Saranya, Yifan, Dinesh; reviewed by Dinesh Joshi and Yifan Cai for CASSANDRA-16222

Co-authored-by: Saranya Krishnakumar <saranya_k@apple.com>
Co-authored-by: Yifan Cai <ycai@apache.org>
Co-authored-by: Francisco Guerrero <francisco.guerrero@apple.com>
Co-authored-by: Doug Rohrer <drohrer@apple.com>
Co-authored-by: Dinesh Joshi <djoshi@apache.org>
262 files changed
tree: 81832e911a6925afe923b0bb33eee77af17c7e07
  1. .circleci/
  2. cassandra40/
  3. client/
  4. common/
  5. docs/
  6. gradle/
  7. ide/
  8. src/
  9. vertx-client/
  10. vertx-client-shaded/
  11. .gitignore
  12. build.gradle
  13. CHANGES.txt
  14. checkstyle.xml
  15. CONTRIBUTING.md
  16. gradle.properties
  17. gradlew
  18. gradlew.bat
  19. LICENSE.txt
  20. README.md
  21. settings.gradle
  22. spotbugs-exclude.xml
README.md

Apache Cassandra Sidecar [WIP]

This is a Sidecar for the highly scalable Apache Cassandra database. For more information, see the Apache Cassandra web site and CIP-1.

This is project is still WIP.

Requirements

  1. Java >= 1.8 (OpenJDK or Oracle), or Java 11
  2. Apache Cassandra 4.0. We depend on virtual tables which is a 4.0 only feature.
  3. Docker for running integration tests.

Getting started: Running The Sidecar

After you clone the git repo, you can use the gradle wrapper to build and run the project. Make sure you have Apache Cassandra running on the host & port specified in conf/sidecar.yaml.

$ ./gradlew run

Configuring Cassandra Instance

While setting up cassandra instance, make sure the data directories of cassandra are in the path stored in sidecar.yaml file, else modify data directories path to point to the correct directories for stream APIs to work.

Testing

We rely on docker containers for integration tests.

The only requirement is to install and run Docker on your test machine.

CircleCI Testing

You will need to use the “Add Projects” function of CircleCI to set up CircleCI on your fork. When promoted to create a branch, do not replace the CircleCI config, choose the option to do it manually. CircleCI will pick up the in project configuration.

Contributing

We warmly welcome and appreciate contributions from the community. Please see CONTRIBUTING.md if you wish to submit pull requests.

Wondering where to go from here?