<?xml version="1.0" encoding="UTF-8"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <title>External Database Connectivity not happening in 7.3</title>
  <link rel="self" href="https://uat.liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=120841195" />
  <subtitle>External Database Connectivity not happening in 7.3</subtitle>
  <id>https://uat.liferay.dev/c/message_boards/find_thread?p_l_id=119785294&amp;threadId=120841195</id>
  <updated>2026-10-15T12:00:22Z</updated>
  <dc:date>2026-10-15T12:00:22Z</dc:date>
  <entry>
    <title>RE: External Database Connectivity not happening in 7.3</title>
    <link rel="alternate" href="https://uat.liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121167468" />
    <author>
      <name>pradip choudhari</name>
    </author>
    <id>https://uat.liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=121167468</id>
    <updated>2021-09-25T10:55:25Z</updated>
    <published>2021-09-25T10:55:24Z</published>
    <summary type="html">&lt;p&gt;Hi Bharamani , &lt;br /&gt;
  &lt;br /&gt; sorry for the late response .&lt;br /&gt; yeah , I got solution
  . &lt;br /&gt; once refer the below youtube link &lt;br /&gt;
  &lt;br /&gt; https://www.youtube.com/watch?v=F1Q0SK4XCAM&amp;amp;t=8s&lt;br /&gt;
  &lt;br /&gt; Thanks &lt;/p&gt;</summary>
    <dc:creator>pradip choudhari</dc:creator>
    <dc:date>2021-09-25T10:55:24Z</dc:date>
  </entry>
  <entry>
    <title>RE: External Database Connectivity not happening in 7.3</title>
    <link rel="alternate" href="https://uat.liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=120976756" />
    <author>
      <name>Bharamani Tashildar</name>
    </author>
    <id>https://uat.liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=120976756</id>
    <updated>2021-07-23T15:16:32Z</updated>
    <published>2021-07-23T10:20:00Z</published>
    <summary type="html">&lt;p&gt;Hi Pradeep,&lt;/p&gt;
&lt;p&gt;Did you got any solution on this?&lt;/p&gt;
&lt;p&gt;We are facing same issue with Liferay DXP 7.3 with External database
  Oracle 19c.&lt;/p&gt;
&lt;p&gt;Thanks &lt;/p&gt;</summary>
    <dc:creator>Bharamani Tashildar</dc:creator>
    <dc:date>2021-07-23T10:20:00Z</dc:date>
  </entry>
  <entry>
    <title>External Database Connectivity not happening in 7.3</title>
    <link rel="alternate" href="https://uat.liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=120841194" />
    <author>
      <name>pradip choudhari</name>
    </author>
    <id>https://uat.liferay.dev/c/message_boards/find_message?p_l_id=119785294&amp;messageId=120841194</id>
    <updated>2021-08-17T15:34:49Z</updated>
    <published>2021-06-22T16:01:58Z</published>
    <summary type="html">&lt;p&gt;Hi Team , &lt;br /&gt;
  &lt;br /&gt; We are using external database for storing user encrolled
  courses information purpose . so In 7.0 we are happiely working with
  external database , Now we are migrating our module service builder
  from 7.0 to 7.3 . but this much configuration not working with 7.3 and
  we are getting getService() as null always because
  of ependency-injector=&amp;quot;spring&amp;quot; . so what are the new
  configurations requires for accessing external database in 7.3 ? &lt;br /&gt;
  &lt;br /&gt; I am adding my service.xml file below : &lt;/p&gt;
&lt;pre&gt;
&lt;code class="language-java"&gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot;?&amp;gt;
&amp;lt;!DOCTYPE service-builder PUBLIC &amp;quot;-//Liferay//DTD Service Builder 7.3.0//EN&amp;quot; &amp;quot;http://www.liferay.com/dtd/liferay-service-builder_7_3_0.dtd&amp;quot;&amp;gt;

&amp;lt;service-builder dependency-injector=&amp;quot;spring&amp;quot; package-path=&amp;quot;com.sakai.external.services&amp;quot;&amp;gt;
	&amp;lt;namespace&amp;gt;sakai&amp;lt;/namespace&amp;gt;
	&amp;lt;entity name=&amp;quot;SakaiService&amp;quot; local-service=&amp;quot;true&amp;quot; remote-service=&amp;quot;false&amp;quot; data-source=&amp;quot;liferayDataSource&amp;quot;&amp;gt;
	     &amp;lt;column name=&amp;quot;sakaiServiceId&amp;quot; type=&amp;quot;long&amp;quot; primary=&amp;quot;true&amp;quot;&amp;gt;&amp;lt;/column&amp;gt;
	&amp;lt;/entity&amp;gt;
&amp;lt;/service-builder&amp;gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;
  &lt;br /&gt;
  &lt;br /&gt; and the service.xml defined data-source Id , we mentioned
  inside ext-spring.xml : &lt;br /&gt;
  &lt;br /&gt;  &lt;/p&gt;
&lt;pre&gt;
&lt;code class="language-java"&gt;&amp;lt;?xml version=&amp;quot;1.0&amp;quot;?&amp;gt;

&amp;lt;beans default-destroy-method=&amp;quot;destroy&amp;quot; default-init-method=&amp;quot;afterPropertiesSet&amp;quot;
   xmlns=&amp;quot;http://www.springframework.org/schema/beans&amp;quot; xmlns:xsi=&amp;quot;http://www.w3.org/2001/XMLSchema-instance&amp;quot;
   xsi:schemaLocation=&amp;quot;http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd&amp;quot;&amp;gt;

   &amp;lt;!-- To define an external data source, the liferayDataSource Spring bean 
       must be overridden. Other default Spring beans like liferaySessionFactory 
       and liferayTransactionManager may optionally be overridden. 

       liferayDataSourceFactory refers to the data source configured on the
       application server. --&amp;gt;
   &amp;lt;bean class=&amp;quot;com.liferay.portal.dao.jdbc.spring.DataSourceFactoryBean&amp;quot;
       id=&amp;quot;liferayDataSourceFactory&amp;quot;&amp;gt;
       &amp;lt;property name=&amp;quot;propertyPrefix&amp;quot; value=&amp;quot;jdbc.sakai.mysql.&amp;quot; /&amp;gt;
       
   &amp;lt;/bean&amp;gt;

   &amp;lt;!-- The data source bean refers to the factory to access the data source.
   --&amp;gt;
   &amp;lt;bean
       class=&amp;quot;org.springframework.jdbc.datasource.LazyConnectionDataSourceProxy&amp;quot;
       id=&amp;quot;liferayDataSource&amp;quot;&amp;gt;
       &amp;lt;property name=&amp;quot;targetDataSource&amp;quot; ref=&amp;quot;liferayDataSourceFactory&amp;quot; /&amp;gt;
   &amp;lt;/bean&amp;gt;

   &amp;lt;!-- In service.xml, we associated our entity with the extDataSource. To 
       associate the extDataSource with our overridden liferayDataSource, we define 
       this alias. --&amp;gt;
  
&amp;lt;/beans&amp;gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;
  &lt;br /&gt; and the same prefix , we added inside portal-ext.properties : &lt;br /&gt;
  &lt;br /&gt;  &lt;/p&gt;
&lt;pre&gt;
&lt;code class="language-java"&gt;jdbc.sakai.mysql.driverClassName=com.mysql.jdbc.Driver
jdbc.sakai.mysql.url=jdbc:mysql://**MySAKAIURL**/sakai12?useUnicode=true&amp;amp;characterEncoding=UTF-8&amp;amp;useFastDateParsing=false
jdbc.sakai.mysql.username=***
jdbc.sakai.mysql.password=***
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;
  &lt;br /&gt; is anything extra configuration require in 7.3 ?&lt;br /&gt;
  &lt;br /&gt;
  &lt;br /&gt;
  &lt;br /&gt;
  &lt;br /&gt;
  &lt;br /&gt;
  &lt;br /&gt;  &lt;/p&gt;</summary>
    <dc:creator>pradip choudhari</dc:creator>
    <dc:date>2021-06-22T16:01:58Z</dc:date>
  </entry>
</feed>
