Files
redux-scraper/db/schema.rb
2024-12-25 21:53:47 +00:00

1818 lines
72 KiB
Ruby
Generated

# This file is auto-generated from the current state of the database. Instead
# of editing this file, please use the migrations feature of Active Record to
# incrementally modify your database, and then regenerate this schema definition.
#
# This file is the source Rails uses to define your schema when running `bin/rails
# db:schema:load`. When creating a new database, `bin/rails db:schema:load` tends to
# be faster and is potentially less error prone than running all of your
# migrations from scratch. Old migrations may fail to apply correctly if those
# migrations use external dependencies or application code.
#
# It's strongly recommended that you check this file into your version control system.
ActiveRecord::Schema[7.2].define(version: 2024_12_25_183955) do
# These are extensions that must be enabled in order to support this database
enable_extension "pg_prewarm"
enable_extension "pg_stat_statements"
enable_extension "pg_trgm"
enable_extension "pgcrypto"
enable_extension "plpgsql"
enable_extension "vector"
# Custom types defined in this database.
# Note that some types may not work with other database engines. Be careful if changing database.
create_enum "postable_type", ["Domain::Fa::Post", "Domain::E621::Post", "Domain::Inkbunny::Post"]
create_table "blob_entries_p", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_on_sha256", unique: true
end
create_table "blob_entries_p_00", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_00_on_sha256", unique: true
end
create_table "blob_entries_p_01", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_01_on_sha256", unique: true
end
create_table "blob_entries_p_02", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_02_on_sha256", unique: true
end
create_table "blob_entries_p_03", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_03_on_sha256", unique: true
end
create_table "blob_entries_p_04", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_04_on_sha256", unique: true
end
create_table "blob_entries_p_05", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_05_on_sha256", unique: true
end
create_table "blob_entries_p_06", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_06_on_sha256", unique: true
end
create_table "blob_entries_p_07", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_07_on_sha256", unique: true
end
create_table "blob_entries_p_08", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_08_on_sha256", unique: true
end
create_table "blob_entries_p_09", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_09_on_sha256", unique: true
end
create_table "blob_entries_p_10", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_10_on_sha256", unique: true
end
create_table "blob_entries_p_11", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_11_on_sha256", unique: true
end
create_table "blob_entries_p_12", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_12_on_sha256", unique: true
end
create_table "blob_entries_p_13", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_13_on_sha256", unique: true
end
create_table "blob_entries_p_14", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_14_on_sha256", unique: true
end
create_table "blob_entries_p_15", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_15_on_sha256", unique: true
end
create_table "blob_entries_p_16", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_16_on_sha256", unique: true
end
create_table "blob_entries_p_17", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_17_on_sha256", unique: true
end
create_table "blob_entries_p_18", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_18_on_sha256", unique: true
end
create_table "blob_entries_p_19", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_19_on_sha256", unique: true
end
create_table "blob_entries_p_20", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_20_on_sha256", unique: true
end
create_table "blob_entries_p_21", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_21_on_sha256", unique: true
end
create_table "blob_entries_p_22", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_22_on_sha256", unique: true
end
create_table "blob_entries_p_23", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_23_on_sha256", unique: true
end
create_table "blob_entries_p_24", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_24_on_sha256", unique: true
end
create_table "blob_entries_p_25", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_25_on_sha256", unique: true
end
create_table "blob_entries_p_26", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_26_on_sha256", unique: true
end
create_table "blob_entries_p_27", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_27_on_sha256", unique: true
end
create_table "blob_entries_p_28", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_28_on_sha256", unique: true
end
create_table "blob_entries_p_29", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_29_on_sha256", unique: true
end
create_table "blob_entries_p_30", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_30_on_sha256", unique: true
end
create_table "blob_entries_p_31", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_31_on_sha256", unique: true
end
create_table "blob_entries_p_32", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_32_on_sha256", unique: true
end
create_table "blob_entries_p_33", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_33_on_sha256", unique: true
end
create_table "blob_entries_p_34", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_34_on_sha256", unique: true
end
create_table "blob_entries_p_35", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_35_on_sha256", unique: true
end
create_table "blob_entries_p_36", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_36_on_sha256", unique: true
end
create_table "blob_entries_p_37", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_37_on_sha256", unique: true
end
create_table "blob_entries_p_38", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_38_on_sha256", unique: true
end
create_table "blob_entries_p_39", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_39_on_sha256", unique: true
end
create_table "blob_entries_p_40", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_40_on_sha256", unique: true
end
create_table "blob_entries_p_41", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_41_on_sha256", unique: true
end
create_table "blob_entries_p_42", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_42_on_sha256", unique: true
end
create_table "blob_entries_p_43", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_43_on_sha256", unique: true
end
create_table "blob_entries_p_44", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_44_on_sha256", unique: true
end
create_table "blob_entries_p_45", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_45_on_sha256", unique: true
end
create_table "blob_entries_p_46", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_46_on_sha256", unique: true
end
create_table "blob_entries_p_47", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_47_on_sha256", unique: true
end
create_table "blob_entries_p_48", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_48_on_sha256", unique: true
end
create_table "blob_entries_p_49", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_49_on_sha256", unique: true
end
create_table "blob_entries_p_50", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_50_on_sha256", unique: true
end
create_table "blob_entries_p_51", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_51_on_sha256", unique: true
end
create_table "blob_entries_p_52", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_52_on_sha256", unique: true
end
create_table "blob_entries_p_53", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_53_on_sha256", unique: true
end
create_table "blob_entries_p_54", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_54_on_sha256", unique: true
end
create_table "blob_entries_p_55", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_55_on_sha256", unique: true
end
create_table "blob_entries_p_56", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_56_on_sha256", unique: true
end
create_table "blob_entries_p_57", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_57_on_sha256", unique: true
end
create_table "blob_entries_p_58", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_58_on_sha256", unique: true
end
create_table "blob_entries_p_59", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_59_on_sha256", unique: true
end
create_table "blob_entries_p_60", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_60_on_sha256", unique: true
end
create_table "blob_entries_p_61", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_61_on_sha256", unique: true
end
create_table "blob_entries_p_62", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_62_on_sha256", unique: true
end
create_table "blob_entries_p_63", primary_key: "sha256", id: :binary, force: :cascade do |t|
t.binary "base_sha256"
t.string "content_type", null: false
t.integer "size", null: false
t.binary "contents", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_entries_p_63_on_sha256", unique: true
end
create_table "blob_files", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_on_sha256", unique: true
end
create_table "blob_files_00", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_00_on_sha256", unique: true
end
create_table "blob_files_01", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_01_on_sha256", unique: true
end
create_table "blob_files_02", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_02_on_sha256", unique: true
end
create_table "blob_files_03", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_03_on_sha256", unique: true
end
create_table "blob_files_04", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_04_on_sha256", unique: true
end
create_table "blob_files_05", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_05_on_sha256", unique: true
end
create_table "blob_files_06", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_06_on_sha256", unique: true
end
create_table "blob_files_07", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_07_on_sha256", unique: true
end
create_table "blob_files_08", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_08_on_sha256", unique: true
end
create_table "blob_files_09", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_09_on_sha256", unique: true
end
create_table "blob_files_10", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_10_on_sha256", unique: true
end
create_table "blob_files_11", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_11_on_sha256", unique: true
end
create_table "blob_files_12", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_12_on_sha256", unique: true
end
create_table "blob_files_13", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_13_on_sha256", unique: true
end
create_table "blob_files_14", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_14_on_sha256", unique: true
end
create_table "blob_files_15", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_15_on_sha256", unique: true
end
create_table "blob_files_16", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_16_on_sha256", unique: true
end
create_table "blob_files_17", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_17_on_sha256", unique: true
end
create_table "blob_files_18", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_18_on_sha256", unique: true
end
create_table "blob_files_19", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_19_on_sha256", unique: true
end
create_table "blob_files_20", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_20_on_sha256", unique: true
end
create_table "blob_files_21", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_21_on_sha256", unique: true
end
create_table "blob_files_22", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_22_on_sha256", unique: true
end
create_table "blob_files_23", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_23_on_sha256", unique: true
end
create_table "blob_files_24", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_24_on_sha256", unique: true
end
create_table "blob_files_25", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_25_on_sha256", unique: true
end
create_table "blob_files_26", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_26_on_sha256", unique: true
end
create_table "blob_files_27", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_27_on_sha256", unique: true
end
create_table "blob_files_28", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_28_on_sha256", unique: true
end
create_table "blob_files_29", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_29_on_sha256", unique: true
end
create_table "blob_files_30", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_30_on_sha256", unique: true
end
create_table "blob_files_31", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_31_on_sha256", unique: true
end
create_table "blob_files_32", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_32_on_sha256", unique: true
end
create_table "blob_files_33", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_33_on_sha256", unique: true
end
create_table "blob_files_34", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_34_on_sha256", unique: true
end
create_table "blob_files_35", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_35_on_sha256", unique: true
end
create_table "blob_files_36", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_36_on_sha256", unique: true
end
create_table "blob_files_37", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_37_on_sha256", unique: true
end
create_table "blob_files_38", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_38_on_sha256", unique: true
end
create_table "blob_files_39", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_39_on_sha256", unique: true
end
create_table "blob_files_40", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_40_on_sha256", unique: true
end
create_table "blob_files_41", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_41_on_sha256", unique: true
end
create_table "blob_files_42", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_42_on_sha256", unique: true
end
create_table "blob_files_43", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_43_on_sha256", unique: true
end
create_table "blob_files_44", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_44_on_sha256", unique: true
end
create_table "blob_files_45", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_45_on_sha256", unique: true
end
create_table "blob_files_46", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_46_on_sha256", unique: true
end
create_table "blob_files_47", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_47_on_sha256", unique: true
end
create_table "blob_files_48", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_48_on_sha256", unique: true
end
create_table "blob_files_49", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_49_on_sha256", unique: true
end
create_table "blob_files_50", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_50_on_sha256", unique: true
end
create_table "blob_files_51", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_51_on_sha256", unique: true
end
create_table "blob_files_52", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_52_on_sha256", unique: true
end
create_table "blob_files_53", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_53_on_sha256", unique: true
end
create_table "blob_files_54", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_54_on_sha256", unique: true
end
create_table "blob_files_55", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_55_on_sha256", unique: true
end
create_table "blob_files_56", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_56_on_sha256", unique: true
end
create_table "blob_files_57", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_57_on_sha256", unique: true
end
create_table "blob_files_58", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_58_on_sha256", unique: true
end
create_table "blob_files_59", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_59_on_sha256", unique: true
end
create_table "blob_files_60", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_60_on_sha256", unique: true
end
create_table "blob_files_61", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_61_on_sha256", unique: true
end
create_table "blob_files_62", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_62_on_sha256", unique: true
end
create_table "blob_files_63", id: false, force: :cascade do |t|
t.binary "sha256", null: false
t.integer "version", null: false
t.jsonb "metadata", default: {}, null: false
t.string "content_type", null: false
t.integer "size_bytes", null: false
t.datetime "created_at", null: false
t.index ["sha256"], name: "index_blob_files_63_on_sha256", unique: true
end
create_table "delayed_jobs", force: :cascade do |t|
t.integer "priority", default: 0, null: false
t.integer "attempts", default: 0, null: false
t.text "handler", null: false
t.text "last_error"
t.datetime "run_at"
t.datetime "locked_at"
t.datetime "failed_at"
t.string "locked_by"
t.string "queue"
t.datetime "created_at"
t.datetime "updated_at"
t.string "signature"
t.jsonb "args"
t.index ["priority", "run_at"], name: "delayed_jobs_priority_run_at_idx"
t.index ["queue"], name: "delayed_jobs_queue_idx"
t.index ["signature"], name: "delayed_jobs_signature_idx", unique: true
end
create_table "domain_e621_post_versions", force: :cascade do |t|
t.bigint "item_id"
t.integer "schema_version"
t.string "event", null: false
t.jsonb "diff"
t.datetime "created_at", null: false
t.index ["item_id"], name: "index_domain_e621_post_versions_on_item_id"
end
create_table "domain_e621_posts", force: :cascade do |t|
t.integer "e621_id", null: false
t.integer "state", null: false
t.jsonb "state_detail"
t.string "md5"
t.string "file_url_str"
t.string "description"
t.integer "rating"
t.integer "score"
t.integer "score_up"
t.integer "score_down"
t.integer "num_favorites"
t.integer "num_comments"
t.integer "change_seq"
t.jsonb "flags_array"
t.jsonb "pools_array"
t.jsonb "sources_array"
t.jsonb "artists_array"
t.jsonb "tags_array"
t.bigint "file_id"
t.bigint "parent_e621_id"
t.datetime "deleted_at"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.datetime "posted_at"
t.index ["e621_id"], name: "index_domain_e621_posts_on_e621_id", unique: true
t.index ["file_id"], name: "index_domain_e621_posts_on_file_id"
t.index ["md5"], name: "index_domain_e621_posts_on_md5", unique: true, where: "(deleted_at IS NULL)"
t.index ["parent_e621_id"], name: "index_domain_e621_posts_on_parent_e621_id"
end
create_table "domain_e621_taggings", id: false, force: :cascade do |t|
t.integer "category"
t.bigint "post_id", null: false
t.bigint "tag_id", null: false
t.index ["post_id", "tag_id"], name: "index_domain_e621_taggings_on_post_id_and_tag_id", unique: true
end
create_table "domain_e621_tags", force: :cascade do |t|
t.string "name", null: false
t.integer "type"
t.string "description"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["name"], name: "index_domain_e621_tags_on_name", unique: true
end
create_table "domain_fa_favs", id: false, force: :cascade do |t|
t.bigint "user_id", null: false
t.bigint "post_id", null: false
t.index ["user_id", "post_id"], name: "index_domain_fa_favs_on_user_id_and_post_id", unique: true
t.index ["user_id"], name: "index_domain_fa_favs_on_user_id"
end
create_table "domain_fa_follows", id: false, force: :cascade do |t|
t.bigint "follower_id", null: false
t.bigint "followed_id", null: false
t.index ["followed_id", "follower_id"], name: "index_domain_fa_follows_on_followed_id_and_follower_id"
t.index ["follower_id", "followed_id"], name: "index_domain_fa_follows_on_follower_id_and_followed_id", unique: true
end
create_table "domain_fa_post_factors", force: :cascade do |t|
t.bigint "post_id", null: false
t.vector "for_favorite", limit: 32
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["for_favorite"], name: "index_domain_fa_post_factors_on_for_favorite", using: :ivfflat
t.index ["post_id"], name: "index_domain_fa_post_factors_on_post_id", unique: true
end
create_table "domain_fa_posts", force: :cascade do |t|
t.integer "fa_id"
t.bigint "creator_id"
t.string "title"
t.string "category"
t.string "theme"
t.string "species"
t.string "gender"
t.string "description"
t.jsonb "keywords"
t.integer "num_favorites"
t.integer "num_comments"
t.integer "num_views"
t.datetime "posted_at"
t.string "file_url_str"
t.bigint "file_id"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.integer "state"
t.jsonb "state_detail"
t.jsonb "log_entry_detail"
t.index ["creator_id"], name: "index_domain_fa_posts_on_creator_id"
t.index ["fa_id"], name: "index_domain_fa_posts_on_fa_id", unique: true, include: ["id"]
t.index ["file_id"], name: "index_domain_fa_posts_on_file_id"
end
create_table "domain_fa_user_avatar_versions", force: :cascade do |t|
t.bigint "item_id"
t.integer "schema_version"
t.string "event", null: false
t.jsonb "diff"
t.datetime "created_at", null: false
t.index ["item_id"], name: "index_domain_fa_user_avatar_versions_on_item_id"
end
create_table "domain_fa_user_avatars", force: :cascade do |t|
t.bigint "user_id", null: false
t.integer "state", null: false
t.jsonb "state_detail"
t.string "file_url_str"
t.bigint "log_entry_id"
t.binary "file_sha256"
t.datetime "downloaded_file_at"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["user_id"], name: "index_domain_fa_user_avatars_on_user_id", unique: true
end
create_table "domain_fa_user_factors", force: :cascade do |t|
t.bigint "user_id", null: false
t.vector "for_follower", limit: 32
t.vector "for_followed", limit: 32
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["for_followed"], name: "index_domain_fa_user_factors_on_for_followed", using: :ivfflat
t.index ["for_follower"], name: "index_domain_fa_user_factors_on_for_follower", using: :ivfflat
t.index ["user_id"], name: "index_domain_fa_user_factors_on_user_id", unique: true
end
create_table "domain_fa_users", force: :cascade do |t|
t.string "name", null: false
t.string "full_name"
t.string "url_name", null: false
t.string "artist_type"
t.string "mood"
t.string "profile_html"
t.integer "num_pageviews"
t.integer "num_submissions"
t.integer "num_comments_recieved"
t.integer "num_comments_given"
t.integer "num_journals"
t.integer "num_favorites"
t.datetime "scanned_gallery_at"
t.datetime "scanned_page_at"
t.datetime "registered_at"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.jsonb "log_entry_detail"
t.integer "state"
t.jsonb "state_detail"
t.datetime "scanned_follows_at"
t.datetime "scanned_favs_at"
t.index ["name"], name: "domain_fa_users_name_idx", opclass: :gist_trgm_ops, using: :gist
t.index ["name"], name: "index_domain_fa_users_on_name", unique: true
t.index ["url_name"], name: "domain_fa_users_url_name_idx", opclass: :gist_trgm_ops, using: :gist
t.index ["url_name"], name: "index_domain_fa_users_on_url_name", unique: true
end
create_table "domain_inkbunny_favs", id: false, force: :cascade do |t|
t.bigint "user_id", null: false
t.bigint "post_id", null: false
t.index ["post_id", "user_id"], name: "index_domain_inkbunny_favs_on_post_id_and_user_id"
t.index ["post_id"], name: "index_domain_inkbunny_favs_on_post_id"
t.index ["user_id", "post_id"], name: "index_domain_inkbunny_favs_on_user_id_and_post_id", unique: true
t.index ["user_id"], name: "index_domain_inkbunny_favs_on_user_id"
end
create_table "domain_inkbunny_files", force: :cascade do |t|
t.integer "state", null: false
t.jsonb "state_detail", default: {}, null: false
t.bigint "post_id", null: false
t.bigint "log_entry_id"
t.binary "blob_entry_sha256"
t.integer "file_order", null: false
t.bigint "ib_file_id"
t.jsonb "ib_detail_raw"
t.datetime "ib_created_at"
t.string "file_name"
t.string "url_str"
t.string "md5_initial"
t.string "md5_full"
t.jsonb "md5s"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["post_id", "file_order"], name: "index_domain_inkbunny_files_on_post_id_and_file_order"
end
create_table "domain_inkbunny_follows", id: false, force: :cascade do |t|
t.bigint "follower_id", null: false
t.bigint "followed_id", null: false
t.index ["followed_id", "follower_id"], name: "index_domain_inkbunny_follows_on_followed_id_and_follower_id"
t.index ["followed_id"], name: "index_domain_inkbunny_follows_on_followed_id"
t.index ["follower_id", "followed_id"], name: "index_domain_inkbunny_follows_on_follower_id_and_followed_id", unique: true
t.index ["follower_id"], name: "index_domain_inkbunny_follows_on_follower_id"
end
create_table "domain_inkbunny_global_states", force: :cascade do |t|
t.string "key", null: false
t.string "value"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
end
create_table "domain_inkbunny_pool_joins", force: :cascade do |t|
t.bigint "post_id", null: false
t.bigint "pool_id", null: false
t.integer "ordinal"
t.index ["pool_id"], name: "index_domain_inkbunny_pool_joins_on_pool_id"
t.index ["post_id"], name: "index_domain_inkbunny_pool_joins_on_post_id"
end
create_table "domain_inkbunny_pools", force: :cascade do |t|
t.string "name"
t.string "description"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
end
create_table "domain_inkbunny_posts", force: :cascade do |t|
t.integer "state", null: false
t.jsonb "state_detail"
t.datetime "shallow_updated_at"
t.datetime "deep_updated_at"
t.bigint "creator_id"
t.bigint "ib_post_id"
t.string "title"
t.string "description"
t.string "writing"
t.datetime "posted_at", precision: nil
t.datetime "last_file_updated_at", precision: nil
t.integer "rating"
t.integer "submission_type"
t.integer "num_views"
t.integer "num_files"
t.jsonb "ib_detail_raw"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["creator_id"], name: "index_domain_inkbunny_posts_on_creator_id"
end
create_table "domain_inkbunny_taggings", force: :cascade do |t|
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
end
create_table "domain_inkbunny_tags", force: :cascade do |t|
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
end
create_table "domain_inkbunny_user_avatars", force: :cascade do |t|
t.bigint "user_id", null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["user_id"], name: "index_domain_inkbunny_user_avatars_on_user_id"
end
create_table "domain_inkbunny_users", force: :cascade do |t|
t.integer "state", null: false
t.json "state_detail"
t.string "name", null: false
t.bigint "ib_user_id", null: false
t.string "avatar_url_str"
t.binary "avatar_file_sha256"
t.bigint "avatar_file_log_entry_id"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["ib_user_id"], name: "index_domain_inkbunny_users_on_ib_user_id", unique: true
end
create_table "domain_twitter_medias", id: false, force: :cascade do |t|
t.string "id", null: false
t.integer "state"
t.json "state_detail"
t.json "raw_data"
t.string "url_str"
t.bigint "tweet_id", null: false
t.bigint "file_id"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["file_id"], name: "index_domain_twitter_medias_on_file_id"
t.index ["id"], name: "index_domain_twitter_medias_on_id", unique: true
t.index ["tweet_id"], name: "index_domain_twitter_medias_on_tweet_id"
end
create_table "domain_twitter_tweets", force: :cascade do |t|
t.integer "state"
t.json "state_detail"
t.json "raw_data"
t.bigint "author_id"
t.string "content"
t.bigint "reply_to_tweet_id"
t.datetime "tweeted_at", precision: nil
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["author_id"], name: "index_domain_twitter_tweets_on_author_id"
t.index ["reply_to_tweet_id"], name: "index_domain_twitter_tweets_on_reply_to_tweet_id"
end
create_table "domain_twitter_user_versions", force: :cascade do |t|
t.bigint "item_id"
t.integer "schema_version"
t.string "event", null: false
t.jsonb "diff"
t.datetime "created_at", null: false
t.index ["item_id"], name: "index_domain_twitter_user_versions_on_item_id"
end
create_table "domain_twitter_users", force: :cascade do |t|
t.integer "state"
t.json "state_detail"
t.json "raw_data"
t.string "name", null: false
t.string "nick"
t.string "description"
t.integer "num_fav_count"
t.integer "num_followers"
t.integer "num_following"
t.datetime "registered_at"
t.datetime "scanned_timeline_at"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.bigint "tw_id"
t.index ["name"], name: "index_domain_twitter_users_on_name", unique: true
t.index ["tw_id"], name: "index_domain_twitter_users_on_tw_id", unique: true
end
create_table "flat_sst_entries", id: false, force: :cascade do |t|
t.binary "key", null: false
t.binary "contents", null: false
t.index ["key"], name: "index_flat_sst_entries_on_key", unique: true
end
create_table "good_job_batches", id: :uuid, default: -> { "gen_random_uuid()" }, force: :cascade do |t|
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.text "description"
t.jsonb "serialized_properties"
t.text "on_finish"
t.text "on_success"
t.text "on_discard"
t.text "callback_queue_name"
t.integer "callback_priority"
t.datetime "enqueued_at"
t.datetime "discarded_at"
t.datetime "finished_at"
end
create_table "good_job_executions", id: :uuid, default: -> { "gen_random_uuid()" }, force: :cascade do |t|
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.uuid "active_job_id", null: false
t.text "job_class"
t.text "queue_name"
t.jsonb "serialized_params"
t.datetime "scheduled_at"
t.datetime "finished_at"
t.text "error"
t.integer "error_event", limit: 2
t.text "error_backtrace", array: true
t.uuid "process_id"
t.interval "duration"
t.index ["active_job_id", "created_at"], name: "index_good_job_executions_on_active_job_id_and_created_at"
t.index ["process_id", "created_at"], name: "index_good_job_executions_on_process_id_and_created_at"
end
create_table "good_job_processes", id: :uuid, default: -> { "gen_random_uuid()" }, force: :cascade do |t|
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.jsonb "state"
t.integer "lock_type", limit: 2
end
create_table "good_job_settings", id: :uuid, default: -> { "gen_random_uuid()" }, force: :cascade do |t|
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.text "key"
t.jsonb "value"
t.index ["key"], name: "index_good_job_settings_on_key", unique: true
end
create_table "good_jobs", id: :uuid, default: -> { "gen_random_uuid()" }, force: :cascade do |t|
t.text "queue_name"
t.integer "priority"
t.jsonb "serialized_params"
t.datetime "scheduled_at"
t.datetime "performed_at"
t.datetime "finished_at"
t.text "error"
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.uuid "active_job_id"
t.text "concurrency_key"
t.text "cron_key"
t.uuid "retried_good_job_id"
t.datetime "cron_at"
t.uuid "batch_id"
t.uuid "batch_callback_id"
t.boolean "is_discrete"
t.integer "executions_count"
t.text "job_class"
t.integer "error_event", limit: 2
t.text "labels", array: true
t.uuid "locked_by_id"
t.datetime "locked_at"
t.index ["active_job_id", "created_at"], name: "index_good_jobs_on_active_job_id_and_created_at"
t.index ["batch_callback_id"], name: "index_good_jobs_on_batch_callback_id", where: "(batch_callback_id IS NOT NULL)"
t.index ["batch_id"], name: "index_good_jobs_on_batch_id", where: "(batch_id IS NOT NULL)"
t.index ["concurrency_key"], name: "index_good_jobs_on_concurrency_key_when_unfinished", where: "(finished_at IS NULL)"
t.index ["cron_key", "created_at"], name: "index_good_jobs_on_cron_key_and_created_at_cond", where: "(cron_key IS NOT NULL)"
t.index ["cron_key", "cron_at"], name: "index_good_jobs_on_cron_key_and_cron_at_cond", unique: true, where: "(cron_key IS NOT NULL)"
t.index ["finished_at"], name: "index_good_jobs_jobs_on_finished_at", where: "((retried_good_job_id IS NULL) AND (finished_at IS NOT NULL))"
t.index ["labels"], name: "index_good_jobs_on_labels", where: "(labels IS NOT NULL)", using: :gin
t.index ["locked_by_id"], name: "index_good_jobs_on_locked_by_id", where: "(locked_by_id IS NOT NULL)"
t.index ["priority", "created_at"], name: "index_good_job_jobs_for_candidate_lookup", where: "(finished_at IS NULL)"
t.index ["priority", "created_at"], name: "index_good_jobs_jobs_on_priority_created_at_when_unfinished", order: { priority: "DESC NULLS LAST" }, where: "(finished_at IS NULL)"
t.index ["priority", "scheduled_at"], name: "index_good_jobs_on_priority_scheduled_at_unfinished_unlocked", where: "((finished_at IS NULL) AND (locked_by_id IS NULL))"
t.index ["queue_name", "scheduled_at"], name: "index_good_jobs_on_queue_name_and_scheduled_at", where: "(finished_at IS NULL)"
t.index ["scheduled_at"], name: "index_good_jobs_on_scheduled_at", where: "(finished_at IS NULL)"
end
create_table "http_log_entries", force: :cascade do |t|
t.string "uri_scheme", null: false
t.string "uri_host", null: false
t.string "uri_path", null: false
t.string "uri_query"
t.string "uri_hash"
t.integer "verb", null: false
t.bigint "request_headers_id", null: false
t.bigint "response_headers_id", null: false
t.integer "status_code", null: false
t.integer "response_time_ms", null: false
t.string "content_type", null: false
t.binary "response_sha256", null: false
t.datetime "requested_at", null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.bigint "caused_by_id"
t.integer "performed_by", null: false
t.index ["caused_by_id"], name: "index_http_log_entries_on_caused_by_id"
t.index ["request_headers_id"], name: "index_http_log_entries_on_request_headers_id"
t.index ["response_headers_id"], name: "index_http_log_entries_on_response_headers_id"
t.index ["response_sha256"], name: "index_http_log_entries_on_response_sha256", using: :hash
t.index ["uri_host", "uri_path", "uri_query"], name: "index_http_log_entries_on_uri_host_path_query"
end
create_table "http_log_entry_headers", force: :cascade do |t|
t.binary "sha256", null: false
t.jsonb "headers", null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.index ["sha256"], name: "index_http_log_entry_headers_on_sha256", unique: true
end
create_table "indexed_posts", force: :cascade do |t|
t.integer "postable_id", null: false
t.datetime "created_at", null: false
t.datetime "updated_at", null: false
t.enum "postable_type", null: false, enum_type: "postable_type"
t.index ["created_at"], name: "index_indexed_posts_on_created_at"
t.index ["postable_id", "postable_type"], name: "index_indexed_posts_on_postable_id_and_postable_type", unique: true
end
create_table "log_store_sst_entries", id: false, force: :cascade do |t|
t.binary "key", null: false
t.binary "value", null: false
t.binary "base_key"
t.binary "contents"
t.index ["key"], name: "index_log_store_sst_entries_on_key", unique: true
end
create_table "pghero_query_stats", force: :cascade do |t|
t.text "database"
t.text "user"
t.text "query"
t.bigint "query_hash"
t.float "total_time"
t.bigint "calls"
t.datetime "captured_at", precision: nil
t.index ["database", "captured_at"], name: "index_pghero_query_stats_on_database_and_captured_at"
end
create_table "pghero_space_stats", force: :cascade do |t|
t.text "database"
t.text "schema"
t.text "relation"
t.bigint "size"
t.datetime "captured_at", precision: nil
t.index ["database", "captured_at"], name: "index_pghero_space_stats_on_database_and_captured_at"
end
create_table "versions", force: :cascade do |t|
t.string "item_type", null: false
t.bigint "item_id", null: false
t.integer "schema_version", null: false
t.string "event", null: false
t.jsonb "diff"
t.datetime "created_at"
t.index ["item_type", "item_id"], name: "index_versions_on_item_type_and_item_id"
end
add_foreign_key "domain_e621_post_versions", "domain_e621_posts", column: "item_id"
add_foreign_key "domain_e621_taggings", "domain_e621_posts", column: "post_id"
add_foreign_key "domain_e621_taggings", "domain_e621_tags", column: "tag_id"
add_foreign_key "domain_fa_favs", "domain_fa_users", column: "user_id"
add_foreign_key "domain_fa_follows", "domain_fa_users", column: "followed_id"
add_foreign_key "domain_fa_follows", "domain_fa_users", column: "follower_id"
add_foreign_key "domain_fa_post_factors", "domain_fa_posts", column: "post_id"
add_foreign_key "domain_fa_posts", "domain_fa_users", column: "creator_id"
add_foreign_key "domain_fa_posts", "http_log_entries", column: "file_id"
add_foreign_key "domain_fa_user_avatar_versions", "domain_fa_user_avatars", column: "item_id"
add_foreign_key "domain_fa_user_avatars", "domain_fa_users", column: "user_id"
add_foreign_key "domain_fa_user_avatars", "http_log_entries", column: "log_entry_id"
add_foreign_key "domain_fa_user_factors", "domain_fa_users", column: "user_id"
add_foreign_key "domain_inkbunny_favs", "domain_inkbunny_posts", column: "post_id"
add_foreign_key "domain_inkbunny_favs", "domain_inkbunny_users", column: "user_id"
add_foreign_key "domain_inkbunny_files", "domain_inkbunny_posts", column: "post_id"
add_foreign_key "domain_inkbunny_follows", "domain_inkbunny_users", column: "followed_id"
add_foreign_key "domain_inkbunny_follows", "domain_inkbunny_users", column: "follower_id"
add_foreign_key "domain_inkbunny_pool_joins", "domain_inkbunny_pools", column: "pool_id"
add_foreign_key "domain_inkbunny_pool_joins", "domain_inkbunny_posts", column: "post_id"
add_foreign_key "domain_twitter_medias", "domain_twitter_tweets", column: "tweet_id"
add_foreign_key "domain_twitter_medias", "http_log_entries", column: "file_id"
add_foreign_key "domain_twitter_tweets", "domain_twitter_users", column: "author_id", primary_key: "tw_id", name: "on_author_id"
add_foreign_key "http_log_entries", "http_log_entries", column: "caused_by_id"
add_foreign_key "http_log_entries", "http_log_entry_headers", column: "request_headers_id"
add_foreign_key "http_log_entries", "http_log_entry_headers", column: "response_headers_id"
end