Results 1 to 2 of 2
- 01-26-2012, 12:48 PM #1Member
- Join Date
- Jan 2012
- Rep Power
EJB Security context in Swing application
I am having an issue with following exception:
java.rmi.RemoteException: EJB Exception: ; nested exception is:
javax.ejb.EJBAccessException: [EJB:010160]Security Violation: User: '<anonymous>' has insufficient permission to access EJB: type=<ejb>
I've read certain forums and found out is that EJB SecurityContext is bound to the thread and that is stored in thread local and
inherented by child threads.
The problem is that this exception is quite rare and users have to restart their GUIs to get rid of it.
The flow is following: Login window -> get username/password -> Use this username/password to create initial context.
The problem is that during login window creating AWT threads are already created and I think what I need to do is:
a) Kill all AWT/Swing threads after users enters login/password into Login window.
b) initialize InitialContext in main thread to make sure it's inherented by all other threads.
There are couple of issues about this - I dont know how to kill AWT/Swing threads. Also if someone knows more elegant solution, would be great.
P.S. I am using Weblogic 10.0.3.
- 01-26-2012, 02:12 PM #2
Re: EJB Security context in Swing application
dbIf you're forever cleaning cobwebs, it's time to get rid of the spiders.
- By rajanpalanisamy in forum Apache CommonsReplies: 0Last Post: 01-02-2012, 05:15 PM
- By rtomar in forum Java ServletReplies: 2Last Post: 07-03-2011, 04:31 PM
- By owasptraining in forum Java CertificationReplies: 0Last Post: 06-07-2011, 04:19 PM
- By Saurabh321 in forum New To JavaReplies: 1Last Post: 04-17-2009, 11:12 AM
- By bbq in forum Java ServletReplies: 1Last Post: 07-05-2007, 03:11 AM