We need effectively remove messages in a batch from the DynamoDB database using composite key (messageID + toDeviceID). For this task, we can use the inner BatchWriteItem function from [[ https://linear.app/comm/issue/ENG-1302/inner-database-function-to-use-batchwriteitem-in-dynamodb | ENG-1302 ]] and delete items by batches instead of 1 by 1.
Linear task: [[ https://linear.app/comm/issue/ENG-1361/removing-messages-in-a-batch-by-composite-key-messageid-todeviceid | ENG-1361 ]]