Company
Date Published
Author
Johan Larson
Word count
1744
Language
English
Hacker News points
None

Summary

In Couchbase 6.5, collections and scopes provide a new way to organize documents within a bucket, similar to tables in relational databases. Collections are the lowest level of document organization and directly contain documents. They allow grouping documents more precisely than before, enabling queries against specific collections instead of just the entire bucket. Scopes contain collections and collections contain documents, with different use cases depending on the Couchbase cluster configuration. The current version provides a Developer Preview feature, allowing developers to start working with collections and scopes right away. N1QL queries cannot currently work against collections in 6.5, but this will change in 7.0, enabling queries that span multiple scopes. The design allows for separating large or frequently changing data from user documents, improving the scalability and maintainability of applications.