Skip to content

Commit 9523ed4

Browse files
more logging
1 parent ba92e75 commit 9523ed4

1 file changed

Lines changed: 10 additions & 0 deletions

File tree

lambdas/supplier-allocator/src/handler/allocate-handler.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,10 @@ async function getSupplierFromConfig(
178178
},
179179
volumeGroupId: volumeGroupDetails.id,
180180
};
181+
deps.logger.info({
182+
description: "Resolved supplier details for letter event",
183+
supplierDetails,
184+
});
181185
return supplierDetails;
182186
} catch (error) {
183187
deps.logger.error({
@@ -235,6 +239,12 @@ function incrementAllocation(
235239
allocation: number,
236240
deps: Deps,
237241
) {
242+
deps.logger.info({
243+
description: "Incrementing allocation for volume group and supplier",
244+
volumeGroupId,
245+
supplierId,
246+
allocation,
247+
});
238248
const groupAllocations = map.get(volumeGroupId) ?? {};
239249
groupAllocations[supplierId] =
240250
(groupAllocations[supplierId] ?? 0) + allocation;

0 commit comments

Comments
 (0)