![]() |
sponsored links |
|
|
sponsored links
|
|
|
2
20th June 07:44
External User
Posts: 1
|
Clearly, you should work first on your actual assigned tasks. In fact,
you would do well to discuss your optimization plans with your supervisor before modifying a single line of code toward that end, as there may be specific reasons for any or all of the implementation details you might be inclined to change, and there may be an optimization project going on elsewhere or waiting in the wings. Plus, if you do end up successfully inserting some optimization then you want to get credit for it. As for where to find performance gains, you _must_ profile the application to have a reasonable chance of success in a short time frame. There is a variety of Java profilers available, both free and commercial, with a wide variety of capability. Typically the container would maintain multiple distinct instances of the session bean -- at minimum one per active session. Stateful beans therefore do not scale as well as stateless ones, but unless the application server is short on memory (and hence using a lot of VM or doing a lot of GC) the stateful / stateless distinction is not likely to be a performance issue. Again, however, you need to profile to really find out. I thought you were on a tight schedule. This is likely to be a fairly large chunk of work. It is one of the more likely areas to be a performance win, but you need to profile. Also, when you profile be sure to ****yze the DB performance: sometimes query optimization can be a tremendous win. If you dump the entity beans then you should still put the data access framework behind a session bean and make sure to use XA-aware connections. That gives you the benefits of J2EE transactions without the entity beans. You very likely want that, especially if the application ever will update any of the data. So you are suggesting creating and using a collection of value objects? That's often a win performance-wise. But it might or might not give the application a noticeable speedup if there is a bigger problem elsewhere. Another alternative might be to use local EJB interfaces instead of remote ones. That way you take RMI out of the picture altogether, at the cost of some limitations to your possible deployment scenarios. Beware, however, as this fundamentally changes the argument-passing and return value semantics (you get standard Java semantics instead of passing copies around). It is unlikely that this is the cause of a significant speed reduction, although it is possible that it contributes to a _perceived_ speed reduction, depending on the browser used. The same is true of the HTML output in general, which conceivably might be restructured to improve client-side performance. You really, truly need to know where the performance problems are in advance before speculatively modifying this sort of thing. John Bollinger jobollin@indiana.edu |
|