Skip to content

Commit

Permalink
Update README
Browse files Browse the repository at this point in the history
  • Loading branch information
baopham committed May 25, 2016
1 parent 8984796 commit 197d60c
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ Install

* Composer install
```bash
composer require baopham/dynamodb:0.2.3
composer require baopham/dynamodb:0.3.0
```

* Install service provider:
Expand Down Expand Up @@ -83,6 +83,13 @@ $model->fillableAttr2 = 'foo';
// DynamoDb doesn't support incremented Id, so you need to use UUID for the primary key.
$model->id = 'de305d54-75b4-431b-adb2-eb6b9e546014'
$model->save();
// chunk
$model->chunk(10, function ($records) {
foreach ($records as $record) {
}
});
```
* Or if you want to sync your DB table with a DynamoDb table, use trait `BaoPham\DynamoDb\ModelTrait`, it will call a `PutItem` after the model is saved.
Expand Down Expand Up @@ -114,7 +121,7 @@ $ java -Djava.library.path=./DynamoDBLocal_lib -jar dynamodb_local/DynamoDBLocal
$ ./vendor/bin/phpunit
```
* DynamoDb local version: 2015-07-16_1.0
* DynamoDb local version: 2016-01-07_1.0
* DynamoDb local schema for tests created by the [DynamoDb local shell](http://docs.aws.amazon.com/amazondynamodb/latest/developerguide/Tools.DynamoDBLocal.Shell.html) is located [here](dynamodb_local_schema.js)
Expand All @@ -137,3 +144,4 @@ Author and Contributors
-------
* Bao Pham
* [warrick-loyaltycorp](https://github.com/warrick-loyaltycorp)
* [cthos](https://github.com/cthos)

This comment has been minimized.

Copy link
@baopham

baopham May 25, 2016

Author Owner

@cthos thank you 👍

0 comments on commit 197d60c

Please sign in to comment.