evt-entity_store 0.5.1.0 → 0.5.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/entity_store/entity_store.rb +6 -6
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 95e8ca849336783e8719376561f6bd074d3396bef726694980ba5e9b5a2da6fc
|
4
|
+
data.tar.gz: a0aa7a6f47a6bcb32759493a41b7774c677d125a6624ace6450559fbe46e1152
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 81278f5c291b3fcf04e00eae1ea95bd298cae36618883f9665a44ccd0d2ac0e4a8d3614d7885d28e08271a51ccd31053bff8d81dc1849f271d2e321969a37378
|
7
|
+
data.tar.gz: 7237514ce48bd5cdd499083895c2b941ad207bf8d80e8bb129426e95e2b419a7ac8087df66539d158b47745065658a85ac53cd281075101207488cd25e686522
|
@@ -75,7 +75,7 @@ module EntityStore
|
|
75
75
|
end
|
76
76
|
|
77
77
|
def get(id, include: nil, &probe_action)
|
78
|
-
logger.trace { "Getting entity (ID: #{id.inspect}, Entity Class: #{entity_class.name})" }
|
78
|
+
logger.trace(tag: :store) { "Getting entity (ID: #{id.inspect}, Entity Class: #{entity_class.name})" }
|
79
79
|
|
80
80
|
record = cache.get id
|
81
81
|
|
@@ -100,14 +100,14 @@ module EntityStore
|
|
100
100
|
)
|
101
101
|
end
|
102
102
|
|
103
|
-
logger.info { "Get entity done (ID: #{id.inspect}, Entity Class: #{entity_class.name}, Version: #{record&.version.inspect}, Time: #{record&.time.inspect})" }
|
103
|
+
logger.info(tag: :store) { "Get entity done (ID: #{id.inspect}, Entity Class: #{entity_class.name}, Version: #{record&.version.inspect}, Time: #{record&.time.inspect})" }
|
104
104
|
logger.info(tags: [:data, :entity]) { entity.pretty_inspect }
|
105
105
|
|
106
106
|
EntityCache::Record.destructure(record, include)
|
107
107
|
end
|
108
108
|
|
109
109
|
def refresh(entity, id, current_position, &probe_action)
|
110
|
-
logger.trace { "Refreshing (ID: #{id.inspect}, Entity Class: #{entity_class.name}, Current Position #{current_position.inspect})" }
|
110
|
+
logger.trace(tag: :store) { "Refreshing (ID: #{id.inspect}, Entity Class: #{entity_class.name}, Current Position #{current_position.inspect})" }
|
111
111
|
logger.trace(tags: [:data, :entity]) { entity.pretty_inspect }
|
112
112
|
|
113
113
|
stream_name = self.stream_name(id)
|
@@ -116,7 +116,7 @@ module EntityStore
|
|
116
116
|
|
117
117
|
project = projection_class.build(entity)
|
118
118
|
|
119
|
-
logger.trace { "Reading (Stream Name: #{stream_name}, Position: #{current_position}" }
|
119
|
+
logger.trace(tag: :store) { "Reading (Stream Name: #{stream_name}, Position: #{current_position}" }
|
120
120
|
reader_class.(stream_name, position: start_position, session: session) do |event_data|
|
121
121
|
project.(event_data)
|
122
122
|
current_position = event_data.position
|
@@ -125,9 +125,9 @@ module EntityStore
|
|
125
125
|
probe_action.(event_data)
|
126
126
|
end
|
127
127
|
end
|
128
|
-
logger.debug { "Read (Stream Name: #{stream_name}, Position: #{current_position.inspect})" }
|
128
|
+
logger.debug(tag: :store) { "Read (Stream Name: #{stream_name}, Position: #{current_position.inspect})" }
|
129
129
|
|
130
|
-
logger.debug { "Refreshed (ID: #{id.inspect}, Entity Class: #{entity_class.name}, Current Position: #{current_position.inspect})" }
|
130
|
+
logger.debug(tag: :store) { "Refreshed (ID: #{id.inspect}, Entity Class: #{entity_class.name}, Current Position: #{current_position.inspect})" }
|
131
131
|
logger.debug(tags: [:data, :entity]) { entity.pretty_inspect }
|
132
132
|
|
133
133
|
current_position
|