Sha256: e21eb5187b916dffb87864ccfe6c091bc7dcef73eb1ab42171d2551a7e018ee5

Contents?: true

Size: 1.29 KB

Versions: 32

Compression:

Stored size: 1.29 KB

Contents

CREATE TABLE IF NOT EXISTS shards (
    class_name              VARCHAR(125) NOT NULL,
    table_prefix            VARCHAR(125) NOT NULL,
    hostname                VARCHAR(25)  NOT NULL,
    source_type             VARCHAR(125),
    destination_type        VARCHAR(125),
    busy                    TINYINT      NOT NULL DEFAULT 0,

   PRIMARY KEY primary_key_table_prefix_hostname (hostname, table_prefix)
) ENGINE=INNODB;

CREATE TABLE IF NOT EXISTS shard_children (
    parent_hostname         VARCHAR(125) NOT NULL,
    parent_table_prefix     VARCHAR(125) NOT NULL,
    child_hostname          VARCHAR(125) NOT NULL,
    child_table_prefix      VARCHAR(125) NOT NULL,
    weight                  INT NOT NULL DEFAULT 1,

    PRIMARY KEY primary_key_family (parent_hostname, parent_table_prefix, child_hostname, child_table_prefix),
    INDEX child (child_hostname, child_table_prefix)
) ENGINE=INNODB;

CREATE TABLE IF NOT EXISTS forwardings (
    base_source_id          BIGINT                  NOT NULL,
    table_id                INT                     NOT NULL,
    shard_hostname          VARCHAR(125)            NOT NULL,
    shard_table_prefix      VARCHAR(125)            NOT NULL,

    PRIMARY KEY (base_source_id, table_id),

    UNIQUE unique_shard (shard_hostname, shard_table_prefix)
) ENGINE=INNODB;

Version data entries

32 entries across 32 versions & 1 rubygems

Version Path
gizzmo-0.13.1 test/recreate.sql
gizzmo-0.13.0 test/recreate.sql
gizzmo-0.12.1 test/recreate.sql
gizzmo-0.12.0 test/recreate.sql
gizzmo-0.11.4 test/recreate.sql
gizzmo-0.11.3 test/recreate.sql
gizzmo-0.11.2 test/recreate.sql
gizzmo-0.11.1 test/recreate.sql
gizzmo-0.11.0 test/recreate.sql
gizzmo-0.10.1 test/recreate.sql
gizzmo-0.10.0 test/recreate.sql
gizzmo-0.9.0 test/recreate.sql
gizzmo-0.8.3 test/recreate.sql
gizzmo-0.8.2 test/recreate.sql
gizzmo-0.8.1 test/recreate.sql
gizzmo-0.8.0 test/recreate.sql
gizzmo-0.7.5 test/recreate.sql
gizzmo-0.7.4 test/recreate.sql
gizzmo-0.7.0 test/recreate.sql
gizzmo-0.6.0 test/recreate.sql