I'm having the same sort of problem as some other poster regarding
JDBC.
I've tried some examples, but the problem I have is in the fact that every example seems to show hard codes of the url and password.
That's great, but is there a way to get a database connection where the url and password from the users who log on can be used to connect to the database?
I can have the users log on to secured areas on the web, then connect them to the DB using a connection pool where it's basically a standard non-expiring password/url JDBC connection to connect to a DB.
The problem is, the project i'm working on needs to know who is connecting to the DB, for how long, and for what. The DB is on a mainframe system and if a user connects to it, that is how the customer's are charged.. For mainframe usage and such.
If they log in to the website, connect through the standard connection pool, there really isn't a way to charge them without making it a drawn out difficult process that will be left to whoever is maintaining the system. For all intensive purposes, it would just look like the connection pool should be charged. that won't work.
Right now i'm using j_security_check for loggin users into secured area's on the web and because that what was recommended to me, and it's already been setup on the app server to work with the mainframe db and users/password combos. So it was the best way to get users logged in.
I need to know or need some help on a way for Me to login through j_security_check, where it checks if i am a valid user, and then it connects to the DB using their username/password and not the standard conneciton pools username/password.
If that can't be done, I could just make it where anytime somebody connects to the mainframe DB, they have to log in.
But is there a way, with j_security_check, to be able to log or follow how long a user has accessed or been logged in so the customer can actually be charged for mainframe usage.
That is the way it is done and that' s the way they want to keep it. Be able to charge the user for mainframe usage.
Maybe it's not entirely a JDBC issue, but it is a combo of JDBC issues where i need a way to connect a user to a DB using their username/pw combo and not a standard JDBC connection pool username/password and on top of that, if that isn't possible, then I have to figure out a way with j_security_check to keep a log or something.
Any help would be great. Thanks.