why is J2EE faster than RMI

hi

i wrote some algorithms like Fast Fourier Transform, N-body problem, Graph problems, and ran them as parallel applications on multiple processors(2, 4, 8) using both j2ee and rmi architectures.

all of the applications ran faster with j2ee. i was expecting rmi to run faster. because j2ee will the have application server overhead compared to rmi, its performance should be lower than rmi.

i cannot explain myself why this is happening. any help would be greatly appreciated.

thanks

[516 byte] By [bart1979a] at [2007-9-29 11:42:55]
# 1

> i cannot explain myself why this is happening. any

> help would be greatly appreciated.

It is probably that the J2EE is handling multiple request at the same time, i.e. Multi-tasking via the AppServer. I would suspect that the RMI solution is single threaded and therefore is not. I would also expect RMI to outperform J2EE other things being equal, however to get the same benefits you would probably need to re-write RMI to support the same scalability features as naturally offered with the J2EE AppServers.

MartinS.a at 2007-7-15 1:16:10 > top of Java-index,Other Topics,Patterns & OO Design...