Connect with Hasura
On this page
The Hasura SingleStore Data Connector ("the connector") connects your SingleStore database to Hasura Data Delivery Network (DDN) and enables you to query and update your SingleStore data via a GraphQL API.
The Hasura SingleStore Data Connector is built using the Native Data Connector SDK for TypeScript, and it implements Hasura's Native Data Connectors specification.
Prerequisites
-
A Hasura Cloud account.
-
Create a supergraph.
-
Create a subgraph.
-
An active SingleStore deployment.
Connect to SingleStore
To connect to your SingleStore deployment using the connector:
-
Set the context for an existing subgraph.
-
Initialize the connector.
ddn connector init -i -
Specify the connection configuration for your SingleStore deployment using the following environment variables:
Variable Name
Description
SINGLESTORE_
HOST Hostname or IP address of your SingleStore deployment.
SINGLESTORE_
PORT Port of your SingleStore deployment.
Default is
3306
.SINGLESTORE_
USER Name of the SingleStore database user with which to access the database.
SINGLESTORE_
PASSWORD Password for the SingleStore database user
SINGLESTORE_
DATABASE Name of the SingleStore database to connect with.
Refer to the Hasura SingleStore Data Connector GitHub repository for information on additional configuration options and connection pool options.
-
Once the connector is initialized, introspect the source database to update the configuration.
-
Add your models, commands, and relationships.
-
Create a new build, and run the scripts using the connector.
The connector is now configured and ready.
Supported Features
Feature |
Supported |
---|---|
Native queries and logical models |
|
Simple object query |
✔ |
Filter or search |
✔ |
Simple aggregation |
✔ |
Sort |
✔ |
Paginate |
✔ |
Table relationships |
✔ |
Views |
✔ |
Distinct |
✔ |
Remote relationships |
✔ |
Mutations |
|
Limitations
SingleStore does not support foreign keys..
files.
References
Last modified: October 18, 2024