(1.0ms) CREATE TABLE "schema_migrations" ("version" varchar(255) NOT NULL)   (1.3ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version") ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations" Migrating to CreateSwitchmanShards (20130328212039)  (0.0ms) begin transaction  (0.4ms) CREATE TABLE "switchman_shards" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar(255), "database_server_id" varchar(255), "default" boolean DEFAULT 'f' NOT NULL)  SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20130328212039"]]  (0.8ms) commit transaction Migrating to CreateDefaultShard (20130328224244)  (0.1ms) begin transaction Switchman::Shard Exists (0.1ms) SELECT 1 AS one FROM "switchman_shards" WHERE "switchman_shards"."default" = 't' LIMIT 1 SQL (0.3ms) INSERT INTO "switchman_shards" ("default") VALUES (?) [["default", true]] Switchman::Shard Load (0.1ms) SELECT "switchman_shards".* FROM "switchman_shards" WHERE "switchman_shards"."default" = 't' LIMIT 1  (0.2ms) begin transaction [shard 1 deploy] SQL (5023.8ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20130328224244"]] [shard 1 deploy] SQLite3::BusyException: database is locked: INSERT INTO "schema_migrations" ("version") VALUES (?)  (0.1ms) rollback transaction [shard 1 deploy]  (6.5ms) rollback transaction  (1.3ms) SELECT * FROM unnest(current_schemas(false)) PG::UndefinedTable: ERROR: relation "switchman_shards" does not exist LINE 5: WHERE a.attrelid = '"switchman_shards"'::regc... ^ : SELECT a.attname, format_type(a.atttypid, a.atttypmod), pg_get_expr(d.adbin, d.adrelid), a.attnotnull, a.atttypid, a.atttypmod FROM pg_attribute a LEFT JOIN pg_attrdef d ON a.attrelid = d.adrelid AND a.attnum = d.adnum WHERE a.attrelid = '"switchman_shards"'::regclass AND a.attnum > 0 AND NOT a.attisdropped ORDER BY a.attnum  (2.0ms) CREATE TABLE "schema_migrations" ("version" character varying(255) NOT NULL)  (1.2ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version") ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations" Migrating to CreateSwitchmanShards (20130328212039)  (0.1ms) BEGIN  (3.7ms) CREATE TABLE "switchman_shards" ("id" bigserial primary key, "name" character varying(255), "database_server_id" character varying(255), "default" boolean DEFAULT 'f' NOT NULL) SQL (0.5ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20130328212039"]]  (0.4ms) COMMIT Migrating to CreateDefaultShard (20130328224244)  (0.3ms) BEGIN Switchman::Shard Exists (0.5ms) SELECT 1 AS one FROM "switchman_shards" WHERE "switchman_shards"."default" = 't' LIMIT 1 SQL (0.5ms) INSERT INTO "switchman_shards" ("default") VALUES ($1) RETURNING "id" [["default", true]] Switchman::Shard Load (0.2ms) SELECT "switchman_shards".* FROM "switchman_shards" WHERE "switchman_shards"."default" = 't' LIMIT 1 SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20130328224244"]]  (0.3ms) COMMIT Migrating to CreateUsers (20130403132607)  (0.1ms) BEGIN  (1.8ms) CREATE TABLE "users" ("id" bigserial primary key, "name" character varying(255), "mirror_user_id" bigint, "created_at" timestamp, "updated_at" timestamp) SQL (0.1ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20130403132607"]]  (0.4ms) COMMIT Migrating to CreateAppendages (20130411202442)  (0.1ms) BEGIN  (1.7ms) CREATE TABLE "appendages" ("id" bigserial primary key, "user_id" bigint, "value" integer, "created_at" timestamp, "updated_at" timestamp) SQL (0.1ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20130411202442"]]  (0.4ms) COMMIT Migrating to CreateMirrorUsers (20130411202551)  (0.1ms) BEGIN  (1.6ms) CREATE TABLE "mirror_users" ("id" bigserial primary key, "user_id" bigint, "created_at" timestamp, "updated_at" timestamp) SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20130411202551"]]  (0.3ms) COMMIT Migrating to CreateDigits (20131022202028)  (0.1ms) BEGIN  (1.6ms) CREATE TABLE "digits" ("id" bigserial primary key, "appendage_id" bigint, "value" integer, "created_at" timestamp, "updated_at" timestamp) SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20131022202028"]]  (0.3ms) COMMIT Migrating to CreateFeatures (20131206172923)  (0.1ms) BEGIN  (1.9ms) CREATE TABLE "features" ("id" bigserial primary key, "owner_id" bigint, "owner_type" character varying(255), "value" integer, "created_at" timestamp, "updated_at" timestamp) SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20131206172923"]]  (0.3ms) COMMIT Migrating to AddParentIdToUsers (20140123154135)  (0.1ms) BEGIN  (0.2ms) ALTER TABLE "users" ADD COLUMN "parent_id" bigint SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20140123154135"]]  (0.3ms) COMMIT Migrating to CreateRoots (20140219183820)  (0.1ms) BEGIN  (1.7ms) CREATE TABLE "roots" ("id" bigserial primary key, "user_id" bigint, "created_at" timestamp, "updated_at" timestamp) SQL (0.4ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20140219183820"]]  (0.4ms) COMMIT ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations"  (1.0ms) SELECT * FROM unnest(current_schemas(false)) Switchman::Shard Load (0.3ms) SELECT "switchman_shards".* FROM "switchman_shards" WHERE "switchman_shards"."default" = 't' LIMIT 1  (0.2ms) SELECT * FROM unnest(current_schemas(false)) Switchman::Shard Load (0.7ms) SELECT "switchman_shards".* FROM "switchman_shards" WHERE "switchman_shards"."database_server_id" = 'test' AND "switchman_shards"."name" IS NULL ORDER BY "switchman_shards"."id" ASC LIMIT 1 Switchman::Shard Load (0.4ms) SELECT "switchman_shards".* FROM "switchman_shards" WHERE "switchman_shards"."database_server_id" = 'production' AND "switchman_shards"."name" IS NULL ORDER BY "switchman_shards"."id" ASC LIMIT 1  (0.7ms) SELECT COUNT(*) FROM "users" [shard 1 master]