A Siaqodb Document represents a record within a Bucket; it has 4 main fields/properties:
- Key - unique identifier for a Document per Bucket, it should be explicitly provided.
- Content - the actual content of the document in JSON/BSON(or other format)
- Tags - collection of key-value pairs (secondary indexes);
- Version - this value is generated on server-side (see SiaqodbCloud) and is used for optimistic concurrency control.
Key is a String type that acts as unique identifier within a Bucket. For new Documents, client code must ensure the uniqueness of this value. There is no specific limitation of length of this field, but having small size Key value increase performance. Key values are indexed and stored ordered.
This field/property is stored internally in the format of the Serializer provided. Usually this should be a custom POCO object.
Tags is a collection of key-value pairs, its values being automatically indexed. There is no limitation for number of indexes.
Version is a String type and is this value is generated on server-side (see SiaqodbCloud) and it is used for optimistic concurrency control. Client code should never alter this value.