Search code examples
javaliferay

Liferay: can't deploy module. Unresolved requirement: Require-Capability: osgi.ee; filter:="(osgi.ee=UNKNOWN)"


I recently started Liferay development and I'm following the official developer guide, but I'm having trouble when trying to deploy a simple hello world module.

When I try to deploy the module, Eclipse console shows the following exception:

org.osgi.framework.BundleException: Could not resolve module: com.liferay.docs.guestbook.portlet [1000]_ Unresolved requirement: Require-Capability: osgi.ee; filter:="(osgi.ee=UNKNOWN)"_ [Sanitized]

I'm stuck at this point, and don't know what to do. I tried using different Eclipse versions, I tried changing projects' Java build path to use JRE 1.8, I tried deleting the project and creating a new one...

I also used the command "ss" to list the modules, but apparently my module isn't listed.

I'm under Ubuntu 18.04 and using Eclipse 2018-12 build.

Thank you.


Solution

  • Problem solved.

    I was using Eclipse + Liferay on an Ubuntu VM, then I switched to my host machine (W10) and installed Oracle JDK and module was deployed correctly.

    So I guess the problem was using JRE instead of full JDK.