You can use the getCallerPrincipal method on the ejb-context to get a Principal object that represents the logged in user.
But I got an impression that the getCallerPrincipal was only for the currently logged in user. But what I want to do is to view the all the logged in user to a given server, I am not how to achieve that by using the principal. Can we get all logged in principals?
Please give me more direction.