Liferay elastic search - indexing a Liferay table

Leo Volkov, modified 7 Years ago. New Member Posts: 7 Join Date: 11/30/12 Recent Posts

Hi - I see that Layout table is not indexed in Liferay by default (dont see it part of Index Actions under system administration), is there someway to add it to indexing or do we have to write the indexer ?  Thanks 

thumbnail
Jorge Díaz, modified 7 Years ago. Liferay Master Posts: 753 Join Date: 1/9/14 Recent Posts

If you want to index Layout objects, you have to write a new Indexer.

You have also to modify Liferay Layout code in order to call new indexer because Liferay out of the box doesn't call the indexer in every operation. For more information see this post: https://community.liferay.com/forums/-/message_boards/message/96835069

Leo Volkov, modified 7 Years ago. New Member Posts: 7 Join Date: 11/30/12 Recent Posts

Thank you !

Leo Volkov, modified 6 Years ago. New Member Posts: 7 Join Date: 11/30/12 Recent Posts

Hi - What is the best way to create a indexer in liferay 7 , is it as a liferay module project or hook ? I use eclipse ide. Thanks

thumbnail
Ashish Singh, modified 6 Years ago. Junior Member Posts: 45 Join Date: 12/1/16 Recent Posts

Hi Leo,

You can create a module project to create an Indexer and LayoutServiceWrapper to update and delete Indexes

There is an excellent tutorial for same by liferay at  https://dev.liferay.com/develop/tutorials/-/knowledge_base/7-0/creating-a-guestbook-indexer

Leo Volkov, modified 6 Years ago. New Member Posts: 7 Join Date: 11/30/12 Recent Posts
thank you