Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
3921323
wip: introduce DynamoDb driver
adrians5j Aug 24, 2020
3777ef2
feat: remove `id` and introduce keys
adrians5j Aug 24, 2020
8f4d1e1
chore: add missing watch command
adrians5j Aug 24, 2020
c453ee4
chore: add config for `@shelf/jest-dynamodb`
adrians5j Aug 24, 2020
09d9be6
fix: if model not provided, return an empty array
adrians5j Aug 30, 2020
75b5371
chore: remove unused imports
adrians5j Aug 30, 2020
9f4efaf
wip: adjust sent driver args
adrians5j Aug 30, 2020
d644453
chore: remove redundant files
adrians5j Sep 6, 2020
8077bdc
feat: add logical and comparison operators
adrians5j Sep 6, 2020
a082eb4
wip: create DynamoDb driver
adrians5j Sep 6, 2020
56c9015
test: add tests
adrians5j Sep 6, 2020
70036e4
chore: remove all-contributors
adrians5j Sep 7, 2020
92c30f6
test: add tests
adrians5j Sep 7, 2020
4aba1ba
chore: create GSIs
adrians5j Sep 7, 2020
d54b5d9
chore: update yarn.lock
adrians5j Sep 7, 2020
776c687
chore: update dev dependencies
adrians5j Sep 7, 2020
3afe739
fix: exclude GSI fields if null in batchWrite operations
adrians5j Sep 7, 2020
226ac0a
fix: export Batch class
adrians5j Sep 7, 2020
18c32af
feat: introduce Batch class
adrians5j Sep 7, 2020
45fa74c
feat: create DynamoDb driver
adrians5j Sep 7, 2020
bb7e041
feat: introduce Transaction class
adrians5j Sep 7, 2020
b485b06
fix: find entries in storage pool by primary key, not `id`
adrians5j Sep 7, 2020
1ed2340
fix: add IndexName if unique key query was recognized
adrians5j Sep 7, 2020
4689f6d
chore: rename `maxPerPage` to `maxLimit`
adrians5j Sep 7, 2020
256466a
feat: introduce additional static method
adrians5j Sep 7, 2020
5676b84
ci: add beta release action
adrians5j Sep 7, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 51 additions & 0 deletions .github/workflows/betaRelease.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
name: Next Release

on:
push:
branches: [ beta ]

env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

jobs:
build-test-release:
name: Build, test and release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- uses: actions/setup-node@v2-beta
with:
node-version: '12'

- name: Create ".npmrc" file in the project root
run: echo "//registry.npmjs.org/:_authToken=\${NPM_TOKEN}" > .npmrc

- name: Install dependencies
run: yarn --frozen-lockfile

- name: Check dependencies
run: yarn adio

- name: Build packages
run: yarn build

# - name: Run tests
# run: yarn test:dist

- name: Prepare packages
run: yarn prepack

- name: Set git email
run: git config --global user.email "info@webiny.com"

- name: Set git username
run: git config --global user.name "webiny"

- name: Create a release on GitHub
run: yarn lerna version --conventional-prerelease --yes

- name: Release packages to NPM
run: yarn lerna publish from-package --dist-tag beta --yes

50 changes: 50 additions & 0 deletions jest-dynamodb-config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
module.exports = {
tables: [
{
TableName: `pk-sk`,
KeySchema: [
{ AttributeName: "pk", KeyType: "HASH" },
{ AttributeName: "sk", KeyType: "RANGE" }
],
AttributeDefinitions: [
{ AttributeName: "pk", AttributeType: "S" },
{ AttributeName: "sk", AttributeType: "S" },
{ AttributeName: "gsi1pk", AttributeType: "S" },
{ AttributeName: "gsi1sk", AttributeType: "S" },
{ AttributeName: "gsi2pk", AttributeType: "S" },
{ AttributeName: "gsi2sk", AttributeType: "S" }
],
ProvisionedThroughput: { ReadCapacityUnits: 1, WriteCapacityUnits: 1 },
GlobalSecondaryIndexes: [
{
IndexName: "gsi1pk_gsi1sk",
KeySchema: [
{ AttributeName: "gsi1pk", KeyType: "HASH" },
{ AttributeName: "gsi1sk", KeyType: "RANGE" }
],
Projection: {
ProjectionType: "ALL"
},
ProvisionedThroughput: {
ReadCapacityUnits: 1,
WriteCapacityUnits: 1
}
},
{
IndexName: "gsi2pk_gsi2sk",
KeySchema: [
{ AttributeName: "gsi2pk", KeyType: "HASH" },
{ AttributeName: "gsi2sk", KeyType: "RANGE" }
],
Projection: {
ProjectionType: "ALL"
},
ProvisionedThroughput: {
ReadCapacityUnits: 1,
WriteCapacityUnits: 1
}
}
]
}
]
};
3 changes: 0 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@
"@babel/preset-env": "^7.4.3",
"@babel/preset-flow": "^7.0.0",
"adio": "^1.1.1",
"all-contributors-cli": "^5.6.0",
"babel-eslint": "^10.0.3",
"babel-jest": "^24.7.1",
"camelcase": "^5.2.0",
Expand Down Expand Up @@ -45,8 +44,6 @@
"test:coverage": "yarn test:src --coverage",
"test:coverage:coveralls": "npm run test:coverage && cat ./coverage/lcov.info | coveralls",
"lint-staged": "lint-staged",
"contributors:add": "all-contributors add",
"contributors:generate": "all-contributors generate",
"lerna:version": "lerna version --yes",
"lerna:publish": "lerna publish --yes",
"lerna:rm-dist": "lerna exec -- rm -rf dist",
Expand Down
14 changes: 14 additions & 0 deletions packages/fields-storage-dynamodb/.babelrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"presets": [
["@babel/preset-env", {
"targets": {
"node": "8.10"
}
}],
"@babel/preset-flow"
],
"plugins": [
["@babel/plugin-proposal-object-rest-spread", {"useBuiltIns": true}],
["@babel/plugin-transform-runtime"]
]
}
Loading