Foros de discusión

Indexing Implementation in Join Table

thumbnail
Edson Ma, modificado hace 11 años.

Indexing Implementation in Join Table

New Member Mensajes: 6 Fecha de incorporación: 28/07/11 Mensajes recientes
People,

How ar you? I want to ask if there's possibility to Index (using liferay lucene) a join table in Liferay.

My entity is showed ahead (got from my servive.xml):
<entity name="SistemaProducao_Topico_Conteudo" cache-enabled="false" remote-service="false" local-service="true">
<column name="relationId" type="long" primary="true" />
<column name="companyId" type="long" />
<column name="groupId" type="long" />
<column name="sistemaProducaoId" type="long" primary="true"/>
<column name="topicoId" type="long" primary="true" />
<column name="ordem" type="long" />
<column name="content_html" type="String" />

......
</entity>

I implemented the Indexing class :
public class SPTopicoConteudoIndexer extends BaseIndexer { ... }

And put all configurations in portlet.xml and liferay-portlet.xml to make that model looks like a Portlet to be indexed.

After that, when I call the indexing methods... it shows Cast Exceptions.
com.liferay.portal.kernel.search.SearchException: java.lang.ClassCastException: br.com.seatecnologia.embrapa.service.persistence.SistemaProducao_Topico_ConteudoPK cannot be cast to java.lang.Long ........

Are there any way to do that?

Thanks in Advance

Cheers