wal 0.0.8 → 0.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/wal/generators/migration.rb +3 -1
- data/lib/wal/record_watcher.rb +2 -2
- data/lib/wal/version.rb +1 -1
- data/rbi/wal.rbi +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 140043c149ae22712f4e537d5d8121ff696b2a575422ed22f76525119e096281
|
4
|
+
data.tar.gz: 64f711f0344b0849ca8400c748e26ae4d53610e3ae45c424fa8d42264ea46700
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3c84b284325e136e45759e1b0ce89c64cea25ba733828820faee04fd0cc02a6e654b323ad35490c8ebfb80a0d1cd946e39bc591bf9170b8797ee92d16978e837
|
7
|
+
data.tar.gz: fe236786f9634eb6c96aa11a6ba279c1357f1b6911fe6401a0d19f45f064ddacbee8a1c79427ee1d5b1f29deb8af057aca1dc4ad274b86c8c9ec8eab672b228e
|
@@ -10,7 +10,8 @@ module Wal
|
|
10
10
|
|
11
11
|
source_root File.expand_path("templates", __dir__)
|
12
12
|
|
13
|
-
argument :watcher, type: :string
|
13
|
+
argument :watcher, type: :string, required: true, banner: "WATCHER_CLASS", desc: "Wal Watcher class name"
|
14
|
+
class_option :columns, type: :boolean, required: false, default: false
|
14
15
|
|
15
16
|
def self.next_migration_number(dir)
|
16
17
|
::ActiveRecord::Generators::Base.next_migration_number(dir)
|
@@ -53,6 +54,7 @@ module Wal
|
|
53
54
|
.delete_callbacks
|
54
55
|
.keys
|
55
56
|
.reduce(tables) { |tables, table| tables.reverse_merge(table => []) }
|
57
|
+
.transform_values { |cols| options[:columns] ? cols : [] }
|
56
58
|
else
|
57
59
|
[]
|
58
60
|
end
|
data/lib/wal/record_watcher.rb
CHANGED
@@ -112,8 +112,8 @@ module Wal
|
|
112
112
|
#
|
113
113
|
# These strategies can be defined per transaction, and by default it will uses the memory one, and only fallback
|
114
114
|
# to the temporary table if the transaction size is roughly 2 gigabytes or more.
|
115
|
-
def aggregation_strategy(
|
116
|
-
if
|
115
|
+
def aggregation_strategy(begin_transaction_event)
|
116
|
+
if begin_transaction_event.estimated_size > 1024.pow(3) * 2
|
117
117
|
:temporary_table
|
118
118
|
else
|
119
119
|
:memory
|
data/lib/wal/version.rb
CHANGED
data/rbi/wal.rbi
CHANGED
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: wal
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.10
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Rodrigo Navarro
|
8
8
|
bindir: exe
|
9
9
|
cert_chain: []
|
10
|
-
date: 2025-
|
10
|
+
date: 2025-09-01 00:00:00.000000000 Z
|
11
11
|
dependencies:
|
12
12
|
- !ruby/object:Gem::Dependency
|
13
13
|
name: pg
|