Compare Data API client versions

DataStax recommends using the latest versions of the clients to access the latest features, improvements, and bug fixes.

This page describes major changes in specific client versions, including major new features, deprecations, removals, and breaking changes. This page does not provide client release notes.

For information about the latest client versions, installation instructions, and other client documentation, see the links in the following table:

Language Client Version Documentation

python Python

astrapy

Latest release

Connect

Reference

typescript TypeScript

astra-db-ts

Latest release

Connect

Reference

java Java

astra-db-java

Latest release

Connect

Reference

Version 1.5

This version is scheduled for release by the end of September 2024.

Version 1.5 of the Data API clients deprecates namespace in favor of keyspace. In this version, keyspace is a synonym for both namespace and keyspace. This change also applies to the Data API itself (HTTP).

This change aligns the Data API and clients with the DevOps API, which already uses keyspace for both namespaces and keyspaces. It also better reflects the underlying Astra DB functionality, in which namespace is effectively an alternative label for keyspace.

A future client release after version 1.5 will remove support for namespace, and then the clients will accept only keyspace.

After you upgrade to version 1.5, change your code to use keyspace instead of namespace. For example:

  • Python

  • TypeScript

  • Java

  • curl

# Before 1.5
database = client.get_database("API_ENDPOINT", namespace="NAMESPACE_OR_KEYSPACE_NAME")

# 1.5 and later
database = client.get_database("API_ENDPOINT", keyspace="NAMESPACE_OR_KEYSPACE_NAME")
// Before 1.5
const db = client.db('API_ENDPOINT', { namespace: 'NAMESPACE_OR_KEYSPACE_NAME' });

// 1.5 and later
const db = client.db('API_ENDPOINT', { keyspace: 'NAMESPACE_OR_KEYSPACE_NAME' });
// Before 1.5
Database db = client.getDatabase(String apiEndpoint, String namespace);

// 1.5 and later
Database db = client.getDatabase(String apiEndpoint, String keyspace);

The impact to HTTP requests is minimal. HTTP already accepted either a keyspace or namespace name in the URL path, and most commands used a keyspace parameter.

curl -sS --location -X POST "ASTRA_DB_ENDPOINT/api/json/v1/NAMESPACE_OR_KEYSPACE_NAME" \
--header "Token: APPLICATION_TOKEN" \
--header "Content-Type: application/json" \
--data '{DATA_API_COMMAND_BODY}'

Upon release, the Astra DB Serverless documentation and client references will use keyspace in place of namespace, with the following exceptions:

  • Documentation describing the Astra Portal, which will continue to use namespace.

  • Some preexisting integration guides and tutorials that rely on a subcomponent, such as a sample app, that is unrelated to the Data API and has a namespace object, class, variable, or otherwise.

  • Third-party documentation over which DataStax has no influence.

Was this helpful?

Give Feedback

How can we improve the documentation?

© 2024 DataStax | Privacy policy | Terms of use

Apache, Apache Cassandra, Cassandra, Apache Tomcat, Tomcat, Apache Lucene, Apache Solr, Apache Hadoop, Hadoop, Apache Pulsar, Pulsar, Apache Spark, Spark, Apache TinkerPop, TinkerPop, Apache Kafka and Kafka are either registered trademarks or trademarks of the Apache Software Foundation or its subsidiaries in Canada, the United States and/or other countries. Kubernetes is the registered trademark of the Linux Foundation.

General Inquiries: +1 (650) 389-6000, info@datastax.com