Skip to content

Commit 472feaa

Browse files
committed
Update Changelog
1 parent 2d8720e commit 472feaa

File tree

1 file changed

+1
-29
lines changed

1 file changed

+1
-29
lines changed

CHANGELOG.md

+1-29
Original file line numberDiff line numberDiff line change
@@ -3,39 +3,11 @@
33

44
* Feature - Add support for atomic counter (#144)
55

6-
2.7.0 (master)
6+
2.7.0 (2021-10-28)
77
------------------
88

99
* Feature - Implement the `BatchWriteItem` operation (#119)
1010

11-
#### BatchWriteItem Example
12-
13-
```ruby
14-
class Breakfast
15-
include Aws::Record
16-
integer_attr :id, hash_key: true
17-
string_attr :name, range_key: true
18-
string_attr :body
19-
end
20-
21-
# save something to DynamoDB so we can delete it later in a batch request
22-
eggs = Breakfast.new(id: 1, name: "eggs").save!
23-
# we're going to create the following items in a batch request
24-
waffles = Breakfast.new(id: 2, name: "waffles")
25-
pancakes = Breakfast.new(id: 3, name: "pancakes")
26-
27-
# perform a batch operation
28-
operation = Aws::Record::Batch.write(client: Breakfast.dynamodb_client) do |db|
29-
db.put(waffles)
30-
db.delete(eggs)
31-
db.put(pancakes)
32-
end
33-
34-
# (optional) - unprocessed items can be retried
35-
# note: it's a good idea to implement a custom/exponential backoff strategy
36-
operation.execute! unless operation.complete?
37-
```
38-
3911
2.6.1 (2021-08-10)
4012
------------------
4113

0 commit comments

Comments
 (0)