torque-postgresql 4.0.0 → 4.1.0
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/Rakefile +24 -0
- data/lib/torque/postgresql/adapter/database_statements.rb +89 -7
- data/lib/torque/postgresql/adapter/inheritance_statements.rb +297 -0
- data/lib/torque/postgresql/adapter/oid/array.rb +17 -0
- data/lib/torque/postgresql/adapter/oid/box.rb +1 -1
- data/lib/torque/postgresql/adapter/oid/circle.rb +1 -1
- data/lib/torque/postgresql/adapter/oid/composite.rb +116 -0
- data/lib/torque/postgresql/adapter/oid/line.rb +1 -1
- data/lib/torque/postgresql/adapter/oid/lquery.rb +53 -0
- data/lib/torque/postgresql/adapter/oid/ltree.rb +53 -0
- data/lib/torque/postgresql/adapter/oid/segment.rb +1 -1
- data/lib/torque/postgresql/adapter/oid/struct.rb +150 -0
- data/lib/torque/postgresql/adapter/oid/struct_list.rb +52 -0
- data/lib/torque/postgresql/adapter/oid/struct_set.rb +38 -0
- data/lib/torque/postgresql/adapter/quoting.rb +11 -2
- data/lib/torque/postgresql/adapter/schema_definitions.rb +46 -0
- data/lib/torque/postgresql/adapter/schema_dumper.rb +28 -2
- data/lib/torque/postgresql/adapter/schema_statements.rb +207 -0
- data/lib/torque/postgresql/adapter.rb +2 -5
- data/lib/torque/postgresql/arel/nodes.rb +63 -1
- data/lib/torque/postgresql/arel/visitors.rb +19 -8
- data/lib/torque/postgresql/associations/join_dependency.rb +55 -0
- data/lib/torque/postgresql/associations.rb +3 -0
- data/lib/torque/postgresql/attributes/base.rb +94 -0
- data/lib/torque/postgresql/attributes/composite.rb +102 -0
- data/lib/torque/postgresql/attributes/enum.rb +13 -2
- data/lib/torque/postgresql/attributes/lquery.rb +180 -0
- data/lib/torque/postgresql/attributes/ltree.rb +169 -0
- data/lib/torque/postgresql/attributes/simple_enum.rb +72 -0
- data/lib/torque/postgresql/attributes/struct.rb +137 -0
- data/lib/torque/postgresql/base.rb +17 -14
- data/lib/torque/postgresql/config.rb +81 -14
- data/lib/torque/postgresql/inheritance/expander.rb +66 -0
- data/lib/torque/postgresql/inheritance/record.rb +52 -0
- data/lib/torque/postgresql/inheritance.rb +138 -65
- data/lib/torque/postgresql/migration/command_recorder.rb +76 -0
- data/lib/torque/postgresql/predicate_builder/composite_handler.rb +109 -0
- data/lib/torque/postgresql/predicate_builder/ltree_handler.rb +44 -0
- data/lib/torque/postgresql/predicate_builder/struct_handler.rb +68 -0
- data/lib/torque/postgresql/predicate_builder.rb +26 -0
- data/lib/torque/postgresql/predicate_table.rb +61 -0
- data/lib/torque/postgresql/railtie.rb +35 -0
- data/lib/torque/postgresql/relation/inheritance.rb +146 -28
- data/lib/torque/postgresql/relation/join_series.rb +8 -6
- data/lib/torque/postgresql/relation/merger.rb +23 -7
- data/lib/torque/postgresql/relation.rb +12 -11
- data/lib/torque/postgresql/schema_cache.rb +1 -0
- data/lib/torque/postgresql/validations.rb +29 -0
- data/lib/torque/postgresql/version.rb +1 -1
- data/lib/torque/postgresql/versioned_commands/command_migration.rb +1 -1
- data/lib/torque/postgresql.rb +6 -0
- data/spec/initialize.rb +20 -2
- data/spec/mocks/cache_query.rb +12 -0
- data/spec/models/author.rb +1 -1
- data/spec/models/comment.rb +2 -0
- data/spec/models/place.rb +2 -0
- data/spec/models/profile.rb +31 -0
- data/spec/schema.rb +34 -4
- data/spec/tests/arel_spec.rb +5 -3
- data/spec/tests/composite_spec.rb +800 -0
- data/spec/tests/ltree_spec.rb +552 -0
- data/spec/tests/struct_spec.rb +968 -0
- data/spec/tests/table_inheritance_spec.rb +1027 -56
- metadata +49 -7
metadata
CHANGED
|
@@ -1,14 +1,13 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: torque-postgresql
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 4.
|
|
4
|
+
version: 4.1.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Carlos Silva
|
|
8
|
-
autorequire:
|
|
9
8
|
bindir: bin
|
|
10
9
|
cert_chain: []
|
|
11
|
-
date:
|
|
10
|
+
date: 2026-08-14 00:00:00.000000000 Z
|
|
12
11
|
dependencies:
|
|
13
12
|
- !ruby/object:Gem::Dependency
|
|
14
13
|
name: rails
|
|
@@ -38,6 +37,20 @@ dependencies:
|
|
|
38
37
|
- - ">="
|
|
39
38
|
- !ruby/object:Gem::Version
|
|
40
39
|
version: '1.2'
|
|
40
|
+
- !ruby/object:Gem::Dependency
|
|
41
|
+
name: ostruct
|
|
42
|
+
requirement: !ruby/object:Gem::Requirement
|
|
43
|
+
requirements:
|
|
44
|
+
- - ">="
|
|
45
|
+
- !ruby/object:Gem::Version
|
|
46
|
+
version: '0.6'
|
|
47
|
+
type: :runtime
|
|
48
|
+
prerelease: false
|
|
49
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
50
|
+
requirements:
|
|
51
|
+
- - ">="
|
|
52
|
+
- !ruby/object:Gem::Version
|
|
53
|
+
version: '0.6'
|
|
41
54
|
- !ruby/object:Gem::Dependency
|
|
42
55
|
name: rake
|
|
43
56
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -143,16 +156,23 @@ files:
|
|
|
143
156
|
- lib/torque/postgresql.rb
|
|
144
157
|
- lib/torque/postgresql/adapter.rb
|
|
145
158
|
- lib/torque/postgresql/adapter/database_statements.rb
|
|
159
|
+
- lib/torque/postgresql/adapter/inheritance_statements.rb
|
|
146
160
|
- lib/torque/postgresql/adapter/oid.rb
|
|
147
161
|
- lib/torque/postgresql/adapter/oid/array.rb
|
|
148
162
|
- lib/torque/postgresql/adapter/oid/box.rb
|
|
149
163
|
- lib/torque/postgresql/adapter/oid/circle.rb
|
|
164
|
+
- lib/torque/postgresql/adapter/oid/composite.rb
|
|
150
165
|
- lib/torque/postgresql/adapter/oid/enum.rb
|
|
151
166
|
- lib/torque/postgresql/adapter/oid/enum_set.rb
|
|
152
167
|
- lib/torque/postgresql/adapter/oid/interval.rb
|
|
153
168
|
- lib/torque/postgresql/adapter/oid/line.rb
|
|
169
|
+
- lib/torque/postgresql/adapter/oid/lquery.rb
|
|
170
|
+
- lib/torque/postgresql/adapter/oid/ltree.rb
|
|
154
171
|
- lib/torque/postgresql/adapter/oid/range.rb
|
|
155
172
|
- lib/torque/postgresql/adapter/oid/segment.rb
|
|
173
|
+
- lib/torque/postgresql/adapter/oid/struct.rb
|
|
174
|
+
- lib/torque/postgresql/adapter/oid/struct_list.rb
|
|
175
|
+
- lib/torque/postgresql/adapter/oid/struct_set.rb
|
|
156
176
|
- lib/torque/postgresql/adapter/quoting.rb
|
|
157
177
|
- lib/torque/postgresql/adapter/schema_creation.rb
|
|
158
178
|
- lib/torque/postgresql/adapter/schema_definitions.rb
|
|
@@ -173,19 +193,26 @@ files:
|
|
|
173
193
|
- lib/torque/postgresql/associations/builder/belongs_to_many.rb
|
|
174
194
|
- lib/torque/postgresql/associations/builder/has_many.rb
|
|
175
195
|
- lib/torque/postgresql/associations/foreign_association.rb
|
|
196
|
+
- lib/torque/postgresql/associations/join_dependency.rb
|
|
176
197
|
- lib/torque/postgresql/associations/preloader.rb
|
|
177
198
|
- lib/torque/postgresql/associations/preloader/association.rb
|
|
178
199
|
- lib/torque/postgresql/associations/preloader/loader_query.rb
|
|
179
200
|
- lib/torque/postgresql/attributes.rb
|
|
201
|
+
- lib/torque/postgresql/attributes/base.rb
|
|
180
202
|
- lib/torque/postgresql/attributes/builder.rb
|
|
181
203
|
- lib/torque/postgresql/attributes/builder/enum.rb
|
|
182
204
|
- lib/torque/postgresql/attributes/builder/full_text_search.rb
|
|
183
205
|
- lib/torque/postgresql/attributes/builder/period.rb
|
|
206
|
+
- lib/torque/postgresql/attributes/composite.rb
|
|
184
207
|
- lib/torque/postgresql/attributes/enum.rb
|
|
185
208
|
- lib/torque/postgresql/attributes/enum_set.rb
|
|
186
209
|
- lib/torque/postgresql/attributes/full_text_search.rb
|
|
187
210
|
- lib/torque/postgresql/attributes/lazy.rb
|
|
211
|
+
- lib/torque/postgresql/attributes/lquery.rb
|
|
212
|
+
- lib/torque/postgresql/attributes/ltree.rb
|
|
188
213
|
- lib/torque/postgresql/attributes/period.rb
|
|
214
|
+
- lib/torque/postgresql/attributes/simple_enum.rb
|
|
215
|
+
- lib/torque/postgresql/attributes/struct.rb
|
|
189
216
|
- lib/torque/postgresql/autosave_association.rb
|
|
190
217
|
- lib/torque/postgresql/auxiliary_statement.rb
|
|
191
218
|
- lib/torque/postgresql/auxiliary_statement/recursive.rb
|
|
@@ -197,14 +224,20 @@ files:
|
|
|
197
224
|
- lib/torque/postgresql/geometry_builder.rb
|
|
198
225
|
- lib/torque/postgresql/i18n.rb
|
|
199
226
|
- lib/torque/postgresql/inheritance.rb
|
|
227
|
+
- lib/torque/postgresql/inheritance/expander.rb
|
|
228
|
+
- lib/torque/postgresql/inheritance/record.rb
|
|
200
229
|
- lib/torque/postgresql/insert_all.rb
|
|
201
230
|
- lib/torque/postgresql/migration.rb
|
|
202
231
|
- lib/torque/postgresql/migration/command_recorder.rb
|
|
203
232
|
- lib/torque/postgresql/predicate_builder.rb
|
|
204
233
|
- lib/torque/postgresql/predicate_builder/arel_attribute_handler.rb
|
|
205
234
|
- lib/torque/postgresql/predicate_builder/array_handler.rb
|
|
235
|
+
- lib/torque/postgresql/predicate_builder/composite_handler.rb
|
|
206
236
|
- lib/torque/postgresql/predicate_builder/enumerator_lazy_handler.rb
|
|
237
|
+
- lib/torque/postgresql/predicate_builder/ltree_handler.rb
|
|
207
238
|
- lib/torque/postgresql/predicate_builder/regexp_handler.rb
|
|
239
|
+
- lib/torque/postgresql/predicate_builder/struct_handler.rb
|
|
240
|
+
- lib/torque/postgresql/predicate_table.rb
|
|
208
241
|
- lib/torque/postgresql/railtie.rb
|
|
209
242
|
- lib/torque/postgresql/reflection.rb
|
|
210
243
|
- lib/torque/postgresql/reflection/abstract_reflection.rb
|
|
@@ -225,6 +258,7 @@ files:
|
|
|
225
258
|
- lib/torque/postgresql/schema_cache/inheritance.rb
|
|
226
259
|
- lib/torque/postgresql/schema_cache/schema_reflection.rb
|
|
227
260
|
- lib/torque/postgresql/table_name.rb
|
|
261
|
+
- lib/torque/postgresql/validations.rb
|
|
228
262
|
- lib/torque/postgresql/version.rb
|
|
229
263
|
- lib/torque/postgresql/versioned_commands.rb
|
|
230
264
|
- lib/torque/postgresql/versioned_commands/command_migration.rb
|
|
@@ -264,7 +298,9 @@ files:
|
|
|
264
298
|
- spec/models/guest_comment.rb
|
|
265
299
|
- spec/models/internal/user.rb
|
|
266
300
|
- spec/models/item.rb
|
|
301
|
+
- spec/models/place.rb
|
|
267
302
|
- spec/models/post.rb
|
|
303
|
+
- spec/models/profile.rb
|
|
268
304
|
- spec/models/question.rb
|
|
269
305
|
- spec/models/question_select.rb
|
|
270
306
|
- spec/models/tag.rb
|
|
@@ -278,6 +314,7 @@ files:
|
|
|
278
314
|
- spec/tests/auxiliary_statement_spec.rb
|
|
279
315
|
- spec/tests/belongs_to_many_spec.rb
|
|
280
316
|
- spec/tests/collector_spec.rb
|
|
317
|
+
- spec/tests/composite_spec.rb
|
|
281
318
|
- spec/tests/distinct_on_spec.rb
|
|
282
319
|
- spec/tests/enum_set_spec.rb
|
|
283
320
|
- spec/tests/enum_spec.rb
|
|
@@ -288,11 +325,13 @@ files:
|
|
|
288
325
|
- spec/tests/insert_all_spec.rb
|
|
289
326
|
- spec/tests/interval_spec.rb
|
|
290
327
|
- spec/tests/lazy_spec.rb
|
|
328
|
+
- spec/tests/ltree_spec.rb
|
|
291
329
|
- spec/tests/period_spec.rb
|
|
292
330
|
- spec/tests/predicate_builder_spec.rb
|
|
293
331
|
- spec/tests/quoting_spec.rb
|
|
294
332
|
- spec/tests/relation_spec.rb
|
|
295
333
|
- spec/tests/schema_spec.rb
|
|
334
|
+
- spec/tests/struct_spec.rb
|
|
296
335
|
- spec/tests/table_inheritance_spec.rb
|
|
297
336
|
- spec/tests/versioned_commands_spec.rb
|
|
298
337
|
homepage: https://github.com/crashtech/torque-postgresql
|
|
@@ -303,7 +342,6 @@ metadata:
|
|
|
303
342
|
source_code_uri: https://github.com/crashtech/torque-postgresql
|
|
304
343
|
bug_tracker_uri: https://github.com/crashtech/torque-postgresql/issues
|
|
305
344
|
changelog_uri: https://github.com/crashtech/torque-postgresql/releases
|
|
306
|
-
post_install_message:
|
|
307
345
|
rdoc_options:
|
|
308
346
|
- "--title"
|
|
309
347
|
- Torque PostgreSQL
|
|
@@ -320,8 +358,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
320
358
|
- !ruby/object:Gem::Version
|
|
321
359
|
version: 1.8.11
|
|
322
360
|
requirements: []
|
|
323
|
-
rubygems_version: 3.
|
|
324
|
-
signing_key:
|
|
361
|
+
rubygems_version: 3.6.9
|
|
325
362
|
specification_version: 4
|
|
326
363
|
summary: ActiveRecord extension to access PostgreSQL advanced resources
|
|
327
364
|
test_files:
|
|
@@ -346,8 +383,8 @@ test_files:
|
|
|
346
383
|
- spec/mocks/create_table.rb
|
|
347
384
|
- spec/models/activity.rb
|
|
348
385
|
- spec/models/activity_book.rb
|
|
349
|
-
- spec/models/activity_post/sample.rb
|
|
350
386
|
- spec/models/activity_post.rb
|
|
387
|
+
- spec/models/activity_post/sample.rb
|
|
351
388
|
- spec/models/author.rb
|
|
352
389
|
- spec/models/author_journalist.rb
|
|
353
390
|
- spec/models/category.rb
|
|
@@ -357,7 +394,9 @@ test_files:
|
|
|
357
394
|
- spec/models/guest_comment.rb
|
|
358
395
|
- spec/models/internal/user.rb
|
|
359
396
|
- spec/models/item.rb
|
|
397
|
+
- spec/models/place.rb
|
|
360
398
|
- spec/models/post.rb
|
|
399
|
+
- spec/models/profile.rb
|
|
361
400
|
- spec/models/question.rb
|
|
362
401
|
- spec/models/question_select.rb
|
|
363
402
|
- spec/models/tag.rb
|
|
@@ -371,6 +410,7 @@ test_files:
|
|
|
371
410
|
- spec/tests/auxiliary_statement_spec.rb
|
|
372
411
|
- spec/tests/belongs_to_many_spec.rb
|
|
373
412
|
- spec/tests/collector_spec.rb
|
|
413
|
+
- spec/tests/composite_spec.rb
|
|
374
414
|
- spec/tests/distinct_on_spec.rb
|
|
375
415
|
- spec/tests/enum_set_spec.rb
|
|
376
416
|
- spec/tests/enum_spec.rb
|
|
@@ -381,10 +421,12 @@ test_files:
|
|
|
381
421
|
- spec/tests/insert_all_spec.rb
|
|
382
422
|
- spec/tests/interval_spec.rb
|
|
383
423
|
- spec/tests/lazy_spec.rb
|
|
424
|
+
- spec/tests/ltree_spec.rb
|
|
384
425
|
- spec/tests/period_spec.rb
|
|
385
426
|
- spec/tests/predicate_builder_spec.rb
|
|
386
427
|
- spec/tests/quoting_spec.rb
|
|
387
428
|
- spec/tests/relation_spec.rb
|
|
388
429
|
- spec/tests/schema_spec.rb
|
|
430
|
+
- spec/tests/struct_spec.rb
|
|
389
431
|
- spec/tests/table_inheritance_spec.rb
|
|
390
432
|
- spec/tests/versioned_commands_spec.rb
|