Friday, 7 April 2017

Timezone Region not found Exception in Weblogic

Hi Readers,

Good Day!! Today we are going to see not the technical, but some strange Exception which I faced while upgrading my web logic to 12.1.3, though the exception looks simple, Identifying and rectifying this issue will be challenging. If any of this readers face same exception it is enough you follow only this, will work exactly.

This error exactly will be caused, when configuring the Data Sources in Weblogic . We used to configure the weblogic datasources by configuring the JNDI name,Driver Name, username and password after the configuration if we try to do TestConfiguration then will get the below error

Message icon - Error Connection test failed.
Message icon - Error ORA-00604: error occurred at recursive SQL level 1 ORA-01882: timezone region not found <br/>oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:450)<br/>oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:392)<br/>oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:385)<br/>oracle.jdbc.driver.T4CTTIfun.processError(T4CTTIfun.java:1018)<br/>oracle.jdbc.driver.T4CTTIoauthenticate.processError(T4CTTIoauthenticate.java:501)<br/>oracle.jdbc.driver.T4CTTIfun.receive(T4CTTIfun.java:522)<br/>oracle.jdbc.driver.T4CTTIfun.doRPC(T4CTTIfun.java:257)<br/>oracle.jdbc.driver.T4CTTIoauthenticate.doOAUTH(T4CTTIoauthenticate.java:437)<br/>oracle.jdbc.driver.T4CTTIoauthenticate.doOAUTH(T4CTTIoauthenticate.java:954)<br/>oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:639)<br/>oracle.jdbc.driver.PhysicalConnection.connect(PhysicalConnection.java:666)<br/>oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:32)<br/>oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:566)<br/>oracle.jdbc.pool.OracleDataSource.getPhysicalConnection(OracleDataSource.java:317)<br/>oracle.jdbc.xa.client.OracleXADataSource.getPooledConnection(OracleXADataSource.java:486)<br/>oracle.jdbc.xa.client.OracleXADataSource.getXAConnection(OracleXADataSource.java:174)<br/>oracle.jdbc.xa.client.OracleXADataSource.getXAConnection(OracleXADataSource.java:109)<br/>weblogic.jdbc.common.internal.DataSourceUtil.testConnection0(DataSourceUtil.java:356)<br/>weblogic.jdbc.common.internal.DataSourceUtil.access$000(DataSourceUtil.java:22)<br/>weblogic.jdbc.common.internal.DataSourceUtil$1.run(DataSourceUtil.java:254)<br/>...

If you encounter this type of exception, then you have to follow below steps

Navigate to <WEBLOGIC-INSTALLED DIR>\user_projects\domains\<YOUR-DOMAIN>\bin then 

open the file named setDomainEnv.cmd 

Search for the Property called JAVA_PROPERTIES ad update that property with  the below values

JAVA_PROPERTIES="-Dwls.home=${WLS_HOME} -Dweblogic.home=${WLS_HOME} -Duser.timezone="GMT""

That means you are defining the Time zone which is not defined.  I am defining the GMT because it’s my Time Zone.

After the Changes, you can restart the Managed server then try configuring the Data Source now, you will not face this exception again. That’s it you are done.

Happy Time Saving !!!!!

No comments:
Write comments