Question

3
Replies
1930
Views
Chunzhi_Hong Member since 2013 137 posts
PEGA
Posted: 3 years ago
Last activity: 3 years 5 months ago
Closed

How to customize jndi name "jdbc/PegaRULES" on WebSphere

On Tomcat it is easy to customize jndi name of pega rules data source by modifying contex.xml and prconfig.xml as below.
Contex.xml
<Resource name="jdbc/PegaRULES_DEV"
auth="Container"
type="javax.sql.DataSource"
maxActive="100"
maxIdle="30"
maxWait="10000"
driverClassName="org.postgresql.Driver"
url="jdbc:postgresql://localhost:5432/postgres"
username="postgres"
password="postgres"/>

prconfig.xml
<env name="database/databases/PegaRULES/dataSource" value="java:comp/env/jdbc/PegaRULES_DEV"/>
<env name="database/databases/PegaDATA/dataSource" value="java:comp/env/jdbc/PegaRULES_DEV"/>

However, the similar approach doesn't work on Webshpere 8.5.5, any ideas? We have restarted Websphere after adding new data source with jndi name "jdbc/PegaRULES_DEV".

ERROR - Unable to obtain DataSource for java:comp/env/jdbc/PegaRULES_DEV; javax.naming.NameNotFoundExceptionHowever, the similar approach doesn't work on Webshpere 8.5.5, any ideas? We have restarted Websphere after adding new data source with jndi name "jdbc/PegaRULES_DEV"

Caused by: com.pega.pegarules.pub.database.BadDatabaseDefinitionException: Database-BadDBDef-MissingPegaRULES

From: (unknown)

at com.pega.pegarules.data.internal.access.DatabaseConfigurationMap.getDBConfig(DatabaseConfigurationMap.java:144)
at com.pega.pegarules.data.internal.access.ConnectionManagerImpl.getDBConfig(ConnectionManagerImpl.java:2776)
at com.pega.pegarules.data.internal.access.ConnectionManagerImpl.getConnection(ConnectionManagerImpl.java:1213)
at com.pega.pegarules.data.internal.access.ConnectionManagerImpl.getConnection(ConnectionManagerImpl.java:1170)
at com.pega.pegarules.data.internal.access.ConnectionManagerImpl.<init>(ConnectionManagerImpl.java:544)
at com.pega.pegarules.data.internal.PRDataProviderImpl.getConnectionManager(PRDataProviderImpl.java:610)
at com.pega.pegarules.data.internal.PRDataProviderImpl.isMultiTenantEnvironment(PRDataProviderImpl.java:1165)
... 28 more
Low-Code App Development System Administration
Moderation Team has archived post
Share this page LinkedIn