Legacy Knowledge Base
Published Jul. 2, 2025

Commerce modules fail to deploy due following license expiration

Written By

Brian Suh

How To articles are not official guidelines or officially supported documentation. They are community-contributed content and may not always reflect the latest updates to Liferay DXP. We welcome your feedback to improve How To articles!

While we make every effort to ensure this Knowledge Base is accurate, it may not always reflect the most recent updates or official guidelines.We appreciate your understanding and encourage you to reach out with any feedback or concerns.

Legacy Article

You are viewing an article from our legacy "FastTrack" publication program, made available for informational purposes. Articles in this program were published without a requirement for independent editing or verification and are provided"as is" without guarantee.

Before using any information from this article, independently verify its suitability for your situation and project.
Note: please note that Liferay has renamed its Liferay Experience Could offerings to Liferay SaaS (formerly LXC) and Liferay PaaS (formerly LXC-SM).

Issue

  • There has been a documented case where Commerce modules fail to deploy following license expiration and redeployment
WARN [fileinstall-directory-watcher][PortalLicenseEnterpriseAppGateKeeper:333]
Unable to install bundle com.liferay.commerce.account.admin.web-3.0.8.jar?
lpkgPath=file:/opt/liferay/osgi/marketplace/Liferay%20Commerce%20-%20Liferay
%20Commerce%20-%20Impl.lpkg

Environment

  • Liferay PaaS
  • Liferay Commerce

Resolution

  • This may be caused by a race condition during the deployment process where the Commerce module is deployed prior to the updated license's deployment. As a workaround, instead of copying the updated Commerce license XML into the service's deploy folder, you can obtain the .li file in /data/license after you deploy the license.xml into a local Liferay instance. Once the .li file is generated you can then copy that into your service build folder.

  • For example when using Liferay Experience Cloud-SM, an admin can:

    1. Deploy license.xml in a local instance so that the .li file is generated (the .li file will be in the {$liferay.home}/data/license directory)
    2. Put that in your /liferay/configs folder and make note of its location (ENV being the target environment, e.g. dev, prd, uat)
    3. Write a .sh script that will copy the .li file into the Liferay service's /data/license directory from the directory specified in step 2.

Additional Information

  • More information on custom script execution can be found here.
  • If there is an XML license in the environment's configs/{env}/deploy directory, it can interfere with the .sh script and contribute to the race condition. In this case, remove the XML license from the build prior to deployment.
Did this article resolve your issue ?

Legacy Knowledge Base