I have configured the java APM agent through the elastic.apm.service_name config for my spring-boot application.
When there is any error occurring for my method annotated with @Async the error from this isn't available at the APM side. The code snippet where this issue occurs is.
@Async("AsyncConfigPayAgg")
public void submitPaymentToComplianceAndUpdateNano(PaymentDetails paymentDetails, Customer customer,
List<RuleResponse> ruleResponseList) {
try {
LogUtil.log(LOGGER, "Active threads for comply::" + asyncConfigPayAgg.getActiveCount());
APIResponse<?> compliResponse = submitTransactionForCompliance(paymentDetails,
PaymentDirectionEnum.OUTGOING, customer, ruleResponseList);