Specifying entity properties for the database schema
In order to generate a database schema that will be mapped to a database, a few tasks are required. When none of these actions are taken, nothing happens when you attempt to create the database schema.
1. In the Vocabulary editor, select the menu toggle Vocabulary > Show Vocabulary Details.
2. Click on each entity that will be included in the database schema, to do the following:
Set entity Database Persistence - Click on the Database Persistent Property Value dropdown menu, and choose Yes, as shown:
Figure 312. Setting an entity to be database persistent
The entity and all its attributes now display their icon with a database decoration.
Set Entity Identity - Considering Identity strategies, if you want to use an Application Identity, you will choose an attribute in the entity that you can enforce as unique, and then click on its Entity Identity Property Value dropdown menu, and choose from the listed attributes, as shown:
Figure 313. Setting an entity's identity
The selected attribute is now at the top of the listed attributes and marked with an asterisk (*). It will be the primary key (PK) in the generated table.
Set Datastore Caching - (optional) The caching option is a level 2 cache that applies to specific settings in Rulesheets that - together with this entity property value, and enablement on a Ruletest or deployed Decision Service - provides caching of values that would be repeatedly accessed in the datastore. The setting here will apply to all use cases of caching on this entity.
Figure 314. Setting an entity's datastore caching preference
The Datastore Caching options are:
No Cache or blank (default) - Disable caching.
Read Only - Caches data that is never updated.
Read/Write - Caches data that is sometimes updated while maintaining the semantics of "read committed" isolation level. If the database is set to "repeatable read," this concurrency strategy almost maintains the semantics. Repeatable read isolation is compromised in the case of concurrent writes.
Nonstrict Read/Write - Caches data that is sometimes updated without ever locking the cache. If concurrent access to an item is possible, this concurrency strategy makes no guarantee that the item returned from the cache is the latest version available in the database.