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

Support Multi Mosaic in DynamoDB Table #127

Merged
merged 18 commits into from Oct 22, 2020
Merged

Conversation

vincentsarago
Copy link
Member

closes #116

@vincentsarago vincentsarago self-assigned this Oct 16, 2020
@@ -53,46 +69,47 @@ def assets_for_point(self, lng: float, lat: float) -> List[str]:
tile = mercantile.tile(lng, lat, self.quadkey_zoom)
return self.get_assets(tile.x, tile.y, tile.z)

def info(self, fetch_quadkeys: bool = False):
def info(self, quadkeys: bool = False):
Copy link
Member Author

Choose a reason for hiding this comment

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

will be the same for all the backend once we do #126

ExpressionAttributeNames={"#mosaicId": "mosaicId", "#quadKey": "quadKey"},
ExpressionAttributeValues={":mosaicId": {"S": self.mosaic_name}},
ProjectionExpression="#quadKey",
KeyConditionExpression=Key("mosaicId").eq(self.mosaic_name),
Copy link
Member

Choose a reason for hiding this comment

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

❤️ very readable

@vincentsarago vincentsarago marked this pull request as ready for review October 20, 2020 19:19
@vincentsarago vincentsarago changed the title add mosaic_name in the item key Support Multi Mosaic in DynamoDB Table Oct 20, 2020
@vincentsarago
Copy link
Member Author

vincentsarago commented Oct 20, 2020

Next

  • update test
  • test at scale

cogeo_mosaic/backends/dynamodb.py Outdated Show resolved Hide resolved
cogeo_mosaic/backends/dynamodb.py Outdated Show resolved Hide resolved
cogeo_mosaic/backends/dynamodb.py Show resolved Hide resolved
cogeo_mosaic/backends/dynamodb.py Outdated Show resolved Hide resolved
cogeo_mosaic/backends/dynamodb.py Outdated Show resolved Hide resolved
cogeo_mosaic/backends/dynamodb.py Outdated Show resolved Hide resolved
cogeo_mosaic/backends/dynamodb.py Outdated Show resolved Hide resolved
@vincentsarago vincentsarago merged commit 4f062b7 into master Oct 22, 2020
@vincentsarago vincentsarago deleted the newDynamoDBschema branch October 22, 2020 15:36
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.

Multiple mosaics within a single DynamoDB table
3 participants