thermos 0.3.0 → 0.5.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e62c552fe46de749b2a3fb48bf0acd49c0fe8380cb0aae5cc1a2705251e737a1
4
- data.tar.gz: 38aa4f854df16db68a6cec1a5ebef0666b5cc8bf2f20dddf997f818dc8a28cbd
3
+ metadata.gz: caef41475321f2d1d3286a253267f0138396addb93dda96774f3ce29502e42d4
4
+ data.tar.gz: 0b347ad89c7cbd0082c801537270d5efd140db676131985f0c65625d27f3669f
5
5
  SHA512:
6
- metadata.gz: e40a19c56af0d4001723cbdca6528d00e8ddd1524a3d117a1e83314dac8f6480fbda3423419474249990424349ec36ffa35db8dc6b01d0eb67f7f28df580578d
7
- data.tar.gz: b45a8691d82c7b66ae7cc0c5c5aeb00fe1fdd41d75f6cc99ee8812bace09e0f6e4c58a522cfa367a20890872eff214413ca0f63338674fc94aa16ed428902db0
6
+ metadata.gz: b2fcf8764757cbc90257a1b2f1a2c96aa2d39b117702b399ac9d44527e62a9bf14cf394344ffe3300d3513d88b0a9a18063696d299e282794edbcadf5d2bac9d
7
+ data.tar.gz: 2c20039b4fe427402c3ab8dbfacc83266530c0d63e169055f574ae6a433d69a772a9b4d8aa097988bced9ebb6f0c5c532963f7b0ef85f57003dbc7eb1c5e6bd7
@@ -2,29 +2,33 @@
2
2
 
3
3
  module Thermos
4
4
  class Beverage
5
- attr_reader :key, :model, :deps, :action, :lookup_key
5
+ attr_reader :key, :model, :deps, :action, :lookup_key, :filter
6
6
 
7
- def initialize(key:, model:, deps:, action:, lookup_key: nil)
7
+ def initialize(key:, model:, deps:, action:, lookup_key: nil, filter: nil)
8
8
  @key = key
9
9
  @model = model
10
10
  @lookup_key = lookup_key || :id
11
- @deps = deps.map do |dep|
12
- Dependency.new(model: model, association: dep)
13
- end
11
+ @filter = filter || nil
12
+ @deps = generate_deps(model, deps)
14
13
  @action = action
15
14
 
16
15
  set_observers
17
16
  end
18
17
 
19
18
  def lookup_keys_for_dep_model(dep_model)
20
- @deps.flat_map do |dep|
21
- return [] unless dep.klass == dep_model.class
22
- @model.joins(dep.association)
19
+ @deps.select do |dep|
20
+ dep.klass == dep_model.class
21
+ end.flat_map do |dep|
22
+ @model.joins(dep.path)
23
23
  .where(dep.table => { id: dep_model.id })
24
24
  .pluck(@lookup_key)
25
25
  end.uniq
26
26
  end
27
27
 
28
+ def should_fill?(model)
29
+ @filter.class == Proc ? !!@filter.call(model) : true
30
+ end
31
+
28
32
  private
29
33
 
30
34
  def set_observers
@@ -35,5 +39,34 @@ module Thermos
35
39
  def observe(model)
36
40
  model.include(Notifier) unless model.included_modules.include?(Notifier)
37
41
  end
42
+
43
+ def generate_deps(model, deps, root = nil, path = nil)
44
+ deps.reduce([]) do |acc, dep|
45
+ if dep.is_a? Symbol
46
+ acc << Dependency.new(
47
+ model: root || model,
48
+ ref: model.reflect_on_association(dep),
49
+ path: path || dep)
50
+ elsif dep.is_a? Array
51
+ dep.each do |d|
52
+ acc << Dependency.new(
53
+ model: root || model,
54
+ ref: model.reflect_on_association(d),
55
+ path: path || d)
56
+ end
57
+ elsif dep.is_a? Hash
58
+ dep.each do |k,v|
59
+ ref = model.reflect_on_association(k)
60
+ acc << Dependency.new(
61
+ model: root || model,
62
+ ref: ref,
63
+ path: path || k
64
+ )
65
+ acc.concat(generate_deps(ref.class_name.constantize, v, model, dep))
66
+ end
67
+ end
68
+ acc
69
+ end
70
+ end
38
71
  end
39
72
  end
@@ -2,14 +2,13 @@
2
2
 
3
3
  module Thermos
4
4
  class Dependency
5
- attr_reader :model, :association, :klass, :table
5
+ attr_reader :model, :path, :klass, :table
6
6
 
7
- def initialize(model:, association:)
7
+ def initialize(model:, ref:, path: nil)
8
8
  @model = model
9
- @association = association
10
- reflection = @model.reflections[@association.to_s]
11
- @table = reflection.table_name
12
- @klass = reflection.class_name.constantize
9
+ @path = path
10
+ @table = ref.table_name
11
+ @klass = ref.class_name.constantize
13
12
  end
14
13
  end
15
14
  end
@@ -5,7 +5,7 @@ module Thermos
5
5
  extend ActiveSupport::Concern
6
6
 
7
7
  included do
8
- after_commit :notify_thermos
8
+ after_commit :notify_thermos, on: %i[create update]
9
9
  end
10
10
 
11
11
  private
@@ -9,7 +9,7 @@ module Thermos
9
9
 
10
10
  def refill_primary_caches(model)
11
11
  BeverageStorage.instance.beverages.each do |beverage|
12
- if beverage.model == model.class
12
+ if beverage.model == model.class && beverage.should_fill?(model)
13
13
  Thermos::RebuildCacheJob.perform_later(beverage.key, model.send(beverage.lookup_key))
14
14
  end
15
15
  end
@@ -17,8 +17,10 @@ module Thermos
17
17
 
18
18
  def refill_dependency_caches(model)
19
19
  BeverageStorage.instance.beverages.each do |beverage|
20
- beverage.lookup_keys_for_dep_model(model).each do |lookup_key|
21
- Thermos::RebuildCacheJob.perform_later(beverage.key, lookup_key)
20
+ if beverage.should_fill?(model)
21
+ beverage.lookup_keys_for_dep_model(model).each do |lookup_key|
22
+ Thermos::RebuildCacheJob.perform_later(beverage.key, lookup_key)
23
+ end
22
24
  end
23
25
  end
24
26
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Thermos
4
- VERSION = '0.3.0'
4
+ VERSION = '0.5.1'
5
5
  end
data/lib/thermos.rb CHANGED
@@ -8,14 +8,14 @@ require 'thermos/refill_job'
8
8
  require 'thermos/rebuild_cache_job'
9
9
 
10
10
  module Thermos
11
- def self.keep_warm(key:, model:, id:, deps: [], lookup_key: nil, &block)
12
- fill(key: key, model: model, deps: deps, lookup_key: lookup_key, &block)
11
+ def self.keep_warm(key:, model:, id:, deps: [], lookup_key: nil, filter: nil, &block)
12
+ fill(key: key, model: model, deps: deps, lookup_key: lookup_key, filter: filter, &block)
13
13
  drink(key: key, id: id)
14
14
  end
15
15
 
16
- def self.fill(key:, model:, deps: [], lookup_key: nil, &block)
16
+ def self.fill(key:, model:, deps: [], lookup_key: nil, filter: nil, &block)
17
17
  BeverageStorage.instance.add_beverage(
18
- Beverage.new(key: key, model: model, deps: deps, action: block, lookup_key: lookup_key)
18
+ Beverage.new(key: key, model: model, deps: deps, action: block, lookup_key: lookup_key, filter: filter)
19
19
  )
20
20
  end
21
21
 
@@ -18,10 +18,6 @@ module Dummy
18
18
  # The default locale is :en and all translations from config/locales/*.rb,yml are auto loaded.
19
19
  # config.i18n.load_path += Dir[Rails.root.join('my', 'locales', '*.{rb,yml}').to_s]
20
20
  # config.i18n.default_locale = :de
21
-
22
- if Rails.version >= "5.2.0"
23
- Rails.application.config.active_record.sqlite3.represent_boolean_as_integer = true
24
- end
25
21
  end
26
22
  end
27
23
 
@@ -2,11 +2,11 @@
2
2
  # of editing this file, please use the migrations feature of Active Record to
3
3
  # incrementally modify your database, and then regenerate this schema definition.
4
4
  #
5
- # Note that this schema.rb definition is the authoritative source for your
6
- # database schema. If you need to create the application database on another
7
- # system, you should be using db:schema:load, not running all the migrations
8
- # from scratch. The latter is a flawed and unsustainable approach (the more migrations
9
- # you'll amass, the slower it'll run and the greater likelihood for issues).
5
+ # This file is the source Rails uses to define your schema when running `bin/rails
6
+ # db:schema:load`. When creating a new database, `bin/rails db:schema:load` tends to
7
+ # be faster and is potentially less error prone than running all of your
8
+ # migrations from scratch. Old migrations may fail to apply correctly if those
9
+ # migrations use external dependencies or application code.
10
10
  #
11
11
  # It's strongly recommended that you check this file into your version control system.
12
12
 
data/test/thermos_test.rb CHANGED
@@ -111,6 +111,23 @@ class ThermosTest < ActiveSupport::TestCase
111
111
  assert_raises(MockExpectationError) { mock.verify }
112
112
  end
113
113
 
114
+ test "does not rebuild the cache on primary model destroy" do
115
+ mock = Minitest::Mock.new
116
+ category = categories(:baseball)
117
+
118
+ Thermos.fill(key: "key", model: Category) do |id|
119
+ mock.call(id)
120
+ end
121
+
122
+ mock.expect(:call, 1, [category.id])
123
+ assert_equal 1, Thermos.drink(key: "key", id: category.id)
124
+ mock.verify
125
+
126
+ mock.expect(:call, 2, [category.id])
127
+ category.destroy!
128
+ assert_raises(MockExpectationError) { mock.verify }
129
+ end
130
+
114
131
  test "pre-builds cache for new primary model records" do
115
132
  mock = Minitest::Mock.new
116
133
 
@@ -126,6 +143,23 @@ class ThermosTest < ActiveSupport::TestCase
126
143
  assert_equal 1, Thermos.drink(key: "key", id: "foo")
127
144
  assert_raises(MockExpectationError) { mock.verify }
128
145
  end
146
+
147
+ test "allows filtering for which records should be rebuilt" do
148
+ mock = Minitest::Mock.new
149
+ category = categories(:baseball)
150
+ filter = ->(model) { model.name.match("ball") }
151
+ Thermos.fill(key: "key", model: Category, lookup_key: "name", filter: filter) do |name|
152
+ mock.call(name)
153
+ end
154
+
155
+ mock.expect(:call, 1, ["basketball"])
156
+ category.update!(name: "basketball")
157
+ mock.verify
158
+
159
+ mock.expect(:call, 1, ["hockey"])
160
+ category.update!(name: "hockey")
161
+ assert_raises(MockExpectationError) { mock.verify }
162
+ end
129
163
 
130
164
  # has_many model changes
131
165
  test "rebuilds the cache on has_many model change" do
@@ -314,6 +348,30 @@ class ThermosTest < ActiveSupport::TestCase
314
348
  assert_raises(MockExpectationError) { mock.verify }
315
349
  end
316
350
 
351
+ test "handles indirect associations" do
352
+ mock = Minitest::Mock.new
353
+ category = categories(:baseball)
354
+ store = category.store
355
+
356
+ Thermos.fill(key: "key", model: Store, deps: [categories: [:products]]) do |id|
357
+ mock.call(id)
358
+ end
359
+
360
+ mock.expect(:call, 1, [store.id])
361
+ category.update!(name: "foo")
362
+ mock.verify
363
+
364
+ mock.expect(:call, 2, [store.id])
365
+ assert_equal 1, Thermos.drink(key: "key", id: store.id)
366
+ assert_raises(MockExpectationError) { mock.verify }
367
+ Product.create!(categories: [category])
368
+ mock.verify
369
+
370
+ mock.expect(:call, 3, [store.id])
371
+ assert_equal 2, Thermos.drink(key: "key", id: store.id)
372
+ assert_raises(MockExpectationError) { mock.verify }
373
+ end
374
+
317
375
  test "only rebuilds cache for stated dependencies, even if another cache has an associated model of the primary" do
318
376
  category_mock = Minitest::Mock.new
319
377
  product_mock = Minitest::Mock.new
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: thermos
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrew Thal
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-04-30 00:00:00.000000000 Z
11
+ date: 2021-09-24 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -16,14 +16,20 @@ dependencies:
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: 5.0.0
19
+ version: 5.2.4
20
+ - - "<"
21
+ - !ruby/object:Gem::Version
22
+ version: 6.2.0
20
23
  type: :runtime
21
24
  prerelease: false
22
25
  version_requirements: !ruby/object:Gem::Requirement
23
26
  requirements:
24
27
  - - ">="
25
28
  - !ruby/object:Gem::Version
26
- version: 5.0.0
29
+ version: 5.2.4
30
+ - - "<"
31
+ - !ruby/object:Gem::Version
32
+ version: 6.2.0
27
33
  - !ruby/object:Gem::Dependency
28
34
  name: rake
29
35
  requirement: !ruby/object:Gem::Requirement
@@ -106,15 +112,11 @@ files:
106
112
  - test/dummy/config/locales/en.yml
107
113
  - test/dummy/config/routes.rb
108
114
  - test/dummy/config/secrets.yml
109
- - test/dummy/db/development.sqlite3
110
115
  - test/dummy/db/migrate/20160325214744_create_categories.rb
111
116
  - test/dummy/db/migrate/20160325214849_create_products.rb
112
117
  - test/dummy/db/migrate/20160325220006_create_category_items.rb
113
118
  - test/dummy/db/migrate/20160326174530_create_stores.rb
114
119
  - test/dummy/db/schema.rb
115
- - test/dummy/db/test.sqlite3
116
- - test/dummy/log/development.log
117
- - test/dummy/log/test.log
118
120
  - test/dummy/public/404.html
119
121
  - test/dummy/public/422.html
120
122
  - test/dummy/public/500.html
@@ -138,68 +140,67 @@ required_ruby_version: !ruby/object:Gem::Requirement
138
140
  - - ">="
139
141
  - !ruby/object:Gem::Version
140
142
  version: 2.5.0
143
+ - - "<"
144
+ - !ruby/object:Gem::Version
145
+ version: 2.8.0
141
146
  required_rubygems_version: !ruby/object:Gem::Requirement
142
147
  requirements:
143
148
  - - ">="
144
149
  - !ruby/object:Gem::Version
145
150
  version: '0'
146
151
  requirements: []
147
- rubygems_version: 3.1.2
152
+ rubygems_version: 3.0.3.1
148
153
  signing_key:
149
154
  specification_version: 4
150
155
  summary: Always-warm, auto-rebuilding rails caching without timers or touching.
151
156
  test_files:
152
- - test/dummy/app/models/category.rb
153
- - test/dummy/app/models/product.rb
154
- - test/dummy/app/models/category_item.rb
155
- - test/dummy/app/models/store.rb
156
- - test/dummy/app/controllers/application_controller.rb
157
- - test/dummy/app/views/layouts/application.html.erb
158
- - test/dummy/app/assets/config/manifest.js
159
- - test/dummy/app/assets/javascripts/application.js
160
- - test/dummy/app/assets/stylesheets/application.css
161
- - test/dummy/app/helpers/application_helper.rb
162
- - test/dummy/bin/rake
163
- - test/dummy/bin/setup
164
- - test/dummy/bin/bundle
165
- - test/dummy/bin/rails
166
- - test/dummy/config/secrets.yml
157
+ - test/fixtures/category_items.yml
158
+ - test/fixtures/stores.yml
159
+ - test/fixtures/categories.yml
160
+ - test/fixtures/products.yml
161
+ - test/dummy/README.rdoc
162
+ - test/dummy/public/404.html
163
+ - test/dummy/public/422.html
164
+ - test/dummy/public/500.html
165
+ - test/dummy/public/favicon.ico
166
+ - test/dummy/Rakefile
167
+ - test/dummy/config/application.rb
167
168
  - test/dummy/config/routes.rb
168
- - test/dummy/config/locales/en.yml
169
169
  - test/dummy/config/environments/production.rb
170
- - test/dummy/config/environments/development.rb
171
170
  - test/dummy/config/environments/test.rb
172
- - test/dummy/config/environment.rb
173
- - test/dummy/config/application.rb
171
+ - test/dummy/config/environments/development.rb
174
172
  - test/dummy/config/database.yml
175
- - test/dummy/config/boot.rb
176
173
  - test/dummy/config/initializers/backtrace_silencers.rb
177
- - test/dummy/config/initializers/mime_types.rb
174
+ - test/dummy/config/initializers/assets.rb
175
+ - test/dummy/config/initializers/wrap_parameters.rb
178
176
  - test/dummy/config/initializers/filter_parameter_logging.rb
179
177
  - test/dummy/config/initializers/session_store.rb
180
- - test/dummy/config/initializers/wrap_parameters.rb
181
- - test/dummy/config/initializers/assets.rb
182
- - test/dummy/config/initializers/cookies_serializer.rb
183
178
  - test/dummy/config/initializers/inflections.rb
179
+ - test/dummy/config/initializers/mime_types.rb
180
+ - test/dummy/config/initializers/cookies_serializer.rb
181
+ - test/dummy/config/locales/en.yml
182
+ - test/dummy/config/environment.rb
183
+ - test/dummy/config/secrets.yml
184
+ - test/dummy/config/boot.rb
185
+ - test/dummy/app/models/category_item.rb
186
+ - test/dummy/app/models/category.rb
187
+ - test/dummy/app/models/store.rb
188
+ - test/dummy/app/models/product.rb
189
+ - test/dummy/app/views/layouts/application.html.erb
190
+ - test/dummy/app/assets/javascripts/application.js
191
+ - test/dummy/app/assets/stylesheets/application.css
192
+ - test/dummy/app/assets/config/manifest.js
193
+ - test/dummy/app/controllers/application_controller.rb
194
+ - test/dummy/app/helpers/application_helper.rb
184
195
  - test/dummy/config.ru
185
- - test/dummy/Rakefile
186
- - test/dummy/public/favicon.ico
187
- - test/dummy/public/422.html
188
- - test/dummy/public/500.html
189
- - test/dummy/public/404.html
190
- - test/dummy/db/schema.rb
191
- - test/dummy/db/test.sqlite3
192
196
  - test/dummy/db/migrate/20160325214849_create_products.rb
197
+ - test/dummy/db/migrate/20160325220006_create_category_items.rb
193
198
  - test/dummy/db/migrate/20160326174530_create_stores.rb
194
199
  - test/dummy/db/migrate/20160325214744_create_categories.rb
195
- - test/dummy/db/migrate/20160325220006_create_category_items.rb
196
- - test/dummy/db/development.sqlite3
197
- - test/dummy/log/test.log
198
- - test/dummy/log/development.log
199
- - test/dummy/README.rdoc
200
+ - test/dummy/db/schema.rb
201
+ - test/dummy/bin/rails
202
+ - test/dummy/bin/rake
203
+ - test/dummy/bin/bundle
204
+ - test/dummy/bin/setup
200
205
  - test/thermos_test.rb
201
- - test/fixtures/products.yml
202
- - test/fixtures/categories.yml
203
- - test/fixtures/category_items.yml
204
- - test/fixtures/stores.yml
205
206
  - test/test_helper.rb
Binary file
Binary file
@@ -1,31 +0,0 @@
1
- DEPRECATION WARNING: `.represent_boolean_as_integer=` is now always true, so setting this is deprecated and will be removed in Rails 6.1. (called from load at /Users/athal/.asdf/installs/ruby/2.5.6/bin/rake:23)
2
-  (1.0ms) SELECT sqlite_version(*)
3
-  (2.2ms) CREATE TABLE "schema_migrations" ("version" varchar NOT NULL PRIMARY KEY)
4
-  (1.8ms) CREATE TABLE "ar_internal_metadata" ("key" varchar NOT NULL PRIMARY KEY, "value" varchar, "created_at" datetime(6) NOT NULL, "updated_at" datetime(6) NOT NULL)
5
-  (0.3ms) SELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC
6
- Migrating to CreateCategories (20160325214744)
7
-  (0.1ms) begin transaction
8
-  (0.5ms) CREATE TABLE "categories" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "store_id" integer, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)
9
- primary::SchemaMigration Create (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20160325214744"]]
10
-  (1.3ms) commit transaction
11
- Migrating to CreateProducts (20160325214849)
12
-  (0.1ms) begin transaction
13
-  (0.5ms) CREATE TABLE "products" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)
14
- primary::SchemaMigration Create (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20160325214849"]]
15
-  (1.3ms) commit transaction
16
- Migrating to CreateCategoryItems (20160325220006)
17
-  (0.0ms) begin transaction
18
-  (0.6ms) CREATE TABLE "category_items" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "category_id" integer, "product_id" integer, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)
19
- primary::SchemaMigration Create (0.4ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20160325220006"]]
20
-  (1.2ms) commit transaction
21
- Migrating to CreateStores (20160326174530)
22
-  (0.1ms) begin transaction
23
-  (0.5ms) CREATE TABLE "stores" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)
24
- primary::SchemaMigration Create (0.4ms) INSERT INTO "schema_migrations" ("version") VALUES (?) [["version", "20160326174530"]]
25
-  (1.1ms) commit transaction
26
- ActiveRecord::InternalMetadata Load (0.2ms) SELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ? [["key", "environment"], ["LIMIT", 1]]
27
-  (0.1ms) begin transaction
28
- ActiveRecord::InternalMetadata Create (0.6ms) INSERT INTO "ar_internal_metadata" ("key", "value", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["key", "environment"], ["value", "development"], ["created_at", "2020-04-30 15:04:00.698654"], ["updated_at", "2020-04-30 15:04:00.698654"]]
29
-  (0.7ms) commit transaction
30
-  (0.0ms) SELECT sqlite_version(*)
31
-  (0.3ms) SELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC
@@ -1,340 +0,0 @@
1
-  (1.4ms) SELECT sqlite_version(*)
2
-  (1.0ms) SELECT sqlite_version(*)
3
-  (0.0ms) SELECT sqlite_version(*)
4
-  (0.1ms) SELECT sqlite_version(*)
5
-  (0.1ms) DROP TABLE IF EXISTS "categories"
6
-  (3.9ms) CREATE TABLE "categories" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "store_id" integer, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)
7
-  (0.2ms) DROP TABLE IF EXISTS "category_items"
8
-  (1.2ms) CREATE TABLE "category_items" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "category_id" integer, "product_id" integer, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)
9
-  (0.1ms) DROP TABLE IF EXISTS "products"
10
-  (1.6ms) CREATE TABLE "products" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)
11
-  (0.3ms) DROP TABLE IF EXISTS "stores"
12
-  (1.8ms) CREATE TABLE "stores" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "created_at" datetime NOT NULL, "updated_at" datetime NOT NULL)
13
-  (1.5ms) CREATE TABLE "schema_migrations" ("version" varchar NOT NULL PRIMARY KEY)
14
-  (0.1ms) SELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC
15
-  (2.8ms) INSERT INTO "schema_migrations" (version) VALUES (20160326174530)
16
-  (1.6ms) INSERT INTO "schema_migrations" (version) VALUES
17
- (20160325214744),
18
- (20160325214849),
19
- (20160325220006);
20
-
21
- 
22
-  (1.5ms) CREATE TABLE "ar_internal_metadata" ("key" varchar NOT NULL PRIMARY KEY, "value" varchar, "created_at" datetime(6) NOT NULL, "updated_at" datetime(6) NOT NULL)
23
- ActiveRecord::InternalMetadata Load (0.2ms) SELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ? [["key", "environment"], ["LIMIT", 1]]
24
-  (0.1ms) begin transaction
25
- ActiveRecord::InternalMetadata Create (0.5ms) INSERT INTO "ar_internal_metadata" ("key", "value", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["key", "environment"], ["value", "test"], ["created_at", "2020-04-30 15:04:05.288707"], ["updated_at", "2020-04-30 15:04:05.288707"]]
26
-  (0.7ms) commit transaction
27
- ActiveRecord::InternalMetadata Load (0.1ms) SELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ? [["key", "environment"], ["LIMIT", 1]]
28
- ActiveRecord::InternalMetadata Load (0.1ms) SELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ? [["key", "schema_sha1"], ["LIMIT", 1]]
29
-  (0.0ms) begin transaction
30
- ActiveRecord::InternalMetadata Create (0.3ms) INSERT INTO "ar_internal_metadata" ("key", "value", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["key", "schema_sha1"], ["value", "134e2f83987f60f7f5b4e080f9158b942de36d8e"], ["created_at", "2020-04-30 15:04:05.294044"], ["updated_at", "2020-04-30 15:04:05.294044"]]
31
-  (1.0ms) commit transaction
32
-  (0.3ms) SELECT sqlite_version(*)
33
-  (0.2ms) SELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC
34
-  (0.0ms) PRAGMA foreign_keys
35
-  (0.0ms) PRAGMA defer_foreign_keys
36
-  (0.1ms) PRAGMA defer_foreign_keys = ON
37
-  (0.1ms) PRAGMA foreign_keys = OFF
38
-  (0.0ms) begin transaction
39
- Fixtures Load (0.8ms) DELETE FROM "products";
40
- DELETE FROM "categories";
41
- DELETE FROM "category_items";
42
- DELETE FROM "stores";
43
- INSERT INTO "products" ("id", "name", "created_at", "updated_at") VALUES (469160771, 'glove', '2020-04-30 15:04:05.387008', '2020-04-30 15:04:05.387008');
44
- INSERT INTO "categories" ("id", "name", "store_id", "created_at", "updated_at") VALUES (322908140, 'baseball', 868874525, '2020-04-30 15:04:05.388913', '2020-04-30 15:04:05.388913');
45
- INSERT INTO "category_items" ("id", "name", "category_id", "product_id", "created_at", "updated_at") VALUES (678302810, 'baseball glove', 322908140, 469160771, '2020-04-30 15:04:05.390505', '2020-04-30 15:04:05.390505');
46
- INSERT INTO "stores" ("id", "name", "created_at", "updated_at") VALUES (868874525, 'sports store', '2020-04-30 15:04:05.393035', '2020-04-30 15:04:05.393035')
47
-  (1.4ms) commit transaction
48
-  (0.1ms) PRAGMA defer_foreign_keys = 0
49
-  (0.1ms) PRAGMA foreign_keys = 1
50
-  (0.1ms) begin transaction
51
- ---------------------------------------------------------
52
- ThermosTest: test_keeps_the_cache_warm_using_fill_/_drink
53
- ---------------------------------------------------------
54
-  (0.2ms) rollback transaction
55
-  (0.1ms) begin transaction
56
- -------------------------------------------------------------------------------------------
57
- ThermosTest: test_does_not_rebuild_the_cache_for_an_unrelated_has_many_through_model_change
58
- -------------------------------------------------------------------------------------------
59
- Category Load (0.2ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
60
-  (0.1ms) SAVEPOINT active_record_1
61
- Product Create (0.6ms) INSERT INTO "products" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2020-04-30 15:04:05.413054"], ["updated_at", "2020-04-30 15:04:05.413054"]]
62
-  (0.0ms) RELEASE SAVEPOINT active_record_1
63
-  (0.1ms) SAVEPOINT active_record_1
64
- Product Update (0.1ms) UPDATE "products" SET "name" = ?, "updated_at" = ? WHERE "products"."id" = ? [["name", "foo"], ["updated_at", "2020-04-30 15:04:05.418895"], ["id", 469160772]]
65
-  (0.1ms) RELEASE SAVEPOINT active_record_1
66
- [ActiveJob] Product Load (0.1ms) SELECT "products".* FROM "products" WHERE "products"."id" = ? LIMIT ? [["id", 469160772], ["LIMIT", 1]]
67
- [ActiveJob] [Thermos::RefillJob] [7a73cbb9-e40c-49a6-96a2-819f381ac9b9] Performing Thermos::RefillJob (Job ID: 7a73cbb9-e40c-49a6-96a2-819f381ac9b9) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb19d20d50 @uri=#<URI::GID gid://dummy/Product/469160772>>
68
- [ActiveJob] [Thermos::RefillJob] [7a73cbb9-e40c-49a6-96a2-819f381ac9b9]  (0.2ms) SELECT "categories"."id" FROM "categories" INNER JOIN "category_items" ON "category_items"."category_id" = "categories"."id" INNER JOIN "products" ON "products"."id" = "category_items"."product_id" WHERE "products"."id" = ? [["id", 469160772]]
69
- [ActiveJob] [Thermos::RefillJob] [7a73cbb9-e40c-49a6-96a2-819f381ac9b9] Performed Thermos::RefillJob (Job ID: 7a73cbb9-e40c-49a6-96a2-819f381ac9b9) from Inline(default) in 12.52ms
70
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: 7a73cbb9-e40c-49a6-96a2-819f381ac9b9) to Inline(default) with arguments: #<GlobalID:0x00007feb1adb53f0 @uri=#<URI::GID gid://dummy/Product/469160772>>
71
-  (0.3ms) rollback transaction
72
-  (0.0ms) begin transaction
73
- ------------------------------------------------------------
74
- ThermosTest: test_rebuilds_the_cache_on_primary_model_change
75
- ------------------------------------------------------------
76
- Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
77
-  (0.1ms) SAVEPOINT active_record_1
78
- Category Update (0.3ms) UPDATE "categories" SET "name" = ?, "updated_at" = ? WHERE "categories"."id" = ? [["name", "foo"], ["updated_at", "2020-04-30 15:04:05.523306"], ["id", 322908140]]
79
-  (0.1ms) RELEASE SAVEPOINT active_record_1
80
- [ActiveJob] Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
81
- [ActiveJob] [Thermos::RefillJob] [5cab55d4-06d0-4aaa-8e15-4476c6c90e97] Performing Thermos::RefillJob (Job ID: 5cab55d4-06d0-4aaa-8e15-4476c6c90e97) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb19459550 @uri=#<URI::GID gid://dummy/Category/322908140>>
82
- [ActiveJob] [Thermos::RefillJob] [5cab55d4-06d0-4aaa-8e15-4476c6c90e97] [Thermos::RebuildCacheJob] [ce509247-2009-4177-be71-68398f6c465b] Performing Thermos::RebuildCacheJob (Job ID: ce509247-2009-4177-be71-68398f6c465b) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: "key", 322908140
83
- [ActiveJob] [Thermos::RefillJob] [5cab55d4-06d0-4aaa-8e15-4476c6c90e97] [Thermos::RebuildCacheJob] [ce509247-2009-4177-be71-68398f6c465b] Performed Thermos::RebuildCacheJob (Job ID: ce509247-2009-4177-be71-68398f6c465b) from Inline(default) in 0.75ms
84
- [ActiveJob] [Thermos::RefillJob] [5cab55d4-06d0-4aaa-8e15-4476c6c90e97] Enqueued Thermos::RebuildCacheJob (Job ID: ce509247-2009-4177-be71-68398f6c465b) to Inline(default) with arguments: "key", 322908140
85
- [ActiveJob] [Thermos::RefillJob] [5cab55d4-06d0-4aaa-8e15-4476c6c90e97] Performed Thermos::RefillJob (Job ID: 5cab55d4-06d0-4aaa-8e15-4476c6c90e97) from Inline(default) in 1.41ms
86
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: 5cab55d4-06d0-4aaa-8e15-4476c6c90e97) to Inline(default) with arguments: #<GlobalID:0x00007feb19cd9f40 @uri=#<URI::GID gid://dummy/Category/322908140>>
87
-  (0.3ms) rollback transaction
88
-  (0.0ms) begin transaction
89
- ----------------------------------------------------------------------------------
90
- ThermosTest: test_does_not_rebuild_the_cache_for_an_unrelated_primary_model_change
91
- ----------------------------------------------------------------------------------
92
- Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
93
-  (0.0ms) SAVEPOINT active_record_1
94
- Category Create (0.4ms) INSERT INTO "categories" ("name", "created_at", "updated_at") VALUES (?, ?, ?) [["name", "bar"], ["created_at", "2020-04-30 15:04:05.531148"], ["updated_at", "2020-04-30 15:04:05.531148"]]
95
-  (0.1ms) RELEASE SAVEPOINT active_record_1
96
- [ActiveJob] Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908141], ["LIMIT", 1]]
97
- [ActiveJob] [Thermos::RefillJob] [383f3a3e-4c51-4b39-8696-9e8ba8418f1a] Performing Thermos::RefillJob (Job ID: 383f3a3e-4c51-4b39-8696-9e8ba8418f1a) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb1ad9f6b8 @uri=#<URI::GID gid://dummy/Category/322908141>>
98
- [ActiveJob] [Thermos::RefillJob] [383f3a3e-4c51-4b39-8696-9e8ba8418f1a] Performed Thermos::RefillJob (Job ID: 383f3a3e-4c51-4b39-8696-9e8ba8418f1a) from Inline(default) in 0.04ms
99
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: 383f3a3e-4c51-4b39-8696-9e8ba8418f1a) to Inline(default) with arguments: #<GlobalID:0x00007feb1ad9d4f8 @uri=#<URI::GID gid://dummy/Category/322908141>>
100
-  (0.1ms) SAVEPOINT active_record_1
101
- Category Update (0.1ms) UPDATE "categories" SET "name" = ?, "updated_at" = ? WHERE "categories"."id" = ? [["name", "foo"], ["updated_at", "2020-04-30 15:04:05.535626"], ["id", 322908140]]
102
-  (0.0ms) RELEASE SAVEPOINT active_record_1
103
- [ActiveJob] Category Load (0.0ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
104
- [ActiveJob] [Thermos::RefillJob] [f9f740d4-cc88-4b13-b8a9-14c5affdc10a] Performing Thermos::RefillJob (Job ID: f9f740d4-cc88-4b13-b8a9-14c5affdc10a) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb19431050 @uri=#<URI::GID gid://dummy/Category/322908140>>
105
- [ActiveJob] [Thermos::RefillJob] [f9f740d4-cc88-4b13-b8a9-14c5affdc10a] [Thermos::RebuildCacheJob] [c1a54668-583b-4bce-9325-134aa731bed6] Performing Thermos::RebuildCacheJob (Job ID: c1a54668-583b-4bce-9325-134aa731bed6) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: "key", 322908140
106
- [ActiveJob] [Thermos::RefillJob] [f9f740d4-cc88-4b13-b8a9-14c5affdc10a] [Thermos::RebuildCacheJob] [c1a54668-583b-4bce-9325-134aa731bed6] Performed Thermos::RebuildCacheJob (Job ID: c1a54668-583b-4bce-9325-134aa731bed6) from Inline(default) in 1.4ms
107
- [ActiveJob] [Thermos::RefillJob] [f9f740d4-cc88-4b13-b8a9-14c5affdc10a] Enqueued Thermos::RebuildCacheJob (Job ID: c1a54668-583b-4bce-9325-134aa731bed6) to Inline(default) with arguments: "key", 322908140
108
- [ActiveJob] [Thermos::RefillJob] [f9f740d4-cc88-4b13-b8a9-14c5affdc10a] Performed Thermos::RefillJob (Job ID: f9f740d4-cc88-4b13-b8a9-14c5affdc10a) from Inline(default) in 1.95ms
109
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: f9f740d4-cc88-4b13-b8a9-14c5affdc10a) to Inline(default) with arguments: #<GlobalID:0x00007feb1ad85588 @uri=#<URI::GID gid://dummy/Category/322908140>>
110
-  (0.6ms) rollback transaction
111
-  (0.1ms) begin transaction
112
- ----------------------------------------------------------------
113
- ThermosTest: test_re-builds_the_cache_for_new_belongs_to_records
114
- ----------------------------------------------------------------
115
- Category Load (0.4ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
116
-  (0.1ms) SAVEPOINT active_record_1
117
- Store Create (0.6ms) INSERT INTO "stores" ("name", "created_at", "updated_at") VALUES (?, ?, ?) [["name", "foo"], ["created_at", "2020-04-30 15:04:05.563671"], ["updated_at", "2020-04-30 15:04:05.563671"]]
118
- Category Update (0.3ms) UPDATE "categories" SET "store_id" = ?, "updated_at" = ? WHERE "categories"."id" = ? [["store_id", 868874526], ["updated_at", "2020-04-30 15:04:05.566444"], ["id", 322908140]]
119
-  (0.1ms) RELEASE SAVEPOINT active_record_1
120
- [ActiveJob] Store Load (0.1ms) SELECT "stores".* FROM "stores" WHERE "stores"."id" = ? LIMIT ? [["id", 868874526], ["LIMIT", 1]]
121
- [ActiveJob] [Thermos::RefillJob] [39961cdd-3add-4b2f-89d1-2731220068d7] Performing Thermos::RefillJob (Job ID: 39961cdd-3add-4b2f-89d1-2731220068d7) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb1ad2c438 @uri=#<URI::GID gid://dummy/Store/868874526>>
122
- [ActiveJob] [Thermos::RefillJob] [39961cdd-3add-4b2f-89d1-2731220068d7]  (0.1ms) SELECT "categories"."id" FROM "categories" INNER JOIN "stores" ON "stores"."id" = "categories"."store_id" WHERE "stores"."id" = ? [["id", 868874526]]
123
- [ActiveJob] [Thermos::RefillJob] [39961cdd-3add-4b2f-89d1-2731220068d7] [Thermos::RebuildCacheJob] [c6b0d4b1-079c-49f8-8807-343219255b8a] Performing Thermos::RebuildCacheJob (Job ID: c6b0d4b1-079c-49f8-8807-343219255b8a) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: "key", 322908140
124
- [ActiveJob] [Thermos::RefillJob] [39961cdd-3add-4b2f-89d1-2731220068d7] [Thermos::RebuildCacheJob] [c6b0d4b1-079c-49f8-8807-343219255b8a] Performed Thermos::RebuildCacheJob (Job ID: c6b0d4b1-079c-49f8-8807-343219255b8a) from Inline(default) in 1.7ms
125
- [ActiveJob] [Thermos::RefillJob] [39961cdd-3add-4b2f-89d1-2731220068d7] Enqueued Thermos::RebuildCacheJob (Job ID: c6b0d4b1-079c-49f8-8807-343219255b8a) to Inline(default) with arguments: "key", 322908140
126
- [ActiveJob] [Thermos::RefillJob] [39961cdd-3add-4b2f-89d1-2731220068d7] Performed Thermos::RefillJob (Job ID: 39961cdd-3add-4b2f-89d1-2731220068d7) from Inline(default) in 3.82ms
127
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: 39961cdd-3add-4b2f-89d1-2731220068d7) to Inline(default) with arguments: #<GlobalID:0x00007feb193b05e0 @uri=#<URI::GID gid://dummy/Store/868874526>>
128
- [ActiveJob] Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
129
- [ActiveJob] [Thermos::RefillJob] [348665d4-f570-4145-a3c8-f83238f3531c] Performing Thermos::RefillJob (Job ID: 348665d4-f570-4145-a3c8-f83238f3531c) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb1a2c4360 @uri=#<URI::GID gid://dummy/Category/322908140>>
130
- [ActiveJob] [Thermos::RefillJob] [348665d4-f570-4145-a3c8-f83238f3531c] [Thermos::RebuildCacheJob] [bde5a39a-1b10-46ca-aeb1-2aa9f6da13f4] Performing Thermos::RebuildCacheJob (Job ID: bde5a39a-1b10-46ca-aeb1-2aa9f6da13f4) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: "key", 322908140
131
- [ActiveJob] [Thermos::RefillJob] [348665d4-f570-4145-a3c8-f83238f3531c] [Thermos::RebuildCacheJob] [bde5a39a-1b10-46ca-aeb1-2aa9f6da13f4] Performed Thermos::RebuildCacheJob (Job ID: bde5a39a-1b10-46ca-aeb1-2aa9f6da13f4) from Inline(default) in 1.31ms
132
- [ActiveJob] [Thermos::RefillJob] [348665d4-f570-4145-a3c8-f83238f3531c] Enqueued Thermos::RebuildCacheJob (Job ID: bde5a39a-1b10-46ca-aeb1-2aa9f6da13f4) to Inline(default) with arguments: "key", 322908140
133
- [ActiveJob] [Thermos::RefillJob] [348665d4-f570-4145-a3c8-f83238f3531c] Performed Thermos::RefillJob (Job ID: 348665d4-f570-4145-a3c8-f83238f3531c) from Inline(default) in 2.74ms
134
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: 348665d4-f570-4145-a3c8-f83238f3531c) to Inline(default) with arguments: #<GlobalID:0x00007feb1ad251d8 @uri=#<URI::GID gid://dummy/Category/322908140>>
135
-  (0.5ms) rollback transaction
136
-  (0.0ms) begin transaction
137
- --------------------------------------------------------------------------
138
- ThermosTest: test_accepts_and_can_rebuild_off_of_an_id_other_than_the_'id'
139
- --------------------------------------------------------------------------
140
- Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
141
- Product Load (0.0ms) SELECT "products".* FROM "products" WHERE "products"."id" = ? LIMIT ? [["id", 469160771], ["LIMIT", 1]]
142
-  (0.1ms) SAVEPOINT active_record_1
143
- Category Update (0.7ms) UPDATE "categories" SET "name" = ?, "updated_at" = ? WHERE "categories"."id" = ? [["name", "foo"], ["updated_at", "2020-04-30 15:04:05.584873"], ["id", 322908140]]
144
-  (0.0ms) RELEASE SAVEPOINT active_record_1
145
- [ActiveJob] Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
146
- [ActiveJob] [Thermos::RefillJob] [58f500fa-bac4-40bd-8fb2-9addbdc4138e] Performing Thermos::RefillJob (Job ID: 58f500fa-bac4-40bd-8fb2-9addbdc4138e) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb1ad0c6b0 @uri=#<URI::GID gid://dummy/Category/322908140>>
147
- [ActiveJob] [Thermos::RefillJob] [58f500fa-bac4-40bd-8fb2-9addbdc4138e] [Thermos::RebuildCacheJob] [f3b41c46-4cbb-4d5f-a14a-d22a49ae40d0] Performing Thermos::RebuildCacheJob (Job ID: f3b41c46-4cbb-4d5f-a14a-d22a49ae40d0) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: "key", "foo"
148
- [ActiveJob] [Thermos::RefillJob] [58f500fa-bac4-40bd-8fb2-9addbdc4138e] [Thermos::RebuildCacheJob] [f3b41c46-4cbb-4d5f-a14a-d22a49ae40d0] Performed Thermos::RebuildCacheJob (Job ID: f3b41c46-4cbb-4d5f-a14a-d22a49ae40d0) from Inline(default) in 1.42ms
149
- [ActiveJob] [Thermos::RefillJob] [58f500fa-bac4-40bd-8fb2-9addbdc4138e] Enqueued Thermos::RebuildCacheJob (Job ID: f3b41c46-4cbb-4d5f-a14a-d22a49ae40d0) to Inline(default) with arguments: "key", "foo"
150
- [ActiveJob] [Thermos::RefillJob] [58f500fa-bac4-40bd-8fb2-9addbdc4138e] Performed Thermos::RefillJob (Job ID: 58f500fa-bac4-40bd-8fb2-9addbdc4138e) from Inline(default) in 1.91ms
151
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: 58f500fa-bac4-40bd-8fb2-9addbdc4138e) to Inline(default) with arguments: #<GlobalID:0x00007feb19c72d40 @uri=#<URI::GID gid://dummy/Category/322908140>>
152
-  (0.1ms) SAVEPOINT active_record_1
153
- Product Update (0.2ms) UPDATE "products" SET "name" = ?, "updated_at" = ? WHERE "products"."id" = ? [["name", "foo"], ["updated_at", "2020-04-30 15:04:05.591253"], ["id", 469160771]]
154
-  (0.0ms) RELEASE SAVEPOINT active_record_1
155
- [ActiveJob] Product Load (0.1ms) SELECT "products".* FROM "products" WHERE "products"."id" = ? LIMIT ? [["id", 469160771], ["LIMIT", 1]]
156
- [ActiveJob] [Thermos::RefillJob] [dfb56108-c1fa-46c6-9f85-5b99ec653749] Performing Thermos::RefillJob (Job ID: dfb56108-c1fa-46c6-9f85-5b99ec653749) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb1a2ae8d0 @uri=#<URI::GID gid://dummy/Product/469160771>>
157
- [ActiveJob] [Thermos::RefillJob] [dfb56108-c1fa-46c6-9f85-5b99ec653749]  (0.1ms) SELECT "categories"."name" FROM "categories" INNER JOIN "category_items" ON "category_items"."category_id" = "categories"."id" INNER JOIN "products" ON "products"."id" = "category_items"."product_id" WHERE "products"."id" = ? [["id", 469160771]]
158
- [ActiveJob] [Thermos::RefillJob] [dfb56108-c1fa-46c6-9f85-5b99ec653749] [Thermos::RebuildCacheJob] [da9431d7-b3a5-45aa-83b5-4d522b7a5441] Performing Thermos::RebuildCacheJob (Job ID: da9431d7-b3a5-45aa-83b5-4d522b7a5441) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: "key", "foo"
159
- [ActiveJob] [Thermos::RefillJob] [dfb56108-c1fa-46c6-9f85-5b99ec653749] [Thermos::RebuildCacheJob] [da9431d7-b3a5-45aa-83b5-4d522b7a5441] Performed Thermos::RebuildCacheJob (Job ID: da9431d7-b3a5-45aa-83b5-4d522b7a5441) from Inline(default) in 0.77ms
160
- [ActiveJob] [Thermos::RefillJob] [dfb56108-c1fa-46c6-9f85-5b99ec653749] Enqueued Thermos::RebuildCacheJob (Job ID: da9431d7-b3a5-45aa-83b5-4d522b7a5441) to Inline(default) with arguments: "key", "foo"
161
- [ActiveJob] [Thermos::RefillJob] [dfb56108-c1fa-46c6-9f85-5b99ec653749] Performed Thermos::RefillJob (Job ID: dfb56108-c1fa-46c6-9f85-5b99ec653749) from Inline(default) in 2.4ms
162
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: dfb56108-c1fa-46c6-9f85-5b99ec653749) to Inline(default) with arguments: #<GlobalID:0x00007feb1a2a4308 @uri=#<URI::GID gid://dummy/Product/469160771>>
163
-  (0.4ms) rollback transaction
164
-  (0.1ms) begin transaction
165
- ---------------------------------------------------------------------
166
- ThermosTest: test_rebuilds_the_cache_on_has_many_through_model_change
167
- ---------------------------------------------------------------------
168
- Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
169
- Product Load (0.0ms) SELECT "products".* FROM "products" WHERE "products"."id" = ? LIMIT ? [["id", 469160771], ["LIMIT", 1]]
170
-  (0.2ms) SAVEPOINT active_record_1
171
- Product Update (0.7ms) UPDATE "products" SET "name" = ?, "updated_at" = ? WHERE "products"."id" = ? [["name", "foo"], ["updated_at", "2020-04-30 15:04:05.602715"], ["id", 469160771]]
172
-  (0.2ms) RELEASE SAVEPOINT active_record_1
173
- [ActiveJob] Product Load (0.1ms) SELECT "products".* FROM "products" WHERE "products"."id" = ? LIMIT ? [["id", 469160771], ["LIMIT", 1]]
174
- [ActiveJob] [Thermos::RefillJob] [6424d15d-262f-4102-a67b-7660635fe7a6] Performing Thermos::RefillJob (Job ID: 6424d15d-262f-4102-a67b-7660635fe7a6) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb19c514b0 @uri=#<URI::GID gid://dummy/Product/469160771>>
175
- [ActiveJob] [Thermos::RefillJob] [6424d15d-262f-4102-a67b-7660635fe7a6]  (0.0ms) SELECT "categories"."id" FROM "categories" INNER JOIN "category_items" ON "category_items"."category_id" = "categories"."id" INNER JOIN "products" ON "products"."id" = "category_items"."product_id" WHERE "products"."id" = ? [["id", 469160771]]
176
- [ActiveJob] [Thermos::RefillJob] [6424d15d-262f-4102-a67b-7660635fe7a6] [Thermos::RebuildCacheJob] [5ec388f6-656d-4688-9d91-b1cf7f3018e3] Performing Thermos::RebuildCacheJob (Job ID: 5ec388f6-656d-4688-9d91-b1cf7f3018e3) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: "key", 322908140
177
- [ActiveJob] [Thermos::RefillJob] [6424d15d-262f-4102-a67b-7660635fe7a6] [Thermos::RebuildCacheJob] [5ec388f6-656d-4688-9d91-b1cf7f3018e3] Performed Thermos::RebuildCacheJob (Job ID: 5ec388f6-656d-4688-9d91-b1cf7f3018e3) from Inline(default) in 0.81ms
178
- [ActiveJob] [Thermos::RefillJob] [6424d15d-262f-4102-a67b-7660635fe7a6] Enqueued Thermos::RebuildCacheJob (Job ID: 5ec388f6-656d-4688-9d91-b1cf7f3018e3) to Inline(default) with arguments: "key", 322908140
179
- [ActiveJob] [Thermos::RefillJob] [6424d15d-262f-4102-a67b-7660635fe7a6] Performed Thermos::RefillJob (Job ID: 6424d15d-262f-4102-a67b-7660635fe7a6) from Inline(default) in 1.98ms
180
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: 6424d15d-262f-4102-a67b-7660635fe7a6) to Inline(default) with arguments: #<GlobalID:0x00007feb1ace4db8 @uri=#<URI::GID gid://dummy/Product/469160771>>
181
-  (0.4ms) rollback transaction
182
-  (0.0ms) begin transaction
183
- ------------------------------------------------------
184
- ThermosTest: test_keeps_the_cache_warm_using_keep_warm
185
- ------------------------------------------------------
186
-  (0.0ms) rollback transaction
187
-  (0.0ms) begin transaction
188
- ----------------------------------------------------------------------
189
- ThermosTest: test_re-builds_the_cache_for_new_has_many_through_records
190
- ----------------------------------------------------------------------
191
- Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
192
-  (0.1ms) SAVEPOINT active_record_1
193
- Product Create (0.5ms) INSERT INTO "products" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2020-04-30 15:04:05.630441"], ["updated_at", "2020-04-30 15:04:05.630441"]]
194
- CategoryItem Create (0.2ms) INSERT INTO "category_items" ("category_id", "product_id", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["category_id", 322908140], ["product_id", 469160772], ["created_at", "2020-04-30 15:04:05.631920"], ["updated_at", "2020-04-30 15:04:05.631920"]]
195
-  (0.0ms) RELEASE SAVEPOINT active_record_1
196
- [ActiveJob] Product Load (0.1ms) SELECT "products".* FROM "products" WHERE "products"."id" = ? LIMIT ? [["id", 469160772], ["LIMIT", 1]]
197
- [ActiveJob] [Thermos::RefillJob] [61ca40f7-8468-4777-b43a-bcef6ec7db56] Performing Thermos::RefillJob (Job ID: 61ca40f7-8468-4777-b43a-bcef6ec7db56) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb193221f0 @uri=#<URI::GID gid://dummy/Product/469160772>>
198
- [ActiveJob] [Thermos::RefillJob] [61ca40f7-8468-4777-b43a-bcef6ec7db56]  (0.1ms) SELECT "categories"."id" FROM "categories" INNER JOIN "category_items" ON "category_items"."category_id" = "categories"."id" INNER JOIN "products" ON "products"."id" = "category_items"."product_id" WHERE "products"."id" = ? [["id", 469160772]]
199
- [ActiveJob] [Thermos::RefillJob] [61ca40f7-8468-4777-b43a-bcef6ec7db56] [Thermos::RebuildCacheJob] [cb03a152-8031-42c2-a249-ce85a40b4761] Performing Thermos::RebuildCacheJob (Job ID: cb03a152-8031-42c2-a249-ce85a40b4761) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: "key", 322908140
200
- [ActiveJob] [Thermos::RefillJob] [61ca40f7-8468-4777-b43a-bcef6ec7db56] [Thermos::RebuildCacheJob] [cb03a152-8031-42c2-a249-ce85a40b4761] Performed Thermos::RebuildCacheJob (Job ID: cb03a152-8031-42c2-a249-ce85a40b4761) from Inline(default) in 1.55ms
201
- [ActiveJob] [Thermos::RefillJob] [61ca40f7-8468-4777-b43a-bcef6ec7db56] Enqueued Thermos::RebuildCacheJob (Job ID: cb03a152-8031-42c2-a249-ce85a40b4761) to Inline(default) with arguments: "key", 322908140
202
- [ActiveJob] [Thermos::RefillJob] [61ca40f7-8468-4777-b43a-bcef6ec7db56] Performed Thermos::RefillJob (Job ID: 61ca40f7-8468-4777-b43a-bcef6ec7db56) from Inline(default) in 3.39ms
203
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: 61ca40f7-8468-4777-b43a-bcef6ec7db56) to Inline(default) with arguments: #<GlobalID:0x00007feb1a25c6e8 @uri=#<URI::GID gid://dummy/Product/469160772>>
204
-  (0.8ms) rollback transaction
205
-  (0.1ms) begin transaction
206
- ---------------------------------------------------------------
207
- ThermosTest: test_rebuilds_the_cache_on_belongs_to_model_change
208
- ---------------------------------------------------------------
209
- Category Load (0.2ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
210
- Store Load (0.2ms) SELECT "stores".* FROM "stores" WHERE "stores"."id" = ? LIMIT ? [["id", 868874525], ["LIMIT", 1]]
211
-  (0.1ms) SAVEPOINT active_record_1
212
- Store Update (0.3ms) UPDATE "stores" SET "name" = ?, "updated_at" = ? WHERE "stores"."id" = ? [["name", "foo"], ["updated_at", "2020-04-30 15:04:05.645579"], ["id", 868874525]]
213
-  (0.1ms) RELEASE SAVEPOINT active_record_1
214
- [ActiveJob] Store Load (0.1ms) SELECT "stores".* FROM "stores" WHERE "stores"."id" = ? LIMIT ? [["id", 868874525], ["LIMIT", 1]]
215
- [ActiveJob] [Thermos::RefillJob] [1df3f467-81ce-4bca-a154-746ce25d93a4] Performing Thermos::RefillJob (Job ID: 1df3f467-81ce-4bca-a154-746ce25d93a4) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb1ac0c3f0 @uri=#<URI::GID gid://dummy/Store/868874525>>
216
- [ActiveJob] [Thermos::RefillJob] [1df3f467-81ce-4bca-a154-746ce25d93a4]  (0.1ms) SELECT "categories"."id" FROM "categories" INNER JOIN "stores" ON "stores"."id" = "categories"."store_id" WHERE "stores"."id" = ? [["id", 868874525]]
217
- [ActiveJob] [Thermos::RefillJob] [1df3f467-81ce-4bca-a154-746ce25d93a4] [Thermos::RebuildCacheJob] [a7bf9c33-9037-4084-bbd9-fff6f854717f] Performing Thermos::RebuildCacheJob (Job ID: a7bf9c33-9037-4084-bbd9-fff6f854717f) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: "key", 322908140
218
- [ActiveJob] [Thermos::RefillJob] [1df3f467-81ce-4bca-a154-746ce25d93a4] [Thermos::RebuildCacheJob] [a7bf9c33-9037-4084-bbd9-fff6f854717f] Performed Thermos::RebuildCacheJob (Job ID: a7bf9c33-9037-4084-bbd9-fff6f854717f) from Inline(default) in 0.86ms
219
- [ActiveJob] [Thermos::RefillJob] [1df3f467-81ce-4bca-a154-746ce25d93a4] Enqueued Thermos::RebuildCacheJob (Job ID: a7bf9c33-9037-4084-bbd9-fff6f854717f) to Inline(default) with arguments: "key", 322908140
220
- [ActiveJob] [Thermos::RefillJob] [1df3f467-81ce-4bca-a154-746ce25d93a4] Performed Thermos::RefillJob (Job ID: 1df3f467-81ce-4bca-a154-746ce25d93a4) from Inline(default) in 2.32ms
221
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: 1df3f467-81ce-4bca-a154-746ce25d93a4) to Inline(default) with arguments: #<GlobalID:0x00007feb1abf6938 @uri=#<URI::GID gid://dummy/Store/868874525>>
222
-  (1.0ms) rollback transaction
223
-  (0.1ms) begin transaction
224
- -------------------------------------------------------------------------------------
225
- ThermosTest: test_does_not_rebuild_the_cache_for_an_unrelated_belongs_to_model_change
226
- -------------------------------------------------------------------------------------
227
- Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
228
-  (0.1ms) SAVEPOINT active_record_1
229
- Store Create (0.4ms) INSERT INTO "stores" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2020-04-30 15:04:05.655344"], ["updated_at", "2020-04-30 15:04:05.655344"]]
230
-  (0.0ms) RELEASE SAVEPOINT active_record_1
231
- [ActiveJob] Store Load (0.1ms) SELECT "stores".* FROM "stores" WHERE "stores"."id" = ? LIMIT ? [["id", 868874526], ["LIMIT", 1]]
232
- [ActiveJob] [Thermos::RefillJob] [4296e01e-d6eb-4aa8-9199-355bdb518569] Performing Thermos::RefillJob (Job ID: 4296e01e-d6eb-4aa8-9199-355bdb518569) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb1abcd1c8 @uri=#<URI::GID gid://dummy/Store/868874526>>
233
- [ActiveJob] [Thermos::RefillJob] [4296e01e-d6eb-4aa8-9199-355bdb518569] Performed Thermos::RefillJob (Job ID: 4296e01e-d6eb-4aa8-9199-355bdb518569) from Inline(default) in 0.05ms
234
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: 4296e01e-d6eb-4aa8-9199-355bdb518569) to Inline(default) with arguments: #<GlobalID:0x00007feb1abbfe38 @uri=#<URI::GID gid://dummy/Store/868874526>>
235
-  (0.1ms) SAVEPOINT active_record_1
236
- Store Update (0.1ms) UPDATE "stores" SET "name" = ?, "updated_at" = ? WHERE "stores"."id" = ? [["name", "foo"], ["updated_at", "2020-04-30 15:04:05.660458"], ["id", 868874526]]
237
-  (0.1ms) RELEASE SAVEPOINT active_record_1
238
- [ActiveJob] Store Load (0.1ms) SELECT "stores".* FROM "stores" WHERE "stores"."id" = ? LIMIT ? [["id", 868874526], ["LIMIT", 1]]
239
- [ActiveJob] [Thermos::RefillJob] [59a14c90-6fa9-47ea-a3b0-ab69fa60f5f9] Performing Thermos::RefillJob (Job ID: 59a14c90-6fa9-47ea-a3b0-ab69fa60f5f9) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb1ab8dd70 @uri=#<URI::GID gid://dummy/Store/868874526>>
240
- [ActiveJob] [Thermos::RefillJob] [59a14c90-6fa9-47ea-a3b0-ab69fa60f5f9]  (0.1ms) SELECT "categories"."id" FROM "categories" INNER JOIN "stores" ON "stores"."id" = "categories"."store_id" WHERE "stores"."id" = ? [["id", 868874526]]
241
- [ActiveJob] [Thermos::RefillJob] [59a14c90-6fa9-47ea-a3b0-ab69fa60f5f9] Performed Thermos::RefillJob (Job ID: 59a14c90-6fa9-47ea-a3b0-ab69fa60f5f9) from Inline(default) in 0.92ms
242
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: 59a14c90-6fa9-47ea-a3b0-ab69fa60f5f9) to Inline(default) with arguments: #<GlobalID:0x00007feb19299558 @uri=#<URI::GID gid://dummy/Store/868874526>>
243
-  (0.6ms) rollback transaction
244
-  (0.1ms) begin transaction
245
- --------------------------------------------------------------
246
- ThermosTest: test_re-builds_the_cache_for_new_has_many_records
247
- --------------------------------------------------------------
248
- Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
249
-  (0.1ms) SAVEPOINT active_record_1
250
- CategoryItem Create (0.5ms) INSERT INTO "category_items" ("category_id", "created_at", "updated_at") VALUES (?, ?, ?) [["category_id", 322908140], ["created_at", "2020-04-30 15:04:05.669235"], ["updated_at", "2020-04-30 15:04:05.669235"]]
251
-  (0.0ms) RELEASE SAVEPOINT active_record_1
252
- [ActiveJob] CategoryItem Load (0.2ms) SELECT "category_items".* FROM "category_items" WHERE "category_items"."id" = ? LIMIT ? [["id", 678302811], ["LIMIT", 1]]
253
- [ActiveJob] [Thermos::RefillJob] [b09d0df7-2b2a-4b86-a5b5-61b24e3e5fe0] Performing Thermos::RefillJob (Job ID: b09d0df7-2b2a-4b86-a5b5-61b24e3e5fe0) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb19b825e8 @uri=#<URI::GID gid://dummy/CategoryItem/678302811>>
254
- [ActiveJob] [Thermos::RefillJob] [b09d0df7-2b2a-4b86-a5b5-61b24e3e5fe0]  (0.1ms) SELECT "categories"."id" FROM "categories" INNER JOIN "category_items" ON "category_items"."category_id" = "categories"."id" WHERE "category_items"."id" = ? [["id", 678302811]]
255
- [ActiveJob] [Thermos::RefillJob] [b09d0df7-2b2a-4b86-a5b5-61b24e3e5fe0] [Thermos::RebuildCacheJob] [d0df963d-c7bc-44b3-84a6-59115a455682] Performing Thermos::RebuildCacheJob (Job ID: d0df963d-c7bc-44b3-84a6-59115a455682) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: "key", 322908140
256
- [ActiveJob] [Thermos::RefillJob] [b09d0df7-2b2a-4b86-a5b5-61b24e3e5fe0] [Thermos::RebuildCacheJob] [d0df963d-c7bc-44b3-84a6-59115a455682] Performed Thermos::RebuildCacheJob (Job ID: d0df963d-c7bc-44b3-84a6-59115a455682) from Inline(default) in 2.04ms
257
- [ActiveJob] [Thermos::RefillJob] [b09d0df7-2b2a-4b86-a5b5-61b24e3e5fe0] Enqueued Thermos::RebuildCacheJob (Job ID: d0df963d-c7bc-44b3-84a6-59115a455682) to Inline(default) with arguments: "key", 322908140
258
- [ActiveJob] [Thermos::RefillJob] [b09d0df7-2b2a-4b86-a5b5-61b24e3e5fe0] Performed Thermos::RefillJob (Job ID: b09d0df7-2b2a-4b86-a5b5-61b24e3e5fe0) from Inline(default) in 3.58ms
259
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: b09d0df7-2b2a-4b86-a5b5-61b24e3e5fe0) to Inline(default) with arguments: #<GlobalID:0x00007feb1ab1d930 @uri=#<URI::GID gid://dummy/CategoryItem/678302811>>
260
-  (0.5ms) rollback transaction
261
-  (0.0ms) begin transaction
262
- ---------------------------------------------------------------------------------------------------------------------------
263
- ThermosTest: test_only_rebuilds_cache_for_stated_dependencies,_even_if_another_cache_has_an_associated_model_of_the_primary
264
- ---------------------------------------------------------------------------------------------------------------------------
265
- Category Load (0.2ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
266
- Product Load (0.1ms) SELECT "products".* FROM "products" WHERE "products"."id" = ? LIMIT ? [["id", 469160771], ["LIMIT", 1]]
267
-  (0.1ms) SAVEPOINT active_record_1
268
- Product Update (0.4ms) UPDATE "products" SET "name" = ?, "updated_at" = ? WHERE "products"."id" = ? [["name", "foo"], ["updated_at", "2020-04-30 15:04:05.681843"], ["id", 469160771]]
269
-  (0.1ms) RELEASE SAVEPOINT active_record_1
270
- [ActiveJob] Product Load (0.1ms) SELECT "products".* FROM "products" WHERE "products"."id" = ? LIMIT ? [["id", 469160771], ["LIMIT", 1]]
271
- [ActiveJob] [Thermos::RefillJob] [04f6a413-66c0-4439-aa70-4399d2ac0989] Performing Thermos::RefillJob (Job ID: 04f6a413-66c0-4439-aa70-4399d2ac0989) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb19ace548 @uri=#<URI::GID gid://dummy/Product/469160771>>
272
- [ActiveJob] [Thermos::RefillJob] [04f6a413-66c0-4439-aa70-4399d2ac0989] [Thermos::RebuildCacheJob] [c0899b8b-b9c3-4177-8a81-126eb7a3ed91] Performing Thermos::RebuildCacheJob (Job ID: c0899b8b-b9c3-4177-8a81-126eb7a3ed91) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: "product_key", 469160771
273
- [ActiveJob] [Thermos::RefillJob] [04f6a413-66c0-4439-aa70-4399d2ac0989] [Thermos::RebuildCacheJob] [c0899b8b-b9c3-4177-8a81-126eb7a3ed91] Performed Thermos::RebuildCacheJob (Job ID: c0899b8b-b9c3-4177-8a81-126eb7a3ed91) from Inline(default) in 2.06ms
274
- [ActiveJob] [Thermos::RefillJob] [04f6a413-66c0-4439-aa70-4399d2ac0989] Enqueued Thermos::RebuildCacheJob (Job ID: c0899b8b-b9c3-4177-8a81-126eb7a3ed91) to Inline(default) with arguments: "product_key", 469160771
275
- [ActiveJob] [Thermos::RefillJob] [04f6a413-66c0-4439-aa70-4399d2ac0989] Performed Thermos::RefillJob (Job ID: 04f6a413-66c0-4439-aa70-4399d2ac0989) from Inline(default) in 2.89ms
276
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: 04f6a413-66c0-4439-aa70-4399d2ac0989) to Inline(default) with arguments: #<GlobalID:0x00007feb19ab6970 @uri=#<URI::GID gid://dummy/Product/469160771>>
277
-  (0.6ms) rollback transaction
278
-  (0.1ms) begin transaction
279
- -----------------------------------------------------------------------------------
280
- ThermosTest: test_does_not_rebuild_the_cache_for_an_unrelated_has_many_model_change
281
- -----------------------------------------------------------------------------------
282
- Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
283
-  (0.1ms) SAVEPOINT active_record_1
284
- CategoryItem Create (0.4ms) INSERT INTO "category_items" ("created_at", "updated_at") VALUES (?, ?) [["created_at", "2020-04-30 15:04:05.692625"], ["updated_at", "2020-04-30 15:04:05.692625"]]
285
-  (0.1ms) RELEASE SAVEPOINT active_record_1
286
- [ActiveJob] CategoryItem Load (0.1ms) SELECT "category_items".* FROM "category_items" WHERE "category_items"."id" = ? LIMIT ? [["id", 678302811], ["LIMIT", 1]]
287
- [ActiveJob] [Thermos::RefillJob] [ce432d2c-a837-4e0d-9599-a5703e01ac6e] Performing Thermos::RefillJob (Job ID: ce432d2c-a837-4e0d-9599-a5703e01ac6e) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb1aa44ba8 @uri=#<URI::GID gid://dummy/CategoryItem/678302811>>
288
- [ActiveJob] [Thermos::RefillJob] [ce432d2c-a837-4e0d-9599-a5703e01ac6e] Performed Thermos::RefillJob (Job ID: ce432d2c-a837-4e0d-9599-a5703e01ac6e) from Inline(default) in 0.06ms
289
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: ce432d2c-a837-4e0d-9599-a5703e01ac6e) to Inline(default) with arguments: #<GlobalID:0x00007feb1917aa28 @uri=#<URI::GID gid://dummy/CategoryItem/678302811>>
290
-  (0.1ms) SAVEPOINT active_record_1
291
- CategoryItem Update (0.1ms) UPDATE "category_items" SET "name" = ?, "updated_at" = ? WHERE "category_items"."id" = ? [["name", "foo"], ["updated_at", "2020-04-30 15:04:05.697602"], ["id", 678302811]]
292
-  (0.1ms) RELEASE SAVEPOINT active_record_1
293
- [ActiveJob] CategoryItem Load (0.1ms) SELECT "category_items".* FROM "category_items" WHERE "category_items"."id" = ? LIMIT ? [["id", 678302811], ["LIMIT", 1]]
294
- [ActiveJob] [Thermos::RefillJob] [d9346926-4e69-4530-afd9-def9a7bb823f] Performing Thermos::RefillJob (Job ID: d9346926-4e69-4530-afd9-def9a7bb823f) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb1a99f248 @uri=#<URI::GID gid://dummy/CategoryItem/678302811>>
295
- [ActiveJob] [Thermos::RefillJob] [d9346926-4e69-4530-afd9-def9a7bb823f]  (0.1ms) SELECT "categories"."id" FROM "categories" INNER JOIN "category_items" ON "category_items"."category_id" = "categories"."id" WHERE "category_items"."id" = ? [["id", 678302811]]
296
- [ActiveJob] [Thermos::RefillJob] [d9346926-4e69-4530-afd9-def9a7bb823f] Performed Thermos::RefillJob (Job ID: d9346926-4e69-4530-afd9-def9a7bb823f) from Inline(default) in 0.84ms
297
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: d9346926-4e69-4530-afd9-def9a7bb823f) to Inline(default) with arguments: #<GlobalID:0x00007feb1996e748 @uri=#<URI::GID gid://dummy/CategoryItem/678302811>>
298
-  (3.9ms) rollback transaction
299
-  (0.0ms) begin transaction
300
- --------------------------------------------------------------------------------
301
- ThermosTest: test_does_not_rebuild_the_cache_on_rolled_back_primary_model_change
302
- --------------------------------------------------------------------------------
303
- Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
304
-  (0.1ms) SAVEPOINT active_record_1
305
- Category Update (0.4ms) UPDATE "categories" SET "name" = ?, "updated_at" = ? WHERE "categories"."id" = ? [["name", "foo"], ["updated_at", "2020-04-30 15:04:05.710144"], ["id", 322908140]]
306
-  (0.1ms) ROLLBACK TO SAVEPOINT active_record_1
307
-  (0.4ms) rollback transaction
308
-  (0.1ms) begin transaction
309
- -------------------------------------------------------------
310
- ThermosTest: test_rebuilds_the_cache_on_has_many_model_change
311
- -------------------------------------------------------------
312
- Category Load (0.1ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908140], ["LIMIT", 1]]
313
- CategoryItem Load (0.0ms) SELECT "category_items".* FROM "category_items" WHERE "category_items"."id" = ? LIMIT ? [["id", 678302810], ["LIMIT", 1]]
314
-  (0.1ms) SAVEPOINT active_record_1
315
- CategoryItem Update (0.8ms) UPDATE "category_items" SET "name" = ?, "updated_at" = ? WHERE "category_items"."id" = ? [["name", "foo"], ["updated_at", "2020-04-30 15:04:05.716752"], ["id", 678302810]]
316
-  (0.1ms) RELEASE SAVEPOINT active_record_1
317
- [ActiveJob] CategoryItem Load (0.0ms) SELECT "category_items".* FROM "category_items" WHERE "category_items"."id" = ? LIMIT ? [["id", 678302810], ["LIMIT", 1]]
318
- [ActiveJob] [Thermos::RefillJob] [bf6ec42d-ee2b-44c4-b7ae-768624b8f2cb] Performing Thermos::RefillJob (Job ID: bf6ec42d-ee2b-44c4-b7ae-768624b8f2cb) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb194c28c0 @uri=#<URI::GID gid://dummy/CategoryItem/678302810>>
319
- [ActiveJob] [Thermos::RefillJob] [bf6ec42d-ee2b-44c4-b7ae-768624b8f2cb]  (0.0ms) SELECT "categories"."id" FROM "categories" INNER JOIN "category_items" ON "category_items"."category_id" = "categories"."id" WHERE "category_items"."id" = ? [["id", 678302810]]
320
- [ActiveJob] [Thermos::RefillJob] [bf6ec42d-ee2b-44c4-b7ae-768624b8f2cb] [Thermos::RebuildCacheJob] [ad819419-1502-40a6-9723-9e303d6d144b] Performing Thermos::RebuildCacheJob (Job ID: ad819419-1502-40a6-9723-9e303d6d144b) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: "key", 322908140
321
- [ActiveJob] [Thermos::RefillJob] [bf6ec42d-ee2b-44c4-b7ae-768624b8f2cb] [Thermos::RebuildCacheJob] [ad819419-1502-40a6-9723-9e303d6d144b] Performed Thermos::RebuildCacheJob (Job ID: ad819419-1502-40a6-9723-9e303d6d144b) from Inline(default) in 0.69ms
322
- [ActiveJob] [Thermos::RefillJob] [bf6ec42d-ee2b-44c4-b7ae-768624b8f2cb] Enqueued Thermos::RebuildCacheJob (Job ID: ad819419-1502-40a6-9723-9e303d6d144b) to Inline(default) with arguments: "key", 322908140
323
- [ActiveJob] [Thermos::RefillJob] [bf6ec42d-ee2b-44c4-b7ae-768624b8f2cb] Performed Thermos::RefillJob (Job ID: bf6ec42d-ee2b-44c4-b7ae-768624b8f2cb) from Inline(default) in 1.63ms
324
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: bf6ec42d-ee2b-44c4-b7ae-768624b8f2cb) to Inline(default) with arguments: #<GlobalID:0x00007feb194b8438 @uri=#<URI::GID gid://dummy/CategoryItem/678302810>>
325
-  (0.4ms) rollback transaction
326
-  (0.1ms) begin transaction
327
- ----------------------------------------------------------------
328
- ThermosTest: test_pre-builds_cache_for_new_primary_model_records
329
- ----------------------------------------------------------------
330
-  (0.1ms) SAVEPOINT active_record_1
331
- Category Create (0.5ms) INSERT INTO "categories" ("name", "created_at", "updated_at") VALUES (?, ?, ?) [["name", "foo"], ["created_at", "2020-04-30 15:04:05.723711"], ["updated_at", "2020-04-30 15:04:05.723711"]]
332
-  (0.1ms) RELEASE SAVEPOINT active_record_1
333
- [ActiveJob] Category Load (0.2ms) SELECT "categories".* FROM "categories" WHERE "categories"."id" = ? LIMIT ? [["id", 322908141], ["LIMIT", 1]]
334
- [ActiveJob] [Thermos::RefillJob] [7214a2fa-b23f-443d-9112-ef907c60c0c4] Performing Thermos::RefillJob (Job ID: 7214a2fa-b23f-443d-9112-ef907c60c0c4) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: #<GlobalID:0x00007feb1ae14a80 @uri=#<URI::GID gid://dummy/Category/322908141>>
335
- [ActiveJob] [Thermos::RefillJob] [7214a2fa-b23f-443d-9112-ef907c60c0c4] [Thermos::RebuildCacheJob] [d5916426-2b2a-4a73-aae8-b0e415bf8822] Performing Thermos::RebuildCacheJob (Job ID: d5916426-2b2a-4a73-aae8-b0e415bf8822) from Inline(default) enqueued at 2020-04-30T15:04:05Z with arguments: "key", "foo"
336
- [ActiveJob] [Thermos::RefillJob] [7214a2fa-b23f-443d-9112-ef907c60c0c4] [Thermos::RebuildCacheJob] [d5916426-2b2a-4a73-aae8-b0e415bf8822] Performed Thermos::RebuildCacheJob (Job ID: d5916426-2b2a-4a73-aae8-b0e415bf8822) from Inline(default) in 1.98ms
337
- [ActiveJob] [Thermos::RefillJob] [7214a2fa-b23f-443d-9112-ef907c60c0c4] Enqueued Thermos::RebuildCacheJob (Job ID: d5916426-2b2a-4a73-aae8-b0e415bf8822) to Inline(default) with arguments: "key", "foo"
338
- [ActiveJob] [Thermos::RefillJob] [7214a2fa-b23f-443d-9112-ef907c60c0c4] Performed Thermos::RefillJob (Job ID: 7214a2fa-b23f-443d-9112-ef907c60c0c4) from Inline(default) in 2.59ms
339
- [ActiveJob] Enqueued Thermos::RefillJob (Job ID: 7214a2fa-b23f-443d-9112-ef907c60c0c4) to Inline(default) with arguments: #<GlobalID:0x00007feb1a316ea8 @uri=#<URI::GID gid://dummy/Category/322908141>>
340
-  (0.6ms) rollback transaction