evt-entity_snapshot-postgres 0.3.1.0 → 0.3.1.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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dba9866f01756ad8ca07cbfa01471a7250fcb7ce90cdbdad11d5392c05c2ee4b
|
4
|
+
data.tar.gz: 9c2b7754f812e0c07314e699e93b701179a0ff947f8cca9159a83cfd83d7dae4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3d68393cc7f882a7e591577c9987db8e81be9594bc772b9366ea476e54026f19a879d99b294900e9e84ee8564015b91cf873ffe3ccab7bab2270198af7b1704e
|
7
|
+
data.tar.gz: 782b26f91d2fe60961170190f400664af83e24f0efbfcf63d223177d13cadeb7758a6fa656e8ccc0b150c5a81f34cda6f8b62049050592f1ae5b680e021f5a2c
|
@@ -10,12 +10,12 @@ module EntitySnapshot
|
|
10
10
|
def get(id)
|
11
11
|
stream_name = snapshot_stream_name(id)
|
12
12
|
|
13
|
-
logger.trace(tags: [:
|
13
|
+
logger.trace(tags: [:cache, :get]) { "Reading snapshot (Stream: #{stream_name.inspect}, Entity Class: #{entity_class.name})" }
|
14
14
|
|
15
15
|
event_data = read.(stream_name)
|
16
16
|
|
17
17
|
if event_data.nil?
|
18
|
-
logger.debug(tags: [:
|
18
|
+
logger.debug(tags: [:cache, :get, :missg]) { "No snapshot record (Stream: #{stream_name.inspect}, Entity Class: #{entity_class.name})" }
|
19
19
|
return
|
20
20
|
end
|
21
21
|
|
@@ -36,7 +36,7 @@ module EntitySnapshot
|
|
36
36
|
time = Time.parse(time)
|
37
37
|
end
|
38
38
|
|
39
|
-
logger.debug(tags: [:
|
39
|
+
logger.debug(tags: [:cache, :get, :hit]) { "Read snapshot (Stream: #{stream_name.inspect}, Entity Class: #{entity_class.name}, Version: #{version.inspect}, Time: #{time.utc.iso8601(3)})" }
|
40
40
|
|
41
41
|
return entity, version, time
|
42
42
|
end
|
@@ -33,7 +33,7 @@ module EntitySnapshot
|
|
33
33
|
|
34
34
|
stream_name = snapshot_stream_name(id)
|
35
35
|
|
36
|
-
logger.trace(tags: [:
|
36
|
+
logger.trace(tags: [:cache, :put]) { "Writing snapshot (Stream: #{stream_name.inspect}, Entity Class: #{entity.class.name}, Version: #{version.inspect}, Time: #{time.utc.iso8601(3)})" }
|
37
37
|
|
38
38
|
entity_data = Transform::Write.raw_data(entity)
|
39
39
|
|
@@ -52,7 +52,7 @@ module EntitySnapshot
|
|
52
52
|
|
53
53
|
position = write.(event_data, stream_name)
|
54
54
|
|
55
|
-
logger.debug(tags: [:
|
55
|
+
logger.debug(tags: [:cache, :put]) { "Wrote snapshot (Stream: #{stream_name.inspect}, Entity Class: #{entity.class.name}, Version: #{version.inspect}, Time: #{time.utc.iso8601(3)})" }
|
56
56
|
|
57
57
|
position
|
58
58
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: evt-entity_snapshot-postgres
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.1.
|
4
|
+
version: 0.3.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- The Eventide Project
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-11-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: evt-entity_store
|