Skip to content

Commit

Permalink
Update readme (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
shraddhaag authored Jan 25, 2024
1 parent 7c0ee0c commit 466fb9c
Showing 1 changed file with 12 additions and 3 deletions.
15 changes: 12 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ The following steps will allow you to deploy the connector and use it in a Hasur
1. The easiest option is to is to run the connector locally in config mode:
```
cargo run -- configuration serve --port 5000
curl -X POST -d '{"connection": {"username": "your_username", "password": "your_password", "url": "your_clickhouse_url"}, "tables": []}' http://localhost:5000 > clickhouse.connector.configuration.json
curl -X POST -H 'Content-Type: application/json' -d '{"connection": {"username": "your_username", "password": "your_password", "url": "your_clickhouse_url"}, "tables": []}' http://localhost:5000 > clickhouse.connector.configuration.json
```
2. The other option is to manually write your config that follows this pattern:
```
Expand Down Expand Up @@ -67,8 +67,17 @@ The following steps will allow you to deploy the connector and use it in a Hasur
--github-repo-url https://github.com/hasura/ndc-clickhouse/tree/main \
--config-file ./clickhouse.connector.configuration.json
```
- Ensure that your deployed connector is referenced from your metadata with the service token
- Edit your metadata using the LSP support to import the defined schema, functions, procedures
- Ensure that your deployed connector is referenced from your metadata with the service token. This can be done by adding a new file under `subgraphs/<YOUR_SUBGRAPH_DIR>/dataconnectors` with the following:

```
kind: DataConnector
version: v1
definition:
name: clickhouse
url:
singleUrl: <DEPLOYED_CONNECTOR_URL>
```
- Edit your metadata using the [LSP](https://marketplace.visualstudio.com/items?itemName=HasuraHQ.hasura) support to import the defined schema by running the comamnd `Hasura: Refresh Data Connector`. You can also track functions and procedures using the LSP command `Hasura: Track All`.
- Deploy or update your Hasura cloud project
```
hasura3 cloud build create --project-id my-project-id \
Expand Down

0 comments on commit 466fb9c

Please sign in to comment.