I am architecting Trading software system. Current system is client/server and we are replacing it with web based system. I am an experienced J2EE developer and have worked with J2EE, Struts, Hibernate technologies. I am planning to explore and use Spring in business layer and Spring MVC in presentation layer. We will also require to use AJAX in front end for refreshing real data from trading server.
As far as ORM tool is concerned, I am leaning towards Hibernate but bit hesitant as this trading system will have to handle 1 million transactions per day and I am not quite confident with hibernate performance. Should we use hibernate or go for EJBs? Or Spring JDBC with transaction support?
Do you think this will be a right architecture? I am concerned with not having expertiese on Spring and we may uncover issues at later stage of the project.
hibernate or go for EJBs? Or Spring JDBC with transaction support?
Go for Hibernate and use JDBC with DAO as and when needed(ie. where there are many joins, hibernate is not good in that scenario).
Use Spring for front end and middle tier.
Joined: Dec 16, 2004
I have another quick question. In trading system with following scenario,how would one architect this particular piece in Software.
-10 clients (brower clients)are interested in buying 50 stocks of company A with 10 different BUY prices. -System has 60 stocks availabe of company A with $100 as SELL price. -System should handle request on First come first serve basis (Spring-JMS is the option or Message Driven Beans (MDB) ?) -First request came in with < 100 BUY price, system shold put this request in pending (table?) with its BUYing price. -Second request came in with >= 100 BUY price for 40 stocks. system will sell 40 stocks to this client. Now remaining stocks in the system =: 50-40=10 -Third request (client) came in with = 100 BUY price for 40 stocks. System will sell only 10 remaining stocks to this client and will put request in pending table with BUY price = 100 and Quantity = 40-10=30. -Next time when someone sells company A's stocks, system will automatically match against open, pending orders in the databse and will buy for pending orders then send notification to clients about the BUY.