dynamodb_record 0.3.5 → 0.4.1

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.
Files changed (22) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +42 -0
  3. data/lib/dynamodb_record/associations.rb +23 -21
  4. data/lib/dynamodb_record/has_and_belongs_to_many_collection.rb +26 -4
  5. data/lib/dynamodb_record/has_many_collection.rb +18 -0
  6. data/lib/dynamodb_record/persistence.rb +1 -1
  7. data/lib/dynamodb_record/version.rb +1 -1
  8. data/spec/dynamodb_record/association_spec.rb +27 -8
  9. data/spec/dynamodb_record/config_spec.rb +1 -2
  10. data/spec/dynamodb_record/query_spec.rb +1 -1
  11. data/spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_belongs_to/get_object.yml +28 -24
  12. data/spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/{has_and_belongs_to_many_create.yml → _has_and_belongs_to_many/create.yml} +68 -58
  13. data/spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_has_and_belongs_to_many/destroy.yml +322 -0
  14. data/spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_has_and_belongs_to_many/only_one_record.yml +216 -0
  15. data/spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_has_many/create_item.yml +41 -35
  16. data/spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_has_many/create_item_with_.yml +216 -0
  17. data/spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_has_many/get_collection.yml +28 -24
  18. data/spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/has_and_belongs_to_many.yml +41 -35
  19. data/spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/has_many_through.yml +28 -78
  20. data/spec/spec_helper.rb +0 -1
  21. metadata +6 -4
  22. data/spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_has_many/add_list.yml +0 -362
@@ -9,23 +9,25 @@ http_interactions:
9
9
  headers:
10
10
  Accept-Encoding:
11
11
  - ''
12
+ Amz-Sdk-Invocation-Id:
13
+ - d5480aab-96f6-4398-98fa-3a4982ccdc4e
12
14
  Content-Type:
13
15
  - application/x-amz-json-1.0
14
16
  X-Amz-Target:
15
17
  - DynamoDB_20120810.GetItem
16
18
  User-Agent:
17
- - aws-sdk-ruby3/3.191.3 ua/2.0 api/dynamodb#1.105.0 os/macos#20 md/x86_64 lang/ruby#3.2.3
19
+ - aws-sdk-ruby3/3.196.1 ua/2.0 api/dynamodb#1.111.0 os/macos#23 md/arm64 lang/ruby#3.2.3
18
20
  md/3.2.3 cfg/retry-mode#legacy
19
21
  Host:
20
22
  - localhost:8000
21
23
  X-Amz-Date:
22
- - 20240514T151134Z
24
+ - 20240531T203020Z
23
25
  X-Amz-Content-Sha256:
24
26
  - 3f40080fdb7ac1732232c14b86645a9ffbd3f94cf8ecda6b3c584d105288bb8d
25
27
  Authorization:
26
- - AWS4-HMAC-SHA256 Credential=key/20240514/us-east-1/dynamodb/aws4_request,
27
- SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
28
- Signature=6cccb1afecbb66dcb85e14eb44c76944e95b7fd912961a9925abef3d73dc5fd9
28
+ - AWS4-HMAC-SHA256 Credential=key/20240531/us-east-1/dynamodb/aws4_request,
29
+ SignedHeaders=amz-sdk-invocation-id;content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
30
+ Signature=9c6361a5da62df8a3e5ca79c37db22c4942fd817f65461a25e8aa108ec25c08e
29
31
  Content-Length:
30
32
  - '58'
31
33
  Accept:
@@ -36,21 +38,21 @@ http_interactions:
36
38
  message: OK
37
39
  headers:
38
40
  Date:
39
- - Tue, 14 May 2024 15:11:34 GMT
41
+ - Fri, 31 May 2024 20:30:20 GMT
40
42
  X-Amzn-Requestid:
41
- - 4a8b532a-472b-4aef-9955-3e3f6bcb1865
43
+ - 19bbb46e-0bcc-423a-acc3-4ab7745374a4
42
44
  Content-Type:
43
45
  - application/x-amz-json-1.0
44
46
  X-Amz-Crc32:
45
- - '590923779'
47
+ - '2965787765'
46
48
  Content-Length:
47
- - '149'
49
+ - '124'
48
50
  Server:
49
- - Jetty(11.0.17)
51
+ - Jetty(9.4.48.v20220622)
50
52
  body:
51
53
  encoding: UTF-8
52
- string: '{"Item":{"marca":{"S":"Chvrolet"},"created_at":{"S":"2024-05-07T14:09:25-05:00"},"id":{"S":"UVX455"},"updated_at":{"S":"2024-05-07T14:09:25-05:00"}}}'
53
- recorded_at: Tue, 14 May 2024 15:11:34 GMT
54
+ string: '{"Item":{"updated_at":{"S":"2024-05-31T15:29:47-05:00"},"created_at":{"S":"2024-05-31T15:29:47-05:00"},"id":{"S":"UVX455"}}}'
55
+ recorded_at: Fri, 31 May 2024 20:30:20 GMT
54
56
  - request:
55
57
  method: post
56
58
  uri: http://localhost:8000/
@@ -61,23 +63,25 @@ http_interactions:
61
63
  headers:
62
64
  Accept-Encoding:
63
65
  - ''
66
+ Amz-Sdk-Invocation-Id:
67
+ - be83b147-997e-44b9-835d-8c09b3340060
64
68
  Content-Type:
65
69
  - application/x-amz-json-1.0
66
70
  X-Amz-Target:
67
71
  - DynamoDB_20120810.Query
68
72
  User-Agent:
69
- - aws-sdk-ruby3/3.191.3 ua/2.0 api/dynamodb#1.105.0 os/macos#20 md/x86_64 lang/ruby#3.2.3
73
+ - aws-sdk-ruby3/3.196.1 ua/2.0 api/dynamodb#1.111.0 os/macos#23 md/arm64 lang/ruby#3.2.3
70
74
  md/3.2.3 cfg/retry-mode#legacy
71
75
  Host:
72
76
  - localhost:8000
73
77
  X-Amz-Date:
74
- - 20240514T151134Z
78
+ - 20240531T203020Z
75
79
  X-Amz-Content-Sha256:
76
80
  - 2fbf9fb79b236e4c2e9a9151b2960806f4b6841c9205fbe138b73cbd16ff4fee
77
81
  Authorization:
78
- - AWS4-HMAC-SHA256 Credential=key/20240514/us-east-1/dynamodb/aws4_request,
79
- SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
80
- Signature=94c1464d7e64379e71d27c201909ebc469f3808a3f93578bdd2cdddb3c150c4c
82
+ - AWS4-HMAC-SHA256 Credential=key/20240531/us-east-1/dynamodb/aws4_request,
83
+ SignedHeaders=amz-sdk-invocation-id;content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
84
+ Signature=300ef7bb58456c7033f82101578a9496667f3ea45dbe04dc669c4b7ebf101e44
81
85
  Content-Length:
82
86
  - '211'
83
87
  Accept:
@@ -88,19 +92,19 @@ http_interactions:
88
92
  message: OK
89
93
  headers:
90
94
  Date:
91
- - Tue, 14 May 2024 15:11:34 GMT
95
+ - Fri, 31 May 2024 20:30:20 GMT
92
96
  X-Amzn-Requestid:
93
- - faa50e5f-7479-49e8-9b1c-e3c2225bc5da
97
+ - 4512df20-c186-4890-bccc-493ddd3180f8
94
98
  Content-Type:
95
99
  - application/x-amz-json-1.0
96
100
  X-Amz-Crc32:
97
- - '2864220309'
101
+ - '4284377425'
98
102
  Content-Length:
99
- - '110'
103
+ - '177'
100
104
  Server:
101
- - Jetty(11.0.17)
105
+ - Jetty(9.4.48.v20220622)
102
106
  body:
103
107
  encoding: UTF-8
104
- string: '{"Items":[{"name":{"S":"Colcerautos"},"car_id":{"S":"UVX455"},"id":{"S":"12345"}}],"Count":1,"ScannedCount":1}'
105
- recorded_at: Tue, 14 May 2024 15:11:34 GMT
108
+ string: '{"Items":[{"created_at":{"S":"2024-05-31T15:29:47-05:00"},"id":{"S":"12345"},"updated_at":{"S":"2024-05-31T15:29:47-05:00"},"car_id":{"S":"UVX455"}}],"Count":1,"ScannedCount":1}'
109
+ recorded_at: Fri, 31 May 2024 20:30:20 GMT
106
110
  recorded_with: VCR 6.2.0
@@ -9,23 +9,25 @@ http_interactions:
9
9
  headers:
10
10
  Accept-Encoding:
11
11
  - ''
12
+ Amz-Sdk-Invocation-Id:
13
+ - 88cda6a4-108d-483d-bbd6-091469330007
12
14
  Content-Type:
13
15
  - application/x-amz-json-1.0
14
16
  X-Amz-Target:
15
17
  - DynamoDB_20120810.GetItem
16
18
  User-Agent:
17
- - aws-sdk-ruby3/3.191.3 ua/2.0 api/dynamodb#1.105.0 os/macos#20 md/x86_64 lang/ruby#3.2.3
19
+ - aws-sdk-ruby3/3.196.1 ua/2.0 api/dynamodb#1.111.0 os/macos#23 md/arm64 lang/ruby#3.2.3
18
20
  md/3.2.3 cfg/retry-mode#legacy
19
21
  Host:
20
22
  - localhost:8000
21
23
  X-Amz-Date:
22
- - 20240514T150706Z
24
+ - 20240531T203626Z
23
25
  X-Amz-Content-Sha256:
24
26
  - 3f40080fdb7ac1732232c14b86645a9ffbd3f94cf8ecda6b3c584d105288bb8d
25
27
  Authorization:
26
- - AWS4-HMAC-SHA256 Credential=key/20240514/us-east-1/dynamodb/aws4_request,
27
- SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
28
- Signature=06a5056ca7b7412abb28f73b8b51813f4ea4ed87b99dafd5b28902f1f81ddc1d
28
+ - AWS4-HMAC-SHA256 Credential=key/20240531/us-east-1/dynamodb/aws4_request,
29
+ SignedHeaders=amz-sdk-invocation-id;content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
30
+ Signature=f49b5c5de8739e01a29790474862b10c1351f3dbff92a75925645d2d55fa013e
29
31
  Content-Length:
30
32
  - '58'
31
33
  Accept:
@@ -36,21 +38,21 @@ http_interactions:
36
38
  message: OK
37
39
  headers:
38
40
  Date:
39
- - Tue, 14 May 2024 15:07:06 GMT
41
+ - Fri, 31 May 2024 20:36:26 GMT
40
42
  X-Amzn-Requestid:
41
- - ef6a1b97-0637-4f57-b952-e467f119059f
43
+ - f87fde27-cc17-4733-b54c-2a374bfb7eb5
42
44
  Content-Type:
43
45
  - application/x-amz-json-1.0
44
46
  X-Amz-Crc32:
45
- - '590923779'
47
+ - '2965787765'
46
48
  Content-Length:
47
- - '149'
49
+ - '124'
48
50
  Server:
49
- - Jetty(11.0.17)
51
+ - Jetty(9.4.48.v20220622)
50
52
  body:
51
53
  encoding: UTF-8
52
- string: '{"Item":{"marca":{"S":"Chvrolet"},"created_at":{"S":"2024-05-07T14:09:25-05:00"},"id":{"S":"UVX455"},"updated_at":{"S":"2024-05-07T14:09:25-05:00"}}}'
53
- recorded_at: Tue, 14 May 2024 15:07:06 GMT
54
+ string: '{"Item":{"updated_at":{"S":"2024-05-31T15:29:47-05:00"},"created_at":{"S":"2024-05-31T15:29:47-05:00"},"id":{"S":"UVX455"}}}'
55
+ recorded_at: Fri, 31 May 2024 20:36:26 GMT
54
56
  - request:
55
57
  method: post
56
58
  uri: http://localhost:8000/
@@ -61,23 +63,25 @@ http_interactions:
61
63
  headers:
62
64
  Accept-Encoding:
63
65
  - ''
66
+ Amz-Sdk-Invocation-Id:
67
+ - ad6b16a3-5e0d-4659-9746-b582242f8a2a
64
68
  Content-Type:
65
69
  - application/x-amz-json-1.0
66
70
  X-Amz-Target:
67
71
  - DynamoDB_20120810.Query
68
72
  User-Agent:
69
- - aws-sdk-ruby3/3.191.3 ua/2.0 api/dynamodb#1.105.0 os/macos#20 md/x86_64 lang/ruby#3.2.3
73
+ - aws-sdk-ruby3/3.196.1 ua/2.0 api/dynamodb#1.111.0 os/macos#23 md/arm64 lang/ruby#3.2.3
70
74
  md/3.2.3 cfg/retry-mode#legacy
71
75
  Host:
72
76
  - localhost:8000
73
77
  X-Amz-Date:
74
- - 20240514T150706Z
78
+ - 20240531T203626Z
75
79
  X-Amz-Content-Sha256:
76
80
  - cace0a22d92863fee1a25aaedd2a1d186e28b09ab69c98bf43ee1e5d1e62dc78
77
81
  Authorization:
78
- - AWS4-HMAC-SHA256 Credential=key/20240514/us-east-1/dynamodb/aws4_request,
79
- SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
80
- Signature=6b998e974e0b175cfef3301240167228ee4674b99364e0b3d6689914d7582a00
82
+ - AWS4-HMAC-SHA256 Credential=key/20240531/us-east-1/dynamodb/aws4_request,
83
+ SignedHeaders=amz-sdk-invocation-id;content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
84
+ Signature=1725a358cb00c36ed1a2b74be60a70203a0ff92f347656c4f36b64c9197eda28
81
85
  Content-Length:
82
86
  - '184'
83
87
  Accept:
@@ -88,21 +92,21 @@ http_interactions:
88
92
  message: OK
89
93
  headers:
90
94
  Date:
91
- - Tue, 14 May 2024 15:07:06 GMT
95
+ - Fri, 31 May 2024 20:36:26 GMT
92
96
  X-Amzn-Requestid:
93
- - 5105fec4-4f2d-495f-b7fd-1e4e77d422eb
97
+ - ef65a10b-e6c3-4825-b686-71f6ba51d24c
94
98
  Content-Type:
95
99
  - application/x-amz-json-1.0
96
100
  X-Amz-Crc32:
97
- - '1919856377'
101
+ - '1826001805'
98
102
  Content-Length:
99
- - '102'
103
+ - '149'
100
104
  Server:
101
- - Jetty(11.0.17)
105
+ - Jetty(9.4.48.v20220622)
102
106
  body:
103
107
  encoding: UTF-8
104
- string: '{"Items":[{"user_id":{"S":"hguzman10@gmail.com"},"car_id":{"S":"UVX455"}}],"Count":1,"ScannedCount":1}'
105
- recorded_at: Tue, 14 May 2024 15:07:06 GMT
108
+ string: '{"Items":[{"user_id":{"S":"hguzman10@gmail.com"},"car_id":{"S":"UVX455"},"created_at":{"S":"2024-05-31T15:30:20-05:00"}}],"Count":1,"ScannedCount":1}'
109
+ recorded_at: Fri, 31 May 2024 20:36:26 GMT
106
110
  - request:
107
111
  method: post
108
112
  uri: http://localhost:8000/
@@ -112,23 +116,25 @@ http_interactions:
112
116
  headers:
113
117
  Accept-Encoding:
114
118
  - ''
119
+ Amz-Sdk-Invocation-Id:
120
+ - a41f47dd-1f95-4d7e-93d9-d9e6a378d667
115
121
  Content-Type:
116
122
  - application/x-amz-json-1.0
117
123
  X-Amz-Target:
118
124
  - DynamoDB_20120810.GetItem
119
125
  User-Agent:
120
- - aws-sdk-ruby3/3.191.3 ua/2.0 api/dynamodb#1.105.0 os/macos#20 md/x86_64 lang/ruby#3.2.3
126
+ - aws-sdk-ruby3/3.196.1 ua/2.0 api/dynamodb#1.111.0 os/macos#23 md/arm64 lang/ruby#3.2.3
121
127
  md/3.2.3 cfg/retry-mode#legacy
122
128
  Host:
123
129
  - localhost:8000
124
130
  X-Amz-Date:
125
- - 20240514T150706Z
131
+ - 20240531T203626Z
126
132
  X-Amz-Content-Sha256:
127
133
  - ab20f394f9f17ab85359c8cef098ff2e93991ca4f4f9402376eaa33ea97d5545
128
134
  Authorization:
129
- - AWS4-HMAC-SHA256 Credential=key/20240514/us-east-1/dynamodb/aws4_request,
130
- SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
131
- Signature=7a77ca70c4490290987c8cc9c0c7d5828f710adb74e54e0308318765d6cb0bff
135
+ - AWS4-HMAC-SHA256 Credential=key/20240531/us-east-1/dynamodb/aws4_request,
136
+ SignedHeaders=amz-sdk-invocation-id;content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
137
+ Signature=d436539b13e26533d3a515aaf01a86c72da59cf7797a1e212a4c5bae668ce3ab
132
138
  Content-Length:
133
139
  - '72'
134
140
  Accept:
@@ -139,19 +145,19 @@ http_interactions:
139
145
  message: OK
140
146
  headers:
141
147
  Date:
142
- - Tue, 14 May 2024 15:07:06 GMT
148
+ - Fri, 31 May 2024 20:36:26 GMT
143
149
  X-Amzn-Requestid:
144
- - 89bd60ea-9f8f-4e3f-ab76-4a895bb5eb39
150
+ - d0cc0f65-40f2-4001-bd41-a1a3302cf821
145
151
  Content-Type:
146
152
  - application/x-amz-json-1.0
147
153
  X-Amz-Crc32:
148
- - '3262869781'
154
+ - '1366903316'
149
155
  Content-Length:
150
156
  - '157'
151
157
  Server:
152
- - Jetty(11.0.17)
158
+ - Jetty(9.4.48.v20220622)
153
159
  body:
154
160
  encoding: UTF-8
155
- string: '{"Item":{"created_at":{"S":"2024-05-07T14:10:09-05:00"},"id":{"S":"hguzman10@gmail.com"},"balance":{"N":"0"},"updated_at":{"S":"2024-05-07T14:10:09-05:00"}}}'
156
- recorded_at: Tue, 14 May 2024 15:07:06 GMT
161
+ string: '{"Item":{"created_at":{"S":"2024-05-31T15:29:47-05:00"},"id":{"S":"hguzman10@gmail.com"},"balance":{"N":"0"},"updated_at":{"S":"2024-05-31T15:29:47-05:00"}}}'
162
+ recorded_at: Fri, 31 May 2024 20:36:26 GMT
157
163
  recorded_with: VCR 6.2.0
@@ -9,23 +9,25 @@ http_interactions:
9
9
  headers:
10
10
  Accept-Encoding:
11
11
  - ''
12
+ Amz-Sdk-Invocation-Id:
13
+ - 011d35ed-c0d9-42ba-819f-e071f1811fb0
12
14
  Content-Type:
13
15
  - application/x-amz-json-1.0
14
16
  X-Amz-Target:
15
17
  - DynamoDB_20120810.GetItem
16
18
  User-Agent:
17
- - aws-sdk-ruby3/3.191.3 ua/2.0 api/dynamodb#1.105.0 os/macos#20 md/x86_64 lang/ruby#3.2.3
19
+ - aws-sdk-ruby3/3.196.1 ua/2.0 api/dynamodb#1.111.0 os/macos#23 md/arm64 lang/ruby#3.2.3
18
20
  md/3.2.3 cfg/retry-mode#legacy
19
21
  Host:
20
22
  - localhost:8000
21
23
  X-Amz-Date:
22
- - 20240514T150755Z
24
+ - 20240531T203020Z
23
25
  X-Amz-Content-Sha256:
24
26
  - 58ea1cd954af69b1be2d672492d299f11508b9a50931d6d41773854ad047f50f
25
27
  Authorization:
26
- - AWS4-HMAC-SHA256 Credential=key/20240514/us-east-1/dynamodb/aws4_request,
27
- SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
28
- Signature=fda5728befe377bfe63bbfd5f62a72061116fb93b6e8367174004b7449a3e98b
28
+ - AWS4-HMAC-SHA256 Credential=key/20240531/us-east-1/dynamodb/aws4_request,
29
+ SignedHeaders=amz-sdk-invocation-id;content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
30
+ Signature=9dee6d37fd24392fef3bf577a866797dfff007359b05708f50b5f7c38ff9bea7
29
31
  Content-Length:
30
32
  - '58'
31
33
  Accept:
@@ -36,24 +38,21 @@ http_interactions:
36
38
  message: OK
37
39
  headers:
38
40
  Date:
39
- - Tue, 14 May 2024 15:07:55 GMT
41
+ - Fri, 31 May 2024 20:30:20 GMT
40
42
  X-Amzn-Requestid:
41
- - 893f562b-7bc7-49d2-b5ce-65cdb1eb0faa
43
+ - 3c816bd8-0d44-465c-9b40-7bc66c6f2680
42
44
  Content-Type:
43
45
  - application/x-amz-json-1.0
44
46
  X-Amz-Crc32:
45
- - '218550687'
47
+ - '3272862184'
46
48
  Content-Length:
47
- - '385'
49
+ - '146'
48
50
  Server:
49
- - Jetty(11.0.17)
51
+ - Jetty(9.4.48.v20220622)
50
52
  body:
51
53
  encoding: UTF-8
52
- string: '{"Item":{"schedule":{"S":"Luneas a viernes"},"standby_time":{"S":"1
53
- minuto"},"helper_price":{"N":"100"},"service_price":{"N":"1000"},"updated_at":{"S":"2024-05-02T17:24:34-05:00"},"name":{"S":"Datos
54
- Basicos"},"description":{"S":"Informacion del automotor"},"created_at":{"S":"2024-05-02T17:24:34-05:00"},"id":{"S":"c1"},"fields":{"S":"placa,
55
- motor, chasis"},"activated":{"BOOL":true}}}'
56
- recorded_at: Tue, 14 May 2024 15:07:55 GMT
54
+ string: '{"Item":{"created_at":{"S":"2024-05-31T15:29:47-05:00"},"id":{"S":"c1"},"service_price":{"N":"0"},"updated_at":{"S":"2024-05-31T15:29:47-05:00"}}}'
55
+ recorded_at: Fri, 31 May 2024 20:30:20 GMT
57
56
  - request:
58
57
  method: post
59
58
  uri: http://localhost:8000/
@@ -64,23 +63,25 @@ http_interactions:
64
63
  headers:
65
64
  Accept-Encoding:
66
65
  - ''
66
+ Amz-Sdk-Invocation-Id:
67
+ - a17217c1-be26-4039-a4d7-76447479e771
67
68
  Content-Type:
68
69
  - application/x-amz-json-1.0
69
70
  X-Amz-Target:
70
71
  - DynamoDB_20120810.Query
71
72
  User-Agent:
72
- - aws-sdk-ruby3/3.191.3 ua/2.0 api/dynamodb#1.105.0 os/macos#20 md/x86_64 lang/ruby#3.2.3
73
+ - aws-sdk-ruby3/3.196.1 ua/2.0 api/dynamodb#1.111.0 os/macos#23 md/arm64 lang/ruby#3.2.3
73
74
  md/3.2.3 cfg/retry-mode#legacy
74
75
  Host:
75
76
  - localhost:8000
76
77
  X-Amz-Date:
77
- - 20240514T150755Z
78
+ - 20240531T203020Z
78
79
  X-Amz-Content-Sha256:
79
80
  - 7e4307bcc54828fddac9ef4e82db7b6a7523b3e92ea7d81617aa541348ea7378
80
81
  Authorization:
81
- - AWS4-HMAC-SHA256 Credential=key/20240514/us-east-1/dynamodb/aws4_request,
82
- SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
83
- Signature=ca1d7116ed680b7bf3ee6f3ad128eae8d23e179a16def45f00571e8899f5ae0e
82
+ - AWS4-HMAC-SHA256 Credential=key/20240531/us-east-1/dynamodb/aws4_request,
83
+ SignedHeaders=amz-sdk-invocation-id;content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
84
+ Signature=6b2e8b6aada9304ecc3dacf6c621d435fcddf7e5b26f9d5acf25ed753df508af
84
85
  Content-Length:
85
86
  - '225'
86
87
  Accept:
@@ -91,70 +92,19 @@ http_interactions:
91
92
  message: OK
92
93
  headers:
93
94
  Date:
94
- - Tue, 14 May 2024 15:07:55 GMT
95
+ - Fri, 31 May 2024 20:30:20 GMT
95
96
  X-Amzn-Requestid:
96
- - acc1366d-b324-4da8-a2c3-7f1a751af150
97
+ - a4cae398-8753-4840-8952-fcd23faf2d44
97
98
  Content-Type:
98
99
  - application/x-amz-json-1.0
99
100
  X-Amz-Crc32:
100
- - '1832468787'
101
+ - '583912891'
101
102
  Content-Length:
102
- - '121'
103
+ - '39'
103
104
  Server:
104
- - Jetty(11.0.17)
105
+ - Jetty(9.4.48.v20220622)
105
106
  body:
106
107
  encoding: UTF-8
107
- string: '{"Items":[{"user_id":{"S":"hguzman10@gmail.com"},"id":{"S":"12345"},"service_id":{"S":"c1"}}],"Count":1,"ScannedCount":1}'
108
- recorded_at: Tue, 14 May 2024 15:07:55 GMT
109
- - request:
110
- method: post
111
- uri: http://localhost:8000/
112
- body:
113
- encoding: UTF-8
114
- string: '{"TableName":"fleteo-v2-users","Key":{"id":{"S":"hguzman10@gmail.com"}}}'
115
- headers:
116
- Accept-Encoding:
117
- - ''
118
- Content-Type:
119
- - application/x-amz-json-1.0
120
- X-Amz-Target:
121
- - DynamoDB_20120810.GetItem
122
- User-Agent:
123
- - aws-sdk-ruby3/3.191.3 ua/2.0 api/dynamodb#1.105.0 os/macos#20 md/x86_64 lang/ruby#3.2.3
124
- md/3.2.3 cfg/retry-mode#legacy
125
- Host:
126
- - localhost:8000
127
- X-Amz-Date:
128
- - 20240514T150755Z
129
- X-Amz-Content-Sha256:
130
- - ab20f394f9f17ab85359c8cef098ff2e93991ca4f4f9402376eaa33ea97d5545
131
- Authorization:
132
- - AWS4-HMAC-SHA256 Credential=key/20240514/us-east-1/dynamodb/aws4_request,
133
- SignedHeaders=content-type;host;x-amz-content-sha256;x-amz-date;x-amz-target,
134
- Signature=2311f940f3763c56418db07d2d498ca006c94fd097550710d01a749f66cc3fd1
135
- Content-Length:
136
- - '72'
137
- Accept:
138
- - "*/*"
139
- response:
140
- status:
141
- code: 200
142
- message: OK
143
- headers:
144
- Date:
145
- - Tue, 14 May 2024 15:07:55 GMT
146
- X-Amzn-Requestid:
147
- - 6780ab71-69c9-4d30-a321-43c2d06aec41
148
- Content-Type:
149
- - application/x-amz-json-1.0
150
- X-Amz-Crc32:
151
- - '3262869781'
152
- Content-Length:
153
- - '157'
154
- Server:
155
- - Jetty(11.0.17)
156
- body:
157
- encoding: UTF-8
158
- string: '{"Item":{"created_at":{"S":"2024-05-07T14:10:09-05:00"},"id":{"S":"hguzman10@gmail.com"},"balance":{"N":"0"},"updated_at":{"S":"2024-05-07T14:10:09-05:00"}}}'
159
- recorded_at: Tue, 14 May 2024 15:07:55 GMT
108
+ string: '{"Items":[],"Count":0,"ScannedCount":0}'
109
+ recorded_at: Fri, 31 May 2024 20:30:20 GMT
160
110
  recorded_with: VCR 6.2.0
data/spec/spec_helper.rb CHANGED
@@ -22,4 +22,3 @@ VCR.configure do |c|
22
22
  c.default_cassette_options = {match_requests_on: %i[method uri]}
23
23
  # c.default_cassette_options = { match_requests_on: %i[method uri body] }
24
24
  end
25
-
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dynamodb_record
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.5
4
+ version: 0.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Henry Guzman
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2024-05-14 00:00:00.000000000 Z
12
+ date: 2024-06-01 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: activesupport
@@ -202,11 +202,13 @@ files:
202
202
  - spec/dynamodb_record/persistence_spec.rb
203
203
  - spec/dynamodb_record/query_spec.rb
204
204
  - spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_belongs_to/get_object.yml
205
- - spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_has_many/add_list.yml
205
+ - spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_has_and_belongs_to_many/create.yml
206
+ - spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_has_and_belongs_to_many/destroy.yml
207
+ - spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_has_and_belongs_to_many/only_one_record.yml
206
208
  - spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_has_many/create_item.yml
209
+ - spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_has_many/create_item_with_.yml
207
210
  - spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/_has_many/get_collection.yml
208
211
  - spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/has_and_belongs_to_many.yml
209
- - spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/has_and_belongs_to_many_create.yml
210
212
  - spec/fixtures/vcr_cassettes/DynamodbRecord_Associations/has_many_through.yml
211
213
  - spec/fixtures/vcr_cassettes/DynamodbRecord_Document/initializes_from_database.yml
212
214
  - spec/fixtures/vcr_cassettes/DynamodbRecord_Fields/_find/finds_record.yml