GitHub user kaspersorensen opened a pull request:
https://github.com/apache/metamodel/pull/140
Dynamo DB support
This PR adds Amazon DynamoDB support to MetaModel. A few notes on the
implementation:
* I'm personally fairly happy with the read/discovery/query part of
things. As much as possible is leveraged from Amazon's SDK, but since DynamoDB
is essentially schemaless, there's also the usual option of supplying
`SimpleTableDef` objects.
* Creating tables is a bit funky. There are options in creating a DynamoDB
table that I haven't seen elsewhere, such as the throughput capacity flags. I
added system properties for those. There is also in the SDK options for
creating secondary indices, but I didn't find a good way to map that to
MetaModel during CREATE TABLE. So I left it out.
* The testing is pretty sparse right now, and you need a set of Amazon
credentials to make what is there work. Not sure if there is a mock service
available somehow, or an embedded version of DynamoDB.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/kaspersorensen/metamodel dynamo-db
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/metamodel/pull/140.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #140
----
commit 4bd981dfaf0cdd4731d3878701249ac2faf73d92
Author: Kasper Sørensen <[email protected]>
Date: 2017-01-20T02:59:20Z
Added DynamoDB module project structure
commit 432faefd652f2b73975763863de8bcc16e0e9585
Author: Kasper Sørensen <[email protected]>
Date: 2017-01-20T03:49:24Z
Created the initial basic DataContext implementation
commit 774ec721beb759ae2b992bc6153fc358e81f3cf3
Author: Kasper Sørensen <[email protected]>
Date: 2017-01-21T18:47:31Z
Enhanced DynamoDbDataContext with support for count queries
commit 79ad973a09886c237d7392dc1ed0fe30574e7369
Author: Kasper Sørensen <[email protected]>
Date: 2017-01-22T18:24:31Z
Added integration test
commit 2bbc2af5a1cd3060c49ec78cffd7f5e0e17d20a3
Author: Kasper Sørensen <[email protected]>
Date: 2017-01-22T18:55:04Z
Improved integration test by having a check on table creation status
commit 16805c6b085282560d790e47eb36b897b70406a4
Author: Kasper Sørensen <[email protected]>
Date: 2017-01-24T04:39:34Z
Greatly improved discovery and support for custom attributes
commit b5e68d17ca2bbb9031f25c0a1abb4fcf1ba8207d
Author: Kasper Sørensen <[email protected]>
Date: 2017-01-24T05:23:54Z
Added update callback for DynamoDB
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---