Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DynamoDB support (WIP) #71

Merged
merged 9 commits into from
Nov 21, 2021
Merged

DynamoDB support (WIP) #71

merged 9 commits into from
Nov 21, 2021

Conversation

Idokah
Copy link
Collaborator

@Idokah Idokah commented Nov 15, 2021

No description provided.

@@ -58,6 +64,9 @@ const create = () => {
case 'airtable':
internalConfigReader = new gcp.GcpAirtableConfigReader()
break;
case 'dynamo':
internalConfigReader = new aws.AwsDynamoConfigReader(region)
break
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gcp doesn't have dynamo

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's not in gcp, it's in azure for the e2e test.
process.env.CLOUD_VENDOR = 'azr' (all e2e tests are on azure)

internalConfigReader = new aws.AwsDynamoConfigReader(region)
break
default:
internalConfigReader = new aws.AwsConfigReader(secretId || DefaultSecretId, region)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's rename the AwsConfigReader to something else


async find(collectionName, filter, sort, skip, limit) {
const {filterExpr} = this.filterParser.transform(filter)
const response = await this.docClient
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it's better to write

const { Items } = ....

async count(collectionName, filter) {
const {filterExpr} = this.filterParser.transform(filter)
const response = await this.docClient
.scan({TableName: collectionName,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

let's discuss the difference between scan and query

@Idokah Idokah merged commit 9273e3d into master Nov 21, 2021
@Idokah Idokah deleted the dynamodb branch November 21, 2021 13:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants