question

francisdomoney@aol.com avatar image
francisdomoney@aol.com asked Erick Ramirez answered

Stargate Docs crashes on step 2 on KataKoda

Result of attempting to load document 1 "

% Total % Received % Xferd Average Speed Time Time Time Current

Dload Upload Total Spent Left Speed

100 1103 100 19 100 1084 211 12044 --:--:-- --:--:-- --:--:-- 12255

404

parse error: Invalid numeric literal at line 1, column 9

$"

Same happens on GraphQL API step 2

curl "https://${ASTRA_DB_ID}-${ASTRA_DB_REGION}.apps.astra.datastax.com/api/graphql-schema" \

> --header "Accept-Encoding: gzip, deflate, br" \

> --header "Content-Type: application/json" \

> --header "Accept: application/json" \

> --header "Connection: keep-alive" \

> --header "DNT: 1" \

> --header "Origin: https://${ASTRA_DB_ID}-${ASTRA_DB_REGION}.apps.astra.datastax.com" \

> --header "x-cassandra-token: ${ASTRA_AUTHORIZATION_TOKEN}" \

> --data-binary '{"query":"mutation {books: createTable(keyspaceName: \"'"$ASTRA_DB_KEYSPACE"'\" tableName: \"books\" partitionKeys: [{name: \"title\", type: {basic: TEXT}}] values: [{name: \"author\", type: {basic: TEXT}}]) authors: createTable(keyspaceName: \"'"$ASTRA_DB_KEYSPACE"'\" tableName: \"authors\" partitionKeys: [{ name: \"name\", type: {basic: TEXT}}] clusteringKeys: [{name: \"title\", type: {basic: TEXT}, order: \"ASC\"}])}"}' --compressed | jq

% Total % Received % Xferd Average Speed Time Time Time Current

Dload Upload Total Spent Left Speed

100 423 100 19 100 404 128 2729 --:--:-- --:--:-- --:--:-- 2858

404

parse error: Invalid numeric literal at line 1, column 9

stargate
5 comments
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

francisdomoney@aol.com avatar image francisdomoney@aol.com commented ·

[Update re-posted in original question]

0 Likes 0 ·
francisdomoney@aol.com avatar image francisdomoney@aol.com commented ·

This is getting frustrating. The astra database works, but I still get the 404 page not found error

0 Likes 0 ·
francisdomoney@aol.com avatar image francisdomoney@aol.com francisdomoney@aol.com commented ·

This url on the document API doesn't look right curl --request POST \

--url https://$ASTRA_DB_ID-$ASTRA_DB_REGION.apps.astra.datastax.com/api/rest/v1/auth \

--header 'Content-Type: application/json' \

--data '{

"username":"'$ASTRA_DB_USERNAME'", "password":"'$ASTRA_DB_PASSWORD'"}'

[2:41 PM]

The URL that works starts https://astra.datastax.com/org/816cb492-2fc6-435a-9d73-e12cd3cd818c/database ........

0 Likes 0 ·
smadhavan avatar image smadhavan ♦ francisdomoney@aol.com commented ·

@francisdomoney@aol.com , I tested the same scenario step at https://www.datastax.com/dev/graphql#introduction and faced no issues.

I tested scenario the step 2 of 6, Creating a table with the GraphQL API and attached the output here for you to see for yourself. If you continue to have errors, can you provide detailed steps (URL of the scenario, Step details, command details and output screenshots/console output text attachment, etc,) as to where you get the errors for us to better understand the issue?

0 Likes 0 ·
Show more comments
francisdomoney@aol.com avatar image
francisdomoney@aol.com answered

OK problem solved. I was using an old database from July 2020. Deleting it and reestablishing it solved the problem

Share
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

steve.halladay avatar image
steve.halladay answered steve.halladay commented

Try removing the `| jq` from the end of the command to see the error message. `jq` is a json beautifier. The command appears to be returning an error that is not json - this is what the current error indicates. By removing the `jq`, you will be able to see the message, which should help.

2 comments Share
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.

francisdomoney@aol.com avatar image francisdomoney@aol.com commented ·

Thanks

That lets me see that the error is 404 page not found

so looking for URL of missing page https://538f8fdc-1f23-4f53-8e20-80db9b243416-europe-west1.apps.astra.datastax.com/


The link given on the Astra database doesn't seem to work either.

Launching Swagger UI

Visualize and interact with your database’s REST API directly from your web browser with Swagger UI: https://538f8fdc-1f23-4f53-8e20-80db9b243416-europe-west1.apps.astra.datastax.com/api/rest/swagger-ui/

0 Likes 0 ·
steve.halladay avatar image steve.halladay ♦ francisdomoney@aol.com commented ·

It sounds like Astra might be a bit confused. Is it possible to create a different Astra database and use that?

0 Likes 0 ·
Erick Ramirez avatar image
Erick Ramirez answered

I've confirmed with the Astra Engineering team that the cause of the problem is that old free-tier instances don't support new features such as the Document API.

Free-tier instances are not automatically upgraded to newer releases since they are designed for proof-of-concept work which allows developers to trial Astra.

New features and updates are constantly being released so we recommend launching a new instance when trying things out on Astra. Cheers!

Share
10 |1000

Up to 8 attachments (including images) can be used with a maximum of 1.0 MiB each and 10.0 MiB total.