Skip to content

Commit dd8d1db

Browse files
committed
fix(contracts): Improve error messages for DynamoDB operations
1 parent d9e2089 commit dd8d1db

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

unicorn_contracts/src/contracts_service/contractEventHandler.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ class ContractEventHandlerFunction implements LambdaInterface {
5555
await this.createContract(contract);
5656
} catch (error) {
5757
tracer.addErrorAsMetadata(error as Error);
58-
logger.error('Error during DDB PUT', error as Error);
58+
logger.error('DynamoDB PutItem API call unsuccessful. Unable to create contract ', error as Error);
5959
throw error;
6060
}
6161
break;
@@ -66,7 +66,7 @@ class ContractEventHandlerFunction implements LambdaInterface {
6666
await this.updateContract(contract);
6767
} catch (error) {
6868
tracer.addErrorAsMetadata(error as Error);
69-
logger.error('Error during DDB UPDATE', error as Error);
69+
logger.error('DynamoDB UpdateItem API call unsuccessful. Unable to update contract', error as Error);
7070
throw error;
7171
}
7272
break;

0 commit comments

Comments
 (0)