I'm using WebLogic server and have a Stateful Bean running. In the WebLogic Console, each instance of the Stateful Beans is assigned a unique ID which has the format: 999999_9
Does anyone know how to retrieve this unique ID?
Sorry for asking instead of answering - why would you need it?
Hi and thanks for your question and answer :)
I need it because I'm using a Stateful Bean as a Session Manager, where each Bean stores attributes for a client. I store the "Session ID" in a central repository, because even other applications need to access the session. I need to be sure that the Session Id created is a uniqe one, and was therefore interested in the WLS Console ID mechanism which is sure to give each EJB a uniqe key.
I'm not sure if this is the right way to do it, but we cannot use Servlet Session ID's because some of the clients are WAP terminals.
It is System.identityHashCode(this) - if you are inside the XXXBean.java