Azure Cosmos DB Cassandra API 简介Introduction to the Azure Cosmos DB Cassandra API

适用于: Cassandra API

Azure Cosmos DB Cassandra API 可以充当为 Apache Cassandra 编写的应用的数据存储。Azure Cosmos DB Cassandra API can be used as the data store for apps written for Apache Cassandra. 这意味着通过使用现有的符合 CQLv4 的 Apache 驱动程序,现有 Cassandra 应用程序现在可以与 Azure Cosmos DB Cassandra API 通信。This means that by using existing Apache drivers compliant with CQLv4, your existing Cassandra application can now communicate with the Azure Cosmos DB Cassandra API. 在许多情况下,只需更改连接字符串,就可以从使用 Apache Cassandra 切换为使用 Azure Cosmos DB Cassandra API。In many cases, you can switch from using Apache Cassandra to using Azure Cosmos DB's Cassandra API, by just changing a connection string.

通过 Cassandra API 可以使用 Cassandra 查询语言 (CQL)、基于 Cassandra 的工具(如 cqlsh)和熟悉的 Cassandra 客户端驱动程序与 Azure Cosmos DB 中存储的数据进行交互。The Cassandra API enables you to interact with data stored in Azure Cosmos DB using the Cassandra Query Language (CQL) , Cassandra-based tools (like cqlsh) and Cassandra client drivers that you're already familiar with.

使用 Azure Cosmos DB Cassandra API 的优势是什么?What is the benefit of using Apache Cassandra API for Azure Cosmos DB?

无需操作管理 :作为一个完全托管的云服务,Azure Cosmos DB Cassandra API 不需管理和监视跨 OS、JVM 和 yaml 文件的大量设置,也不需进行交互。No operations management : As a fully managed cloud service, Azure Cosmos DB Cassandra API removes the overhead of managing and monitoring a myriad of settings across OS, JVM, and yaml files and their interactions. Azure Cosmos DB 提供对吞吐量、延迟、存储、可用性以及可配置警报的监视。Azure Cosmos DB provides monitoring of throughput, latency, storage, availability, and configurable alerts.

开放源代码标准 :尽管 Cassandra API 是一个完全托管服务,但它仍然支持原生 Apache Cassandra 线路协议的很大一部分,允许你按照广泛使用且与云无关的开源标准构建应用程序。Open source standard : Despite being a fully managed service, Cassandra API still supports a large surface area of the native Apache Cassandra wire protocol, allowing you to build applications on a widely used and cloud agnostic open source standard.

性能管理 :Azure Cosmos DB 可以确保 SLA 所保证的在 99% 的情况下实现低延迟读写。Performance management : Azure Cosmos DB provides guaranteed low latency reads and writes at the 99th percentile, backed up by the SLAs. 用户不需担心操作开销,可以确保高性能和低延迟读写。Users do not have to worry about operational overhead to ensure high performance and low latency reads and writes. 这意味着,用户不需手动计划压缩、管理逻辑删除、设置布隆筛选器和副本。This means that users do not need to deal with scheduling compaction, managing tombstones, setting up bloom filters and replicas manually. Azure Cosmos DB 没有管理这些问题的开销,让你专注于应用程序逻辑。Azure Cosmos DB removes the overhead to manage these issues and lets you focus on the application logic.

能够使用现有的代码和工具 :Azure Cosmos DB 提供的线路协议级别与现有 Cassandra SDK 和工具兼容。Ability to use existing code and tools : Azure Cosmos DB provides wire protocol level compatibility with existing Cassandra SDKs and tools. 此兼容性确保只需经过细微的更改,就可以将现有代码库用于 Azure Cosmos DB Cassandra API。This compatibility ensures you can use your existing codebase with Azure Cosmos DB Cassandra API with trivial changes.

吞吐量和存储弹性 :Azure Cosmos DB 可以通过 Azure门户、PowerShell 或 CLI 操作跨所有区域提供吞吐量,并可缩放预配的吞吐量。Throughput and storage elasticity : Azure Cosmos DB provides throughput across all regions and can scale the provisioned throughput with Azure portal, PowerShell, or CLI operations. 可以根据需要弹性缩放表的存储和吞吐量,其性能可以预测。You can elastically scale storage and throughput for your tables as needed with predictable performance.

多区域分发和可用性 :Azure Cosmos DB 可以在所有 Azure 中国区域多区域分发数据,在本地处理数据,同时确保低延迟数据访问和高可用性。Multiple-region distribution and availability : Azure Cosmos DB provides the ability to multiple-regionally distribute data across all Azure China regions and serve the data locally while ensuring low latency data access and high availability. Azure Cosmos DB 在区域内提供 99.99% 的高可用性,跨多个区域提供 99.999% 的读写可用性,并且没有任何运营开销。Azure Cosmos DB provides 99.99% high availability within a region and 99.999% read and write availability across multiple regions with no operations overhead. 在多个区域分配数据一文中了解详细信息。Learn more in Distribute data multiple-regionally article.

一致性选择 :Azure Cosmos DB 提供五个定义明确的一致性级别以供选择,可在一致性和性能之间实现最佳平衡。Choice of consistency : Azure Cosmos DB provides the choice of five well-defined consistency levels to achieve optimal tradeoffs between consistency and performance. 这些一致性级别分别是:强、有限过期、会话、一致前缀和最终。These consistency levels are strong, bounded-staleness, session, consistent prefix and eventual. 通过这些定义明确、实用且直观的一致性级别,开发者可以在一致性、可用性和延迟之间实现精确的平衡。These well-defined, practical, and intuitive consistency levels allow developers to make precise trade-offs between consistency, availability, and latency. 一致性级别一文中了解详细信息。Learn more in consistency levels article.

企业级 :Azure cosmos DB 提供 符合性认证,以确保用户可以安全地使用该平台。Enterprise grade : Azure cosmos DB provides compliance certifications to ensure users can use the platform securely. Azure Cosmos DB 还提供静态和动态加密、IP 防火墙和审核日志以控制平面活动。Azure Cosmos DB also provides encryption at rest and in motion, IP firewall, and audit logs for control plane activities.

事件溯源 :Cassandra API 可以访问持久性更改日志(即 更改源),这便于直接从数据库中获取事件源。Event Sourcing : Cassandra API provides access to a persistent change log, the Change Feed, which can facilitate event sourcing directly from the database. 在 Apache Cassandra 中,唯一的等效项是变更数据捕获 (CDC),它只是一种机制,用于标记要存档的特定表,并在达到 CDC 日志的可配置磁盘空间后拒绝对这些表的写入(这些功能在 Cosmos DB 中是冗余的,因为系统对相关方面进行自动管理)。In Apache Cassandra, the only equivalent is change data capture (CDC), which is merely a mechanism to flag specific tables for archival as well as rejecting writes to those tables once a configurable size-on-disk for the CDC log is reached (these capabilities are redundant in Cosmos DB as the relevant aspects are automatically governed).

后续步骤Next steps