Issue
- We installed Liferay Connector to Elasticsearch 6 from Liferay's Marketplace on fix pack 11 patch-level. Now that we moved to fix pack 12, we started to get the below exceptions:
WARN [liferay/search_writer/SYSTEM_ENGINE-3][ProxyMessageListener:88] java.lang.NullPointerException
at com.liferay.portal.search.elasticsearch6.internal.ElasticsearchIndexWriter.updateDocument(ElasticsearchIndexWriter.java:249)
at sun.reflect.GeneratedMethodAccessor291.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
/*cut for brevity*/
Environment
- Liferay DXP 7.1+
- Connected to standalone Elasticsearch (supported version)
Resolution
- Reason: In DXP 7.1+, Liferay Connector to Elasticsearch 6 is installed by default and updated through Liferay DXP Fix Packs. Using Liferay Marketplace to update the app on Liferay 7.1+ will cause an error, referring to the Marketplace app description.
-
Resolution (there are two ways):
a) Replace the core osgi modules to the original ones
b) Reinstall the portal from scratch -
Resolution a) Replace the core OSGi modules to the original ones
-
Steps:
-
Create a vanilla DXP 7.1 bundle patched with fix pack 11 to take the core modules from ('Source')
-
Revert the Portal to fix pack 11 ('Target')
- Replace the core modules of Target to the core modules from Source in:
LR_home/osgi/core
LR_home/osgi/marketplace
LR_home/osgi/target-platform
LR_home/osgi/test
LR_home/osgi/configsMind keeping your custom configuration files in LR_home/osgi/configs.
-
Patch your Portal with fix pack 12
-
-