batch versus single transaction processing
Posted: Thu Aug 14, 2008 8:22 pm
Did you ever face the dilemma to choose between batch processing and individual processing in a SOA environment. The outline of the project:
A file with 120.000-350.000 orders if received from a third party supplier and must be offered to a financial module, written in Oracle (PL/SQL). My initial choice was to design a Java adapter which performs validation of the file, splits each record individually and puts it on the Enterprise Service Bus. A JMS listener reads the orders again and offers them one by one to the financial module. With this method it is possible to handle batch files and individual transactions the same; the listener just gets them from the service bus and doesn't care where it came from. Another advantage is that processing of each individual order can be a transactional process. You don´t want processing of a complete file to be one transaction.
Of course I know that batch processing is faster (sql*loader does it very fast), but I didn´t want to optimize too fast. The Oracle developers thought I was a complete fool (which may be the case), but I wanted to stick to the SOA philosphy as much as possible. Don't say that SOA does not exclude batch processing; in the end, if the hardware is up to it, batch processing is an ancient idea. For the time being, you have to stick with it from time to time.
Does anyone has similar experiences?
A file with 120.000-350.000 orders if received from a third party supplier and must be offered to a financial module, written in Oracle (PL/SQL). My initial choice was to design a Java adapter which performs validation of the file, splits each record individually and puts it on the Enterprise Service Bus. A JMS listener reads the orders again and offers them one by one to the financial module. With this method it is possible to handle batch files and individual transactions the same; the listener just gets them from the service bus and doesn't care where it came from. Another advantage is that processing of each individual order can be a transactional process. You don´t want processing of a complete file to be one transaction.
Of course I know that batch processing is faster (sql*loader does it very fast), but I didn´t want to optimize too fast. The Oracle developers thought I was a complete fool (which may be the case), but I wanted to stick to the SOA philosphy as much as possible. Don't say that SOA does not exclude batch processing; in the end, if the hardware is up to it, batch processing is an ancient idea. For the time being, you have to stick with it from time to time.
Does anyone has similar experiences?