Durable storage tips and FAQs

How much storage am I permitted to use?

Storage capacity on the Cloud varies per tier. See the Unison Cloud pricing page for details on the storage limits.

Unison Cloud tier options

How do schema migrations work?

Checkout our schema migrations FAQ doc which covers this in detail

Do not store credentials or other secret information in Cloud tables.

Values like secret keys or other credentials should be stored in the Cloud’s secure Environment.Config ability.

More about the Environment.Config ability

How do I model relational data since OrderedTable is a key-value store?

Unison Cloud’s OrderedTable is a key-value store, but you can model relational data by using compound keys and multiple tables.

Follow along with our OrderedTable schema modeling tutorial

Or write your own relational microblogging app with our learning lab

Prefer OrderedTable over Table in your applications.

Though its name is deceptively simple, Table is more of a building block for making other Cloud storage types than a user-facing concept. This is because there’s no way to get the data from a table after you’ve written to it unless you’ve kept track of the keys in a separate data structure somewhere else. Compare this with the OrderedTable cloud storage type, which provides functions like OrderedTable.toStream.keys, for easy retrieval of table data. Unless you are building other Cloud data structures, you probably want OrderedTable for your business logic.

Watch our Cloud storage deep dive video

Transactions should be small!

Transactions offer us the ability to keep data in sync across a database, but there are limitations to the amount of data that can be transactionally updated at once. This is an instance where we must bend to our infrastructure overlords, alas! The precise limit is somewhat challenging to calculate based on the existing set of Cloud storage functions, as it’s based on three opaque things:

  • The number of records that can be updated in a single transaction (100 records in total)
  • The maximum size of each record (400kb)
  • And the aggregate amount of data being transactionally updated (4MB)

Why is this hard to determine? While you may think that you’re moving less than 100 records at a time, your Cloud storage data structure might be modifying some information about the structure of your data behind the scenes as part of the update. Additionally, the size of your records is challenging to calculate because it includes the size of the serialized dependencies of the data. Neither of these is easily calculable before the transaction is run, therefore, it is important to keep transactions small.

Learn more about OrderedTable via the API docs