Hi folks,
I am currently using the ServiceLocator pattern (mostly) to locate EJBHome classes, and now that I got used to it I am considering to cache the home objects in order to improve performance. At first, I want to keep these home objects in a java.util.Map once they are used:
Ok, that should work. However, I have some questions: could the references in my cache become invalid? I mean, is there a chance that I take an EJBHome from the cache and it does not work anymore? And finally, has anyone got reasons why I should not cache the home objects? Thanks in advance
I am currently using the ServiceLocator pattern (mostly) to locate EJBHome classes, and now that I got used to it I am considering to cache the home objects in order to improve performance. At first, I want to keep these home objects in a java.util.Map once they are used:
Ok, that should work. However, I have some questions: could the references in my cache become invalid? I mean, is there a chance that I take an EJBHome from the cache and it does not work anymore? And finally, has anyone got reasons why I should not cache the home objects? Thanks in advance