0

We have a system that receive payment information for invoices from the bank system. It works like that:

  1. Invoice is created in our system
  2. Payer pays for the invoice from system of Bank
  3. Bank connects to our system and obtain information on invoice
  4. Our system returns the invoice details
  5. Bank system go through payment process, and sends details of the payment to our system and it will wait for for confirm message 30 seconds. 6. If the bank system does not receive confirm message within 30 seconds, bank cancels the payment but does not inform our system about cancellation.
  6. Our system receives the payment info, and saves the payment. Then sends the confirm message to bank. But sometimes, because of network or system issue, confirm message won't be delivered within 30 seconds and we became unaware of cancelled message status.

Message exchange is through SOAP protocol. And bank does not change their system like to inform us about the issue but they provided a method to check payment status by payment id.

I have developed a solution which check each payment after 30 seconds if the payment is successful. Tasks are executed separate threads using thread pool of Spring framework. But I am afraid that it is not the best solution as there is a risk of being full of thread pool when network failure happens.

What solutions would you recommend? Can we use RabbitMQ for this issue?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.