From 466fb9cc8cbf90b4836b006b10ffe4429872b80e Mon Sep 17 00:00:00 2001 From: Shraddha Agrawal Date: Thu, 25 Jan 2024 18:10:05 +0530 Subject: [PATCH] Update readme (#8) --- README.md | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index a063641..081c2ca 100644 --- a/README.md +++ b/README.md @@ -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: ``` @@ -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//dataconnectors` with the following: + +``` +kind: DataConnector +version: v1 +definition: + name: clickhouse + url: + singleUrl: +``` +- 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 \