What's new
-
New
astra db data-api [repl|exec]commands! (beta)- Use
astrapyorastra-db-tsto quickly and easily interact with the Data API, either through an interactive session, or with your own code, usingnode,python, oripythonunder the hood. You can bring your own packages as well! - Try it out yourself!:
astra db data-api repl(spin up a basic repl)astra db data-api repl --python -c -t(it can prompt for which collections/tables to include)astra db data-api exec my_db -c my_coll -e 'my_coll.insertOne({ name: "Astra" })' -- -p
- Use
-
New
astra dotenv [write|print]commands to replaceastra db create-dotenv! (beta)- This aims to make
astra dotenvmuch more practical for actual usage! No more fiddling with your.envfiles every time you switch databases–you can trust astra to update your existing.envfiles through binding comments! - In your .env file, simply comment your env var with
# astra: <ASTRA_ENV_KEY_NAME>. For example: TOKEN=<token> # astra: ASTRA_DB_TOKEN(the comment doesn't need to be inline; it can be before the env var as well)- Then, simply run
astra dotenv writeto update it whenever you need to! - This way, you're no longer stuck with
astra db create-dotenv's opinionated env var names–but in case you used them, they'll still work without any comments needed if the env var name matches!- Just use
astra dotenv list-keysto see what options there are
- Just use
- Note:
astrais very careful not to mess with the rest of your env file, including the formatting (whitespace, quotes, etc.). It'll only touch exactly what you ask it to. However, if you want to stay careful,astra dotenv printcan still take-f .envas an argument and print out what the .env file would be with any updates applied
- This aims to make
-
Various command improvements:
astra db createnow gives you a list of regions to select from if you didn't provide one- No more needing to run preemptive
astra db regions vectorcalls! - Also added
-pg/--pcu-groupflag
- No more needing to run preemptive
astra pcuis now out of beta- New
astra pcu list-typescommand added - New
astra pcu find-associationcommand added astra pcu transfer-associationcan now autodetect the current PCU group the datacenter is in
- New
astra db regions [vector|serverless]now use filter-by-org=enabled by default- Use the new
-a/--allflag to disable this and go back to the original behavior
- Use the new
astra db cqlshandastra db dsbulknow have much better additional argument passing- Additional arguments can be passed to cqlsh/dsbulk verbatim like so:
astra db cqlsh repl my_db -- --flag1 --flag2 value- A bug with parsing backslashes in
astra db cqlsh execshould also be fixed now
astra db endpointsimprovements- Added
data-api-clientendpoint astra db endpointsis now an alias forendpoints list(similar to commands likeastra dbandastra config)- Added
-c/--copyfor the variousastra db endpoints *commands, similar toastra token -c
- Added
astra token listimprovements- Greatly improved performance when there are new (uncached) roles in the orgs you run it against
- Fixed erroring if role id isn't in expected uuid format
astra db resumeshould be fixed to work with the new server response now- It also removes the last reference to the old Stargate APIs from the CLI
astra db dsbulkhas been updated to use dsbulk v1.11.2 (from v1.11.0)astra config use's autocomplete will no longer suggestdefaultastra setuphas a new flow for when you already have an existing config file- it'll ask you if you want to "create a new profile", "setup autocomplete" (if not already setup), "view the docs", or "cancel"
astra shellenvhas some new options- Various updated help-text/error messages
-
Misc other improvements:
- You can now provide an endpoint to refer to any db
- If the command takes a region, it'll infer the region from the endpoint if you don't provide an explicit region yourself:
astra db download-scb https://<id>-us-east1.apps.astra.datastax.comwill download us-east1 (unless you use--region)astra db download-scb https://<id>-FAKE.apps.astra.datastax.comwill fail (unless you use--region)
- Tweaked formatting of various "human" outputs
- Removed explicit indexing in tables, e.g.
│ [0] us-east-1 │ - Removed sorting of a few list fields (e.g. db regions or keyspaces), instead using the server's ordering
- Removed explicit indexing in tables, e.g.
- You can now provide an endpoint to refer to any db