[jboss-user] [JCA/JBoss] - Re: Changinh connection state in CMP EJB

vickyk do-not-reply at jboss.com
Fri Jul 6 02:21:47 EDT 2007


Considering the following  scenario

Assuming that in MySQL Database we have a Reauth-Schema SCHEMA with the following tables:
1) Table0
2) Table1
3) Table2

Considering there are 3 users with the following username/password

1) user1/password1
2) user2/password2
3) user3/password3

Now user1,user2 and user3 can access Table0 
user2 can only access Table1 
user3 can only access Table2

I think I can use GRANT feature in MySql I have yet not tried this ?..

Considering the following flow in the application code 
1) Create a connection Pool for user1/password1.
2) Get the connection from the pool which is created in the Step1.
3) Fire a DML command on the Table0.
4) Now, try to fire the command on the Table1.

The Step4 should now get executed as Table1 can't be accessed by user1 identity. The work around should be to change the identity associated with the connection when taken from the Connection Pool for the Step 4.

This is what I understand from the Re-Authentication feature from the EIS(MySql side) , however I am not sure of how to make such settings.

I am trying to understand the Reauthentication feature at EIS side, is this how it works?

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4061115#4061115

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4061115

More information about the jboss-user mailing list