留言板
Read Write issue in Liferay 6.1
Hi All,
We have been in nightmares to figure out this issue. I need some help immediately basis.
We are facing issue on reading and writing to the DB. I am sharing the configuration that I have done.
portal - ext.properties
Context.xml
Server.xml
It was always reading the data which was configured on jdbc.default.jndi.name=jdbc/LiferayPool, but actually we need to read the data from the liferayReadPool that we have configured.
And if we delete jdbc.default.jndi.name=jdbc/LiferayPool line from the portal-ext.properties, it was default getting connected to the hypersonic DB.
Any suggestion will be helpful on it and also let me know if required more info.
Thanks & Regards,
Amit Doshi
We have been in nightmares to figure out this issue. I need some help immediately basis.
We are facing issue on reading and writing to the DB. I am sharing the configuration that I have done.
portal - ext.properties
jdbc.default.jndi.name=jdbc/LiferayPool
jdbc.read.jndi.name=jdbc/LiferayReadPool
jdbc.write.jndi.name=jdbc/LiferayPool
spring.configs=\
META-INF/base-spring.xml,\
\
META-INF/hibernate-spring.xml,\
META-INF/infrastructure-spring.xml,\
META-INF/management-spring.xml,\
\
META-INF/util-spring.xml,\
\
META-INF/jpa-spring.xml,\
\
META-INF/executor-spring.xml,\
\
META-INF/audit-spring.xml,\
META-INF/cluster-spring.xml,\
META-INF/editor-spring.xml,\
META-INF/jcr-spring.xml,\
META-INF/ldap-spring.xml,\
META-INF/messaging-core-spring.xml,\
META-INF/messaging-misc-spring.xml,\
META-INF/mobile-device-spring.xml,\
META-INF/notifications-spring.xml,\
META-INF/poller-spring.xml,\
META-INF/rules-spring.xml,\
META-INF/scheduler-spring.xml,\
META-INF/scripting-spring.xml,\
META-INF/search-spring.xml,\
META-INF/workflow-spring.xml,\
\
META-INF/counter-spring.xml,\
META-INF/mail-spring.xml,\
META-INF/portal-spring.xml,\
META-INF/portlet-container-spring.xml,\
META-INF/staging-spring.xml,\
META-INF/virtual-layouts-spring.xml,\
\
META-INF/dynamic-data-source-spring.xml,\
#META-INF/shard-data-source-spring.xml,\
#META-INF/memcached-spring.xml,\
#META-INF/monitoring-spring.xml,\
\
META-INF/ext-spring.xml
Context.xml
<resourcelink global="LiferayReadPool" name="jdbc/LiferayReadPool" />
<resourcelink global="LiferayPool" name="jdbc/LiferayPool" />
Server.xml
<resource name="LiferayPool" auth="Container" type="javax.sql.DataSource" driverClassName="net.sourceforge.jtds.jdbc.Driver" url="jdbc:jtds:sqlserver://xxx:1433/Portal;TDS=8.0;bufferMaxMemory=8192;bufferMinPackets=64;cacheMetaData=true;prepareSQL=3;socketKeepAlive=true;" username="sss" password="sss" maxActive="100" maxIdle="30" maxWait="3000" removeAbandoned="true" removeAbandonedTimeout="60" />
<resource name="LiferayReadPool" auth="Container" type="javax.sql.DataSource" driverClassName="net.sourceforge.jtds.jdbc.Driver" url="jdbc:jtds:sqlserver://yyy:1433/Portal;TDS=8.0;bufferMaxMemory=8192;bufferMinPackets=64;cacheMetaData=true;prepareSQL=3;socketKeepAlive=true;" username="zzz" password="zzz" maxActive="100" maxIdle="30" maxWait="3000" removeAbandoned="true" removeAbandonedTimeout="60" />
It was always reading the data which was configured on jdbc.default.jndi.name=jdbc/LiferayPool, but actually we need to read the data from the liferayReadPool that we have configured.
And if we delete jdbc.default.jndi.name=jdbc/LiferayPool line from the portal-ext.properties, it was default getting connected to the hypersonic DB.
Any suggestion will be helpful on it and also let me know if required more info.
Thanks & Regards,
Amit Doshi