You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: powertools-batch/src/main/java/software/amazon/lambda/powertools/batch/examples/ExampleBatchRequestHandler.java
Copy file name to clipboardExpand all lines: powertools-batch/src/main/java/software/amazon/lambda/powertools/batch/examples/ExampleMessageHandlerBuilder.java
// processBatch is implemented as default in the interface and handle exceptions in the processElement function to add the item to the BatchItemFailure list
13
+
14
+
// TODO - as we're getting this on the outside, we could pass in `sqsEvent.getMessages()` which would
15
+
// fix the "how do I extract event-specific message" problem in the interface default.
16
+
returnthis.processBatch(sqsEvent); // we may need to pass context too... ?
17
+
18
+
// TODO - as we're still on the outside, we could take the list of results from `this.processBatch()` and
19
+
// map it back to the SQS-specific response, again solving the "how do I do this event-specific thing"
20
+
// problem in the base class.
21
+
}
22
+
23
+
// this method comes from the BatchProcessor interface, developers need to override the appropriate one
0 commit comments