When is it adviced to put documents in a different bucket?

When is it preferred to separed docs in 2 buckets instead of putting everything on a single bucket?
Won’t getting docs become always slower with the increasing number of docs?

At least if you separate them the search pool is smaller, or it won’t make much difference?

Buckets essentially provide three containment levels:

  1. A namespace: no two documents can have the same name in a bucket.
  2. Resource allocation: cluster memory is allocated and prioritization is done on a per-bucket basis.
  3. Authentication/authorization: buckets can be password protected

Generally speaking, you’ll have one bucket per application, but there are situations where people have one bucket for user profiles and one bucket for individual application backed data.


Thanks a lot Ingenthr!
Leaving outside the fact about RAM document caching, there is not much performance gain in keeping the bucket smaller by moving some docs in another bucket?

Not much for small numbers of buckets. There are some resources related to replication and so forth that are allocated per bucket. This can lead to resource contention in some cases which is why even as of this writing, there are some documented limitations on number of buckets. Most of that is related to the minimum system configuration.