CouchBase - davidkhala/database GitHub Wiki
IDC report (2019): Business Value of the Couchbase NoSQL Database
Partner
SVA Distribution will handle the Hong Kong, Taiwan, and Macau markets.
History
CouchBase was formed in 2011 by merging Membase and CouchOne
- Membase was founded by several leaders of the memcached project
- provided client protocol compatibility with
memcached
(by proxy)
- provided client protocol compatibility with
Architecture
Memory First
- CRUD functionality performed against the memory-resident copy of data. Uncached data is fetched from disk of processing in-memory
- Async Persistence by default: client processing can also choose to wait for finality
Connectionless or Not
-
Cluster/Bucket references should be reused (e.g. via Singleton or Connection Manager), and not created per request
-
It is a best practice to ensure the CouchBase connection gets broken or closed cleanly when the application shuts down.
- For Connectionless data usage case, use CouchBase API
Enterprise ready
- API很多,以至于对于同一个的任务有几种方式可以达成
- 对于计算资源的分配和使用(如bucket memory allocation),将权责交给了了客户,提高了透明度和复杂度,因此需要专门的DBA管理
CouchBase Lite
an embedded, NoSQL JSON-document Style database for your mobile apps.
- compete with MongoDB Realm
Limit
- No web (e.g. nodejs, python) support
CouchBase Server
Community Edition
- Limits
- individual cluster sizes to five (5) cluster nodes
- No XDCR
- license: BSL 1.1 (adopted since CouchBase 7)
- same with MariaDB
Enterprise Edition
- count CPU + Memory
- yearly subscription model
- minimum 3 nodes (1 node need special approval)
- minimum 4 vCPU per node
- minimum 16 GB memory
- Pricing: Sales driven
Vector Search
Available in Capalla UI Search Workbench({} Data Tools
> Search
) and Couchbase Server UI??
- Powered by LangChain and LlamaIndex
- RAG Demo
Access via
- API (curl)
- SQL++
- SDK call
Full text Search
Inverted index: an index data structure mapping text or numbers to document
Scoring
- The Search Service uses the tf-idf algorithm
Powered by BLEVE
Time series
CouchBase Edge Server
Couchbase Edge Server is a lightweight REST and sync server for Couchbase Lite
- Supports SQL++ queries.
Limit
- Not for Windows: no any release for win32
Capella: DBaaS
-
You cannot get an Activation id for personal usage. It means it is not allowed to use PAYG
Capella iQ
Available in Capalla UI Query Workbench
features
-
NL2SQL??
-
Index Advice
- Collapse as button in middle-right of Capella Query Workbench page
- In Couchbase EE ??
-
iQ insights: Data Visualizing by AI
- Similar to Oracle Anlyatic Auto Insights
feat: Columnar
Capella is the only JSON-native DBaaS for real-time operational and analytic workloads.
Capella Columnar's zero-ETL ingests and transforms JSON data, along with other data sources to analytics-ready columnar format.
Developers can do more via conversational analytics, without overwhelming the BI team, and metrics can be write-back into Capella source clusters to improve applications and end-user experiences.
feat: App Services
Use App Services as a fully managed backend for your mobile and IoT applications, complete with offline-first support.
- Use [Couchbase Lite] as your local embedded database to run apps in offline mode with uninterrupted access to local data.
- Seamlessly sync data with App Services when devices reconnect to the internet.
- Compete with Atlas Device Sync
- Based on Couchbase Sync Gateway
Free Tier
Announcement: September 9, 2024
- After a certain amount of time of inactivity, the cluster will be paused and you will receive a email.
- The cluster will be deleted if there is extended period of inactivity (30 days)
- You can have up to 1 free cluster
- 10 GB disk storage, Single node
- It can include up to
Data
,Query
,Index
,Search
(??Create Search Index)
Limit
- Columnar, Analytics and Eventing modules are not available
Migrate
From MongoDB
Justification
- https://cloud.tencent.com/developer/article/1916593
- Latency: CouchBase 的所有键值数据检索和处理操作都发生在内存中,从而产生亚毫秒的性能。
- All Node Active:所有节点都直接执行查询和写入
- MongoDB 的体系结构专注于单节点设置,许多重要功能(如通过 $lookup 函数连接或分组)在多节点和partition配置上表现不佳
- https://www.mongodb.com/docs/atlas/device-sdks/deprecation/#std-label-device-sdks-deprecation
- https://www.mongodb.com/docs/atlas/app-services/data-api/data-api-deprecation/?msockid=2ce6a8ea7d296bdd16b2bd657c196a2b
cli cbmigrate
Limit
- Date and decimal types in MongoDB are converted to strings in Couchbase.
- Date string is in RFC3339 format.
- wildcard and indexes with collation are currently not supported.?
- Compound index involving arrays and objects require specific syntax adaptations.
- When migrating data from MongoDB time series collections,
cbmigrate
imports data based on the output of the find method.- This means the data is imported in its raw form, rather than the optimized bucket format MongoDB uses internally for performance.
From Oracle
From memcached
Strategies for Replacing a Memcached Tier with Couchbase Server cluster