Skip to content

Commit

Permalink
Add new index
Browse files Browse the repository at this point in the history
  • Loading branch information
johnf committed Dec 2, 2024
1 parent 8f5f764 commit ad2322a
Show file tree
Hide file tree
Showing 7 changed files with 44 additions and 8 deletions.
2 changes: 2 additions & 0 deletions app/models/collection.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@
# * **`identifier`**
# * `index_collections_on_operator_id`:
# * **`operator_id`**
# * `index_collections_on_private`:
# * **`private`**
# * `index_collections_on_university_id`:
# * **`university_id`**
#
Expand Down
4 changes: 4 additions & 0 deletions app/models/item.rb
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,10 @@
# * **`access_condition_id`**
# * `index_items_on_collection_id`:
# * **`collection_id`**
# * `index_items_on_collection_id_and_private_and_updated_at`:
# * **`collection_id`**
# * **`private`**
# * **`updated_at`**
# * `index_items_on_collector_id`:
# * **`collector_id`**
# * `index_items_on_discourse_type_id`:
Expand Down
22 changes: 16 additions & 6 deletions db/cache_schema.rb
Original file line number Diff line number Diff line change
@@ -1,12 +1,22 @@
# frozen_string_literal: true
# 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: 1) do
create_table "solid_cache_entries", force: :cascade do |t|
ActiveRecord::Schema[8.0].define(version: 1) do
create_table "solid_cache_entries", charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t|
t.binary "key", limit: 1024, null: false
t.binary "value", limit: 536870912, null: false
t.binary "value", size: :long, null: false
t.datetime "created_at", null: false
t.integer "key_hash", limit: 8, null: false
t.integer "byte_size", limit: 4, null: false
t.bigint "key_hash", null: false
t.integer "byte_size", null: false
t.index ["byte_size"], name: "index_solid_cache_entries_on_byte_size"
t.index ["key_hash", "byte_size"], name: "index_solid_cache_entries_on_key_hash_and_byte_size"
t.index ["key_hash"], name: "index_solid_cache_entries_on_key_hash", unique: true
Expand Down
14 changes: 13 additions & 1 deletion db/queue_schema.rb
Original file line number Diff line number Diff line change
@@ -1,4 +1,16 @@
ActiveRecord::Schema[7.1].define(version: 1) do
# 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[8.0].define(version: 2024_09_04_193154) do
create_table "solid_queue_blocked_executions", charset: "utf8mb4", collation: "utf8mb4_0900_ai_ci", force: :cascade do |t|
t.bigint "job_id", null: false
t.string "queue_name", null: false
Expand Down
4 changes: 3 additions & 1 deletion db/schema.rb

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions spec/models/collection_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@
# * **`identifier`**
# * `index_collections_on_operator_id`:
# * **`operator_id`**
# * `index_collections_on_private`:
# * **`private`**
# * `index_collections_on_university_id`:
# * **`university_id`**
#
Expand Down
4 changes: 4 additions & 0 deletions spec/models/item_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,10 @@
# * **`access_condition_id`**
# * `index_items_on_collection_id`:
# * **`collection_id`**
# * `index_items_on_collection_id_and_private_and_updated_at`:
# * **`collection_id`**
# * **`private`**
# * **`updated_at`**
# * `index_items_on_collector_id`:
# * **`collector_id`**
# * `index_items_on_discourse_type_id`:
Expand Down

0 comments on commit ad2322a

Please sign in to comment.