Gate

The gate is the heart of the PartitionDB configuration. The Gate can serve as a regular database, but its main uses are:

Administrate the partitions

Partitioning a database is feasible by using the Gate. Once the Gate is configured, and a partition column is assigned, the Gate is responsible to propagate every insert, update or delete query to the partitions. The Gate is passing the query to the partition databases based on the partition ID. This mechanism improves the database performance by far.

Manage tables

All tables that are created and published have a view at the Gate. Any change to the table data or schema, will be done at the Gate, so there is no need to access the partition databases one by one. A table is replicated to the partitions contains no data at the Gate. A table that is not replicated to the children databases stores its data at the Gate.

Update objects

Once you create an object, the Gate will replicate if for you to the partitions (unless you chose otherwise). The Gate will manage the object, and make sure to access the object on the correct partition. Note that all objects are being replicated to the partitions upon creation by default, except tables, stored procedures and functions.

Serve as a sandbox

Any temporary objects, or objects that you are not interested to replicate to the partitions, can be created and managed here, at the Gate.

Gate’s attributes

When you create your database or go through the migration process, you have to set the Gate’s attributes. Some of them can be set once and cannot be changed, while others can change at any time. Some of the attributes are: Gate’s name, partition column, is the database a union and more. To learn more read here.