Databases
reference: |
Fauna implements a new architecture that differs from other databases you might be familiar with. A database is a logical construct for grouping other documents. There is no notion of resource provisioning or warmup wait interval. When you create a database, the result is instantaneous. More importantly, there is no limit to the number of databases you can create.
Database structure
A database is a logical grouping of documents. A database can have a schema definition document that describes the database structure. These include collections, functions, child databases, and user-created documents.
Databases exist in the system-global root database context. Other than keys, all other documents exist in the context of a database.
Databases have immutable history in that you can’t insert events with timestamps in the past. This means that after a database is deleted, it can’t be resurrected.
Field | Type | Definition and Requirements |
---|---|---|
|
Name of the database. |
|
|
A read-only string that provides a unique global identifier for this database. |
|
|
(Optional) A JSON object with metadata about this database. |
Operational constraints
Queries are limited to a single database and can’t span databases.
You can rename a database by updating its name
field. Renaming a
database changes its reference but preserves inbound references to the
database. Data in a renamed database remains accessible using existing
keys.
When a database is deleted, its associated data becomes inaccessible and is deleted asynchronously.
Is this article helpful?
Tell Fauna how the article can be improved:
Visit Fauna's forums
or email docs@fauna.com
Thank you for your feedback!