serviceliferayliferay-6.2

Error when adding new table on service.xml - Liferay 6.2


I'm using liferay 6.2 and I want to add a new table on service.xml.

The new entry on service.xml is:

<entity name="FeedError" local-service="true" remote-service="false" cache-enabled="false">

<column name="feId" type="long" primary="true" id-type="identity" />

<column name="errorCode" type="String" />

<column name="translation" type="String" />

<column name="facility" type="String" />

<column name="recordId" type="long" />

<column name="dateTime" type="Date" />

</entity>

Then, when running Build Service with Ant or Liferay Plugin, I got the following error:

BUILD FAILED

/Liferay/liferay-plugins-sdk-6.2/build-common-plugin.xml:443: The following error occurred while executing this line:

/Liferay/liferay-plugins-sdk-6.2/build-common-plugin.xml:147: Service Builder generated exceptions.

Looking at build-common-plugin.xml:443 is:

439:    <build-service
440:     service.api.dir="${basedir}/${service.base.dir}/service"
441:     service.sql.dir="${basedir}/${service.base.dir}/sql"
442:     service.test.dir=""
443:     />

The error is only when adding a new entry to service.xml; for existing ones, it builds without any issue. 

Any help is great appreciate! 


Solution

  • I hardly remember that there was an issue with the keyword "error" in table or column names. The service builder once greped for this keyword. You might give it a try to not use the word "error" in your column definition.