This commit is contained in:
2025-07-10 17:36:51 -03:00
parent 72b1338135
commit bd6fbf7166
19 changed files with 250 additions and 16 deletions

View File

@@ -32,7 +32,7 @@ def lambda_handler(event: EventBridgeEvent, context: LambdaContext) -> bool:
result = enrollment_layer.collection.query(
KeyPair(
# Post-migration: uncomment the following line
# Post-migration: Uncomment the following line
# ComposeKey(tenant_id, prefix='slots#org'),
ComposeKey(tenant_id, prefix='vacancies'),
order_id,
@@ -45,10 +45,12 @@ def lambda_handler(event: EventBridgeEvent, context: LambdaContext) -> bool:
for pair in result['items']:
batch.delete_item(
Key={
# Post-migration: rename `vacancies` to `slots#org`
# Post-migration: Rename `vacancies` to `slots#org`
'id': {'S': ComposeKey(pair['id'], prefix='vacancies')},
'sk': {'S': pair['sk']},
}
)
logger.info('Slots deleted')
return True