I used the SQL to DGraph migration tool to generate schema.txt
and sql.rdf
files from a MySQL database. The tutorial explains how to import this data into a DGraph instance running on localhost:
dgraph live -z localhost:5080 -a localhost:9080 --files sql.rdf --format=rdf --schema schema.txt
I tried replacing localhost:5080
and localhost:9080
with my https://example.com/graphql
endpoint without success.
There’s another tutorial on importing data into Slash using live loader. It uses this command:
docker run -it --rm -v /path/to/g01.json.gz:/tmp/g01.json.gz dgraph/dgraph:v20.07-slash \
dgraph live --slash_grpc_endpoint=<grpc-endpoint>:443 -f /tmp/g01.json.gz -t <api-token>
I’m quite confused here. Here JSON data is uploaded while schema and rdf
is not mentioned. How do I upload the generated schema.txt
and sql.rdf
to Slash GraphQL?
Edit
Issue resolved, please look at this answer.