scylladb / scylladb/alternator-client-java

Idea: a cross-language test framework for all Alternator drivers

Open
#113 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Java
Stars
0
Forks
7
Avg merge
21h 23m
Merged PRs (30d)
9

Description

Jira task: https://scylladb.atlassian.net/browse/DRIVER-715
Jira epic: https://scylladb.atlassian.net/browse/DRIVER-53

Copied from Jira epic DRIVER-53:

There are various features that we need to add to Alternator drivers in every single language. A recent example is handling of Scylla nodes that are not yet available or no longer available (https://github.com/scylladb/scylladb/issues/26326). But there's a whole list of features which we added, or want to add, to every single Alternator driver in every single language - see a collection of these in

https://github.com/scylladb/alternator-load-balancing/issues/152.

The proposal in this issue is to develop a testing framework that will allow us to test these features on every single language, without needing to rewrite each test in N different languages. More importantly, I want to avoid even the need to remember to write the test in each new language: There's a real risk so if we forget to port some feature to our Fortran driver, and we also forget to port the test for that feature for the Fortran driver, then we'll never remember to do that and the feature will forever remain missing in the Fortran driver. The goal of this issue is to prevent this.

I think it should not be too hard to create a test framework that creates a Scylla cluster (or different Scylla clusters for different situations), and then takes a "script" of DynamoDB operations in a pseudo-language (not in any specific language) that the framework can translate into SDK calls in different languages. For example, for [#26326|https://github.com/scylladb/alternator-load-balancing/issues/26326] the test script might say something like:

  1. Create an Alternator cluster with 3 nodes.
  2. Kill one of the 3 nodes abruptly.
  3. Run a "PutItem" request. It shouldn't have an error even if the load balancer chose the dead node as the coordinator because (if [#26326|https://github.com/scylladb/alternator-load-balancing/issues/26326] is done) the retry will happen on a different node.

The idea is that every language the specific command to connect to the cluster and run a "PutItem request" and look at its response will be different, but other than that, the test will be the same.

CC @dkropachev

Migrated from GitHub issue: https://github.com/scylladb/alternator-load-balancing/issues/154

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading Jira tasks DRIVER-715 and DRIVER-53, then review the linked Alternator load-balancing issue collection and issue #26326. Define the pseudo-language, cluster scenarios, and per-language SDK translation; done means the same operation scripts can exercise every Alternator driver without rewriting each test.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
backend-api-design, testing-qa
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.