Skip to content

Commit

Permalink
tap-cassandra working
Browse files Browse the repository at this point in the history
  • Loading branch information
MindaugasN committed Jul 5, 2023
1 parent 5506e7f commit 292dc95
Show file tree
Hide file tree
Showing 8 changed files with 1,791 additions and 139 deletions.
51 changes: 35 additions & 16 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,35 +8,54 @@ Built with the [Meltano Tap SDK](https://sdk.meltano.com) for Singer Taps.
Developer TODO: Update the below as needed to correctly describe the install procedure. For instance, if you do not have a PyPi repo, or if you want users to directly install from your git repo, you can modify this step as appropriate.
## Installation
Install from PyPi:
```bash
pipx install tap-cassandra
```
-->

## Installation

Install from GitHub:

```bash
pipx install git+https://github.com/ORG_NAME/tap-cassandra.git@main
pipx install git+https://github.com/datarts-tech/tap-cassandra.git@main
```

-->

## Configuration

### Accepted Config Options

<!--
Developer TODO: Provide a list of config options accepted by the tap.

This section can be created by copy-pasting the CLI output from:

```
tap-cassandra --about --format=markdown
```
-->
## Capabilities

* `catalog`
* `state`
* `discover`
* `about`
* `stream-maps`
* `schema-flattening`
* `batch`

## Settings

| Setting | Required | Default | Description |
|:--------------------|:--------:|:-------:|:------------|
| hosts | True | None | The list of contact points to try connecting for cluster discovery. |
| port | False | 9042 | The server-side port to open connections to. Defaults to 9042.. |
| keyspace | True | None | Keyspace will be the default keyspace for operations on the Session. |
| username | True | None | The username passed as a PlainTextAuthProvider username. |
| password | True | None | The password passed as a PlainTextAuthProvider password. |
| start_date | False | None | The earliest record date to sync. |
| request_timeout | False | 100 | Request timeout used when not overridden in Session.execute(). |
| local_dc | False | None | The local_dc parameter should be the name of the datacenter. |
| reconnect_delay | False | 60 | Floating point number of seconds to wait inbetween each attempt. |
| max_attempts | False | 5 | Should be a total number of attempts to be made before giving up. |
| protocol_version | False | 65 | The maximum version of the native protocol to use. |
| stream_maps | False | None | Config object for stream maps capability. For more information check out [Stream Maps](https://sdk.meltano.com/en/latest/stream_maps.html). |
| stream_map_config | False | None | User-defined config values to be used within map expressions. |
| flattening_enabled | False | None | 'True' to enable schema flattening and automatically expand nested properties. |
| flattening_max_depth| False | None | The max depth to flatten schemas. |
| batch_config | False | None | |

A full list of supported settings and capabilities for this
tap is available by running:
Expand Down
21 changes: 13 additions & 8 deletions meltano.yml
Original file line number Diff line number Diff line change
@@ -1,29 +1,34 @@
version: 1
send_anonymous_usage_stats: true
project_id: "tap-cassandra"
project_id: tap-cassandra
default_environment: test
environments:
- name: test
plugins:
extractors:
- name: "tap-cassandra"
namespace: "tap_cassandra"
- name: tap-cassandra
namespace: tap_cassandra
pip_url: -e .
capabilities:
- state
- catalog
- discover
- about
- stream-maps
config:
start_date: '2010-01-01T00:00:00Z'
- schema-flattening
- batch
settings:
# TODO: To configure using Meltano, declare settings and their types here:
- name: username
- name: password
kind: password
- name: start_date
value: '2010-01-01T00:00:00Z'
- name: hosts
- name: keyspace
- name: local_dc
- name: port
- name: request_timeout
- name: reconnect_delay
- name: max_attempts
- name: protocol_version
loaders:
- name: target-jsonl
variant: andyh1203
Expand Down
1,286 changes: 1,286 additions & 0 deletions poetry.lock

Large diffs are not rendered by default.

1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ license = "MIT"
python = "<3.12,>=3.7.1"
singer-sdk = { version="^0.28.0" }
fs-s3fs = { version = "^1.1.1", optional = true }
cassandra-driver = "^3.28.0"

[tool.poetry.group.dev.dependencies]
pytest = "^7.2.1"
Expand Down
Loading

0 comments on commit 292dc95

Please sign in to comment.