I got a problem that I am creating a Connection Pool by using JNDI Datasource and I am using Resign 2.0.5 as web server and my Java ver 1.4.0. For this we are specifing the database username and password in resin.conf file as following:
In java file we are given as follows :
Context ctx = new InitialContext();
DataSource ds = (DataSource)ctx.lookup("java:comp/env/jdbc/test");
Connection dbCon = ds.getConnection(sUserId,sPassword);
My problem is if we specify username and password in resin.conf file then whenever user login then its creating a new connection without getting the new connection from Connection pool. If we didn't speicfy the username and password in the resin.conf then its getting the new connection from Connection pool.
I don't want to specify the username and password directly in the resin.conf. Password should be in the form of encryption. How can I encrypt the password and put in resin.conf and wheather resin.conf indentifies the encrypted password or not? Is there any specail tags? Please give suggests for my problem.