Hello, We are using struts framework where for every screen we have a form bean, which calls action class, which inturn calls session ejb(stateless). The business logic is in session ejb which use DAO to interact with database. Now the problem is, that in current scenerio, we will end-up having 100+ screens and thus 100+ session ejb, which may create performance problem later. Pls suggest. Also, can we modify the current framework to look like something.....that we build few session ejbs(categorized based on modules), which will have methods for their related screens, which will inturn invoke a normal java class (with business logic) and this java class will call DAO to interact with database. Pls note that every call to ejb will require TRANSACTION. Pls suggest the pros and cons of this approach or is there a better way to deal with such scenerio? Regards, Jaiom Rana
posted 12 years ago
I have recently looked into this, found one reference of doing it. Check out the 'WebSphere Command Pattern'. Details of this are available in the IBM Redbook: sg245754 Design and Implement Servlets, JSPs, and EJBs for WebSphere.pdf I hope this would give you the details u are looking for. The basic idea of the whole thing is to decouple ur front end from having to know everything abt the backend ( ur business specific session ejb's). Hope this helps.