A lambda function that listens to an SNS topic, checks the requested tile ids and adds the matching content to a corresponding (DynamoDB) search bucket.
The lambda will start by extracting the tile ids from the event object. (See the event section)
Afterwards it will fetch the content for those ids from an S3 bucket.
If the content is not found an error will be logged but the process will continue for
all the successfully found tiles.
The results (tiles and their content) are Pushed to a websocket and s3.
The incoming event is the same as the schema from lambda-search-request-handler.
We Will have the tiles available in the content object. The tile object will have following format:
{
"content": {
"tiles": ['tile:article.dk.10'] // A list of tile ids
}
}
Look at the codeship settings to get the values for these variables. https://codeship.com/projects/147193/configure_environment
Look at .env.example