ree_lib 1.0.84 → 1.0.85
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
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 79577e4a77cb22f4a504b2d6944064c878585a683b89c166418aa003c8fd7eb0
|
|
4
|
+
data.tar.gz: 8ac9c51bea3e5c2611049a8002d23f191ee621801d5e0582e665f5fca51dbb97
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 889a59aeae260e884cd25948b349866ec840bcdb0b85d02bd44c87cef6cdb5e72511669f86cb8f567f3a9e53fba81a85243af9469563fd0fcfbef6fb387356a9
|
|
7
|
+
data.tar.gz: 1880826420b58191ca75292f7dea4a973d3250b93c99e9530a2cafa49d79cb4a1c68be4ee96fb6c6aba19a84fc927a7d22603c4f97f63e9c8141f97aa899e6b9
|
data/Gemfile.lock
CHANGED
|
@@ -1,9 +1,8 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
ree_lib (1.0.
|
|
4
|
+
ree_lib (1.0.85)
|
|
5
5
|
binding_of_caller (~> 1.0.0)
|
|
6
|
-
fiber_scheduler (~> 0.13.0)
|
|
7
6
|
i18n (~> 1.12.0)
|
|
8
7
|
loofah (~> 2.18.0)
|
|
9
8
|
oj (~> 3.13.17)
|
|
@@ -31,7 +30,6 @@ GEM
|
|
|
31
30
|
diff-lcs (1.5.0)
|
|
32
31
|
faker (3.2.0)
|
|
33
32
|
i18n (>= 1.8.11, < 2)
|
|
34
|
-
fiber_scheduler (0.13.0)
|
|
35
33
|
hashdiff (1.0.1)
|
|
36
34
|
highline (2.0.3)
|
|
37
35
|
i18n (1.12.0)
|
|
@@ -127,18 +127,12 @@ module ReeDao
|
|
|
127
127
|
else
|
|
128
128
|
threads = associations.instance_exec(assoc_list, &block)
|
|
129
129
|
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
association.load(assoc_type, assoc_name, **__opts, &block)
|
|
134
|
-
end
|
|
135
|
-
end
|
|
130
|
+
threads[:association_threads].map do |association, assoc_type, assoc_name, __opts, block|
|
|
131
|
+
association.load(assoc_type, assoc_name, **__opts, &block)
|
|
132
|
+
end
|
|
136
133
|
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
association.handle_field(field_proc)
|
|
140
|
-
end
|
|
141
|
-
end
|
|
134
|
+
threads[:field_threads].map do |association, field_proc|
|
|
135
|
+
association.handle_field(field_proc)
|
|
142
136
|
end
|
|
143
137
|
end
|
|
144
138
|
end
|
|
@@ -355,24 +349,6 @@ module ReeDao
|
|
|
355
349
|
|
|
356
350
|
private
|
|
357
351
|
|
|
358
|
-
def task_proc(&proc)
|
|
359
|
-
if Sequel.current.is_a?(Fiber)
|
|
360
|
-
Fiber.schedule &proc
|
|
361
|
-
else
|
|
362
|
-
proc.call
|
|
363
|
-
end
|
|
364
|
-
end
|
|
365
|
-
|
|
366
|
-
def scheduler_proc(&proc)
|
|
367
|
-
if Sequel.current.is_a?(Fiber)
|
|
368
|
-
FiberScheduler do
|
|
369
|
-
Fiber.schedule(:waiting, &proc)
|
|
370
|
-
end
|
|
371
|
-
else
|
|
372
|
-
proc.call
|
|
373
|
-
end
|
|
374
|
-
end
|
|
375
|
-
|
|
376
352
|
def foreign_key_from_dao(dao)
|
|
377
353
|
"#{dao.first_source_table.to_s.gsub(/s$/, '')}_id".to_sym
|
|
378
354
|
end
|
|
@@ -64,37 +64,13 @@ class ReeDao::Agg
|
|
|
64
64
|
if dao.db.in_transaction? || ReeDao.load_sync_associations_enabled?
|
|
65
65
|
associations
|
|
66
66
|
else
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
task_proc do
|
|
70
|
-
association.load(assoc_type, assoc_name, **opts, &block)
|
|
71
|
-
end
|
|
72
|
-
end
|
|
73
|
-
|
|
74
|
-
associations[:field_threads].map do |association, field_proc|
|
|
75
|
-
task_proc do
|
|
76
|
-
association.handle_field(field_proc)
|
|
77
|
-
end
|
|
78
|
-
end
|
|
67
|
+
associations[:association_threads].map do |association, assoc_type, assoc_name, opts, block|
|
|
68
|
+
association.load(assoc_type, assoc_name, **opts, &block)
|
|
79
69
|
end
|
|
80
|
-
end
|
|
81
|
-
end
|
|
82
|
-
|
|
83
|
-
def task_proc(&proc)
|
|
84
|
-
if Sequel.current.is_a?(Fiber)
|
|
85
|
-
Fiber.schedule(&proc)
|
|
86
|
-
else
|
|
87
|
-
proc.call
|
|
88
|
-
end
|
|
89
|
-
end
|
|
90
70
|
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
FiberScheduler do
|
|
94
|
-
Fiber.schedule(:waiting, &proc)
|
|
71
|
+
associations[:field_threads].map do |association, field_proc|
|
|
72
|
+
association.handle_field(field_proc)
|
|
95
73
|
end
|
|
96
|
-
else
|
|
97
|
-
proc.call
|
|
98
74
|
end
|
|
99
75
|
end
|
|
100
76
|
end
|
data/lib/ree_lib/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: ree_lib
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.0.
|
|
4
|
+
version: 1.0.85
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ruslan Gatiyatov
|
|
@@ -122,20 +122,6 @@ dependencies:
|
|
|
122
122
|
- - "~>"
|
|
123
123
|
- !ruby/object:Gem::Version
|
|
124
124
|
version: 3.1.1
|
|
125
|
-
- !ruby/object:Gem::Dependency
|
|
126
|
-
name: fiber_scheduler
|
|
127
|
-
requirement: !ruby/object:Gem::Requirement
|
|
128
|
-
requirements:
|
|
129
|
-
- - "~>"
|
|
130
|
-
- !ruby/object:Gem::Version
|
|
131
|
-
version: 0.13.0
|
|
132
|
-
type: :runtime
|
|
133
|
-
prerelease: false
|
|
134
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
135
|
-
requirements:
|
|
136
|
-
- - "~>"
|
|
137
|
-
- !ruby/object:Gem::Version
|
|
138
|
-
version: 0.13.0
|
|
139
125
|
- !ruby/object:Gem::Dependency
|
|
140
126
|
name: rack-test
|
|
141
127
|
requirement: !ruby/object:Gem::Requirement
|