Ask Questions and Find Answers
Important:
Ask is now read-only. You can review any existing questions and answers, but not add anything new.
But - don't panic! While ask is no more, we've replaced it with discuss - the new Liferay Discussion Forum! Read more here here or just visit the site here:
discuss.liferay.com
RE: Portal upgrade from 7.0 CE to 7.2 CE or 7.1 CE
Hello has anyone successful upgraded to 7.2 or 7.1? If you have successfully upgrade can you share with me the steps you took to do the upgrade
The steps are all well documented. Check the documentation for your target version, which contains the information on how to upgrade from the previous version(s)
Hi Kock, the liferay install planner only goes up to version 7.1 and not 7.2 so I cant use the planner to upgrade. Can I use C:\Liferay7.2\liferay-ce-portal-7.2.0-ga1\tools\portal-tools-db-upgrade-client
Attachments:
Hi Kevin,A lot of customers and users upgraded successfully to 7.1 and several ones to 7.2. Can you explain more in detail what's the issue you are experiencing with the upgrade?Thanks.
Hi Alberto, I am currently using version 7.0 GA3 running on Wildfly 10.0. When I try to use the upgrade tool it does not show upgrade to 7.1. I would like to upgrade from 7.0 to 7.2 . I was looking at the website but it seems to wordy. Can you give me specific detail instruction on the best way to upgrade to 7.2 from 7.0.
ThanksKevin
ThanksKevin
Attachments:
Hi Kevin,An upgrade process is divided into two steps:
- Upgrade the database. For this one, you need to follow these steps: https://portal.liferay.dev/docs/7-2/deploy/-/knowledge_base/d/upgrading-to-product-ver
- Upgrade your custom code. For this, you can use the Liferay Code Upgrade Tool (the one you are using) or the Liferay Planner: https://portal.liferay.dev/docs/7-2/tutorials/-/knowledge_base/t/upgrading-code-to-product-ver
Hi Alberto, I was able to run upgrade_client.jar from the tools folder. I do see my database is update with version 7.2. But I am having a problem in updating my new module jars. if I drop the jar files I get the following error below. Could you let me know the procedure on doing the code upgrade as the instructions on the web requires workspace but my workspace shows only shows version 7.1 and I am using version 7.2
2020-02-07 19:07:32.659 INFO [com.liferay.portal.kernel.deploy.auto.AutoDeployScanner][AutoDeployDir:259] Processing artifactprojectmanager-api-1.0.0.jar
2020-02-07 19:07:39.942 ERROR [fileinstall-C:/liferay-ce-portal-7.2.1-ga2/osgi/modules][LogService:93] Error while starting bundle: file:/C:/liferay-ce-portal-7.2.1-ga2/osgi/modules/artifactprojectmanager-api-1.0.0.jar
org.osgi.framework.BundleException: Could not resolve module: artifactprojectmanager-api [1065]_ Unresolved requirement: Import-Package: com.liferay.expando.kernel.model; version="[1.0.0,2.0.0)"_ [Sanitized]
at org.eclipse.osgi.container.Module.start(Module.java:444)
at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:428)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1275)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1248)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:520)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316)
2020-02-07 19:23:56.943 INFO [com.liferay.portal.kernel.deploy.auto.AutoDeployScanner][AutoDeployDir:259] Processing artifactprojectmanager-api-1.0.0.jar
2020-02-07 19:24:05.387 ERROR [fileinstall-C:/liferay-ce-portal-7.2.1-ga2/osgi/modules][LogService:93] Error while starting bundle: file:/C:/liferay-ce-portal-7.2.1-ga2/osgi/modules/artifactprojectmanager-api-1.0.0.jar
org.osgi.framework.BundleException: Could not resolve module: artifactprojectmanager-api [1065]_ Unresolved requirement: Import-Package: com.liferay.expando.kernel.model; version="[1.0.0,2.0.0)"_ [Sanitized]
at org.eclipse.osgi.container.Module.start(Module.java:444)
at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:428)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1275)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1248)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startAllBundles(DirectoryWatcher.java:1237)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:515)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316)
2020-02-07 19:24:05.392 ERROR [fileinstall-C:/liferay-ce-portal-7.2.1-ga2/osgi/modules][LogService:93] Error while starting bundle: file:/C:/liferay-ce-portal-7.2.1-ga2/osgi/modules/artifactprojectmanager-api-1.0.0.jar
org.osgi.framework.BundleException: Could not resolve module: artifactprojectmanager-api [1065]_ Unresolved requirement: Import-Package: com.liferay.expando.kernel.model; version="[1.0.0,2.0.0)"_ [Sanitized]
at org.eclipse.osgi.container.Module.start(Module.java:444)
at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:428)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1275)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1248)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:520)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316)
2020-02-07 19:07:32.659 INFO [com.liferay.portal.kernel.deploy.auto.AutoDeployScanner][AutoDeployDir:259] Processing artifactprojectmanager-api-1.0.0.jar
2020-02-07 19:07:39.942 ERROR [fileinstall-C:/liferay-ce-portal-7.2.1-ga2/osgi/modules][LogService:93] Error while starting bundle: file:/C:/liferay-ce-portal-7.2.1-ga2/osgi/modules/artifactprojectmanager-api-1.0.0.jar
org.osgi.framework.BundleException: Could not resolve module: artifactprojectmanager-api [1065]_ Unresolved requirement: Import-Package: com.liferay.expando.kernel.model; version="[1.0.0,2.0.0)"_ [Sanitized]
at org.eclipse.osgi.container.Module.start(Module.java:444)
at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:428)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1275)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1248)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:520)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316)
2020-02-07 19:23:56.943 INFO [com.liferay.portal.kernel.deploy.auto.AutoDeployScanner][AutoDeployDir:259] Processing artifactprojectmanager-api-1.0.0.jar
2020-02-07 19:24:05.387 ERROR [fileinstall-C:/liferay-ce-portal-7.2.1-ga2/osgi/modules][LogService:93] Error while starting bundle: file:/C:/liferay-ce-portal-7.2.1-ga2/osgi/modules/artifactprojectmanager-api-1.0.0.jar
org.osgi.framework.BundleException: Could not resolve module: artifactprojectmanager-api [1065]_ Unresolved requirement: Import-Package: com.liferay.expando.kernel.model; version="[1.0.0,2.0.0)"_ [Sanitized]
at org.eclipse.osgi.container.Module.start(Module.java:444)
at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:428)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1275)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1248)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startAllBundles(DirectoryWatcher.java:1237)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:515)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316)
2020-02-07 19:24:05.392 ERROR [fileinstall-C:/liferay-ce-portal-7.2.1-ga2/osgi/modules][LogService:93] Error while starting bundle: file:/C:/liferay-ce-portal-7.2.1-ga2/osgi/modules/artifactprojectmanager-api-1.0.0.jar
org.osgi.framework.BundleException: Could not resolve module: artifactprojectmanager-api [1065]_ Unresolved requirement: Import-Package: com.liferay.expando.kernel.model; version="[1.0.0,2.0.0)"_ [Sanitized]
at org.eclipse.osgi.container.Module.start(Module.java:444)
at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:428)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1275)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1248)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:520)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316)
When you build your module, the build process determines the module versions you need. It generates the necessary import directives for your module to work.
Your module currently wants that the runtime provides com.liferay.expando.kernel.model; version="[1.0.0,2.0.0). This worked for 7.0, but in 7.2 (and 7.1) other versions are needed. The build process uses the version you used to compile the module. So, you need to look into the build.gradle file and increase the versions there.A good way to find the correct version is by looking into the maven repository. Let's say you have a line like:
https://mvnrepository.com/artifact/com.liferay.portal/com.liferay.portal.kernel
7.2 was released in June. And there was a 4.x version released in April. So, I would replace above line with
compileOnly group: "com.liferay.portal", name: "com.liferay.portal.kernel", version: "4.0.0"
You don't need to use a higher or exact version since this version is only used to determine the interfaces and just limits the runtime requirement to [4.00,5.0.0].
Your module currently wants that the runtime provides com.liferay.expando.kernel.model; version="[1.0.0,2.0.0). This worked for 7.0, but in 7.2 (and 7.1) other versions are needed. The build process uses the version you used to compile the module. So, you need to look into the build.gradle file and increase the versions there.A good way to find the correct version is by looking into the maven repository. Let's say you have a line like:
compileOnly group: "com.liferay.portal", name: "com.liferay.portal.kernel", version: "2.6.0"
in your build.gradle. I usually look up the module in maven repository:https://mvnrepository.com/artifact/com.liferay.portal/com.liferay.portal.kernel
7.2 was released in June. And there was a 4.x version released in April. So, I would replace above line with
compileOnly group: "com.liferay.portal", name: "com.liferay.portal.kernel", version: "4.0.0"
You don't need to use a higher or exact version since this version is only used to determine the interfaces and just limits the runtime requirement to [4.00,5.0.0].
Hi Chris/Alberto, I started form scratch again to do the upgrade. The database was updated using the 7.2 build number. Now when I start the liferay server in standalone mode I get the following error below. Can anyone help
10:41:34,959 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) WFLYCTL0013: Operation ("deploy") failed - address: ([("deployment" => "ROOT.war")]) - failure description: {"WFLYCTL0080: Failed services" => {"jboss.undertow.deployment.default-server.default-host./" => "java.lang.NoClassDefFoundError: com/liferay/portal/kernel/util/ServiceLoaderCondition
Caused by: java.lang.NoClassDefFoundError: com/liferay/portal/kernel/util/ServiceLoaderCondition
Caused by: java.lang.ClassNotFoundException: com.liferay.portal.kernel.util.ServiceLoaderCondition"}}
10:41:34,959 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) WFLYCTL0013: Operation ("deploy") failed - address: ([("deployment" => "ROOT.war")]) - failure description: {"WFLYCTL0080: Failed services" => {"jboss.undertow.deployment.default-server.default-host./" => "java.lang.NoClassDefFoundError: com/liferay/portal/kernel/util/ServiceLoaderCondition
Caused by: java.lang.NoClassDefFoundError: com/liferay/portal/kernel/util/ServiceLoaderCondition
Caused by: java.lang.ClassNotFoundException: com.liferay.portal.kernel.util.ServiceLoaderCondition"}}
It seems that this class ServiceLoaderCondition belongs into Liferay CE 7.0 and not in Liferay CE 7.1. Need to know why its referencing this class.
10:41:34,959 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) WFLYCTL0013: Operation ("deploy") failed - address: ([("deployment" => "ROOT.war")]) - failure description: {"WFLYCTL0080: Failed services" => {"jboss.undertow.deployment.default-server.default-host./" => "java.lang.NoClassDefFoundError: com/liferay/portal/kernel/util/ServiceLoaderCondition
Caused by: java.lang.NoClassDefFoundError: com/liferay/portal/kernel/util/ServiceLoaderCondition
Caused by: java.lang.ClassNotFoundException: com.liferay.portal.kernel.util.ServiceLoaderCondition"}}
10:41:34,959 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) WFLYCTL0013: Operation ("deploy") failed - address: ([("deployment" => "ROOT.war")]) - failure description: {"WFLYCTL0080: Failed services" => {"jboss.undertow.deployment.default-server.default-host./" => "java.lang.NoClassDefFoundError: com/liferay/portal/kernel/util/ServiceLoaderCondition
Caused by: java.lang.NoClassDefFoundError: com/liferay/portal/kernel/util/ServiceLoaderCondition
Caused by: java.lang.ClassNotFoundException: com.liferay.portal.kernel.util.ServiceLoaderCondition"}}
Total wild guess: Stop the server, delete the osgi/state folder and start it again.
Wild guess 2: There is some liferay.home setting. Check if it is correct. (Maybe you copied the portal properties from the old server and it still points there ...)
Wild guess 2: There is some liferay.home setting. Check if it is correct. (Maybe you copied the portal properties from the old server and it still points there ...)
Hi Chris, I delete state folder from osgi directory and still got the same errror. Also, I verify in my portal setup that my home was not pointing to the 7.0 folder. Bt there was not exception before when i ran the process as it was trying to install some config files. Failed to install artifact: /appserver/liferay-ce-portal-7.2.1-ga2/osgi/configs/com.liferay.organizations.internal.configuration.OrganizationTypeConfiguration-default.config
com.liferay.portal.configuration.persistence.listener.ConfigurationModelListenerException: The listener com.liferay.organizations.internal.configuration.persistence.listener.OrganizationTypeConfigurationModelListener was unable to save configuration com.liferay.organizations.internal.configuration.OrganizationTypeConfiguration.
at com.liferay.organizations.internal.configuration.persistence.listener.OrganizationTypeConfigurationModelListener.onBeforeSave(OrganizationTypeConfigurationModelListener.jav
in(DBUpgrader.java:101)
2020-02-14 00:37:55.733 ERROR [main][LogService:93] Failed to install artifact: /appserver/liferay-ce-portal-7.2.1-ga2/osgi/configs/com.liferay.portal.vulcan.internal.configuration.VulcanConfiguration-bulk.config
java.lang.NullPointerException
at com.liferay.portal.vulcan.internal.configuration.persistence.listener.VulcanConfigurationModelListener.onAfterSave(VulcanConfigurationMo
I am going to install these config files from a liferay 7.2 installation on my windows machine and install on linux machine and do over the upgrade steap again. I want see if i get no exception in the upgrade logs.
Below is the steps i took to do the upgrade.1. Remove unused objects in Portal
2. Remove duplicate Struture names (ex document types
3. Manually built Liferay 7.2 on Wildfy https://portal.liferay.dev/docs/7-2/deploy/-/knowledge_base/d/installing-product-on-wildfly
5. Copy document_library to new environment
6. Disable indexer and autoUpgrade
7. Config osgi/config
added a file com.liferay.portal.search.configuration.IndexStatusManagerConfiguration.config to my folder [Liferay Home]/osgi/configs with the following content:
indexReadOnly=”true”
Then I added a file com.liferay.portal.upgrade.internal.configuration.ReleaseManagerConfiguration.config to the same folder [Liferay Home]/osgi/configs with autoUpgrade=”false” content.
8. Configure the upgrade tool
10. run upgrade tool java -jar com.liferay.portal.tools.db.upgrade.client.jar
11 Check the portal number in db that portal updae properly in DB which is 7200
12. Enable Indexer
com.liferay.portal.configuration.persistence.listener.ConfigurationModelListenerException: The listener com.liferay.organizations.internal.configuration.persistence.listener.OrganizationTypeConfigurationModelListener was unable to save configuration com.liferay.organizations.internal.configuration.OrganizationTypeConfiguration.
at com.liferay.organizations.internal.configuration.persistence.listener.OrganizationTypeConfigurationModelListener.onBeforeSave(OrganizationTypeConfigurationModelListener.jav
in(DBUpgrader.java:101)
2020-02-14 00:37:55.733 ERROR [main][LogService:93] Failed to install artifact: /appserver/liferay-ce-portal-7.2.1-ga2/osgi/configs/com.liferay.portal.vulcan.internal.configuration.VulcanConfiguration-bulk.config
java.lang.NullPointerException
at com.liferay.portal.vulcan.internal.configuration.persistence.listener.VulcanConfigurationModelListener.onAfterSave(VulcanConfigurationMo
I am going to install these config files from a liferay 7.2 installation on my windows machine and install on linux machine and do over the upgrade steap again. I want see if i get no exception in the upgrade logs.
Below is the steps i took to do the upgrade.1. Remove unused objects in Portal
2. Remove duplicate Struture names (ex document types
3. Manually built Liferay 7.2 on Wildfy https://portal.liferay.dev/docs/7-2/deploy/-/knowledge_base/d/installing-product-on-wildfly
- Installing dependencies to your application server
- Configuring your application server for Liferay Portal
- Deploying the Liferay Portal WAR file to your application server
- Create a separate Database
- Create a database dump from 7.0 and load into new database from step above
- Create file ‘portal-setup-wizard.properties’ with the DB connection properties inside:
5. Copy document_library to new environment
6. Disable indexer and autoUpgrade
7. Config osgi/config
added a file com.liferay.portal.search.configuration.IndexStatusManagerConfiguration.config to my folder [Liferay Home]/osgi/configs with the following content:
indexReadOnly=”true”
Then I added a file com.liferay.portal.upgrade.internal.configuration.ReleaseManagerConfiguration.config to the same folder [Liferay Home]/osgi/configs with autoUpgrade=”false” content.
8. Configure the upgrade tool
- app-server.properties
- portal-upgrade-database.properties
10. run upgrade tool java -jar com.liferay.portal.tools.db.upgrade.client.jar
11 Check the portal number in db that portal updae properly in DB which is 7200
12. Enable Indexer
Verify the build number 7201 in DB but I still get the same error below when I start the JBOSS/Wildfly app server.
20:22:13,687 ERROR [org.jboss.msc.service.fail] (ServerService Thread Pool -- 68) MSC000001: Failed to start service jboss.undertow.deployment.default-server.default-host./: org.jboss.msc.service.StartException in service jboss.undertow.deployment.default-server.default-host./: java.lang.NoClassDefFoundError: com/liferay/portal/kernel/util/ServiceLoaderCondition
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:84)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
at org.jboss.threads.JBossThread.run(JBossThread.java:320)
Caused by: java.lang.NoClassDefFoundError: com/liferay/portal/kernel/util/ServiceLoaderCondition
20:22:13,687 ERROR [org.jboss.msc.service.fail] (ServerService Thread Pool -- 68) MSC000001: Failed to start service jboss.undertow.deployment.default-server.default-host./: org.jboss.msc.service.StartException in service jboss.undertow.deployment.default-server.default-host./: java.lang.NoClassDefFoundError: com/liferay/portal/kernel/util/ServiceLoaderCondition
at org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:84)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
at java.util.concurrent.FutureTask.run(FutureTask.java:266)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at java.lang.Thread.run(Thread.java:745)
at org.jboss.threads.JBossThread.run(JBossThread.java:320)
Caused by: java.lang.NoClassDefFoundError: com/liferay/portal/kernel/util/ServiceLoaderCondition
Hi Chris, I have attached the log file. for the upgrade process. As you can see the errors in there and it made a complete upgrade.
Attachments:
There are only two errors at the start of the file and I honestly have never seen them before. I am also not sure, if they have any impact on the upgrade at all. I believe those errors basically just tell you that the configuration from the filesystem cannot be stored.
You can try to delete the two config files and restart the upgrade process (note: you probably want to restore them after the upgrade)
/appserver/liferay-ce-portal-7.2.1-ga2/osgi/configs/com.liferay.organizations.internal.configuration.OrganizationTypeConfiguration-default.config
/appserver/liferay-ce-portal-7.2.1-ga2/osgi/configs/com.liferay.portal.vulcan.internal.configuration.VulcanConfiguration-bulk.config
You can try to delete the two config files and restart the upgrade process (note: you probably want to restore them after the upgrade)
/appserver/liferay-ce-portal-7.2.1-ga2/osgi/configs/com.liferay.organizations.internal.configuration.OrganizationTypeConfiguration-default.config
/appserver/liferay-ce-portal-7.2.1-ga2/osgi/configs/com.liferay.portal.vulcan.internal.configuration.VulcanConfiguration-bulk.config
Christoph Rabel:
Hi Chris,
When you build your module, the build process determines the module versions you need. It generates the necessary import directives for your module to work.
Your module currently wants that the runtime provides com.liferay.expando.kernel.model; version="[1.0.0,2.0.0). This worked for 7.0, but in 7.2 (and 7.1) other versions are needed. The build process uses the version you used to compile the module. So, you need to look into the build.gradle file and increase the versions there.A good way to find the correct version is by looking into the maven repository. Let's say you have a line like:in your build.gradle. I usually look up the module in maven repository:compileOnly group: "com.liferay.portal", name: "com.liferay.portal.kernel", version: "2.6.0"
https://mvnrepository.com/artifact/com.liferay.portal/com.liferay.portal.kernel
7.2 was released in June. And there was a 4.x version released in April. So, I would replace above line with
compileOnly group: "com.liferay.portal", name: "com.liferay.portal.kernel", version: "4.0.0"
You don't need to use a higher or exact version since this version is only used to determine the interfaces and just limits the runtime requirement to [4.00,5.0.0].
Can you help/advise in resolving this.
I am installing Liferay 7.2 directly and not using migration tools. As I have shown you the error above you mention to change the portal kernel version to 4.0.0 I did that and the error went away. Now I am running my service build and i get an error in my service builder module see below.
2020-02-26 14:07:14.823 ERROR [fileinstall-C:/liferay-ce-portal-7.2.1-ga2/osgi/modules][LogService:93] Error while starting bundle: file:/C:/liferay-ce-portal-7.2.1-ga2/osgi/modules/artifactprojectmanager-service-1.0.0.jar
org.osgi.framework.BundleException: Could not resolve module: artifactprojectmanager-service [1066]_ Unresolved requirement: Import-Package: com.liferay.asset.kernel.service.persistence; version="[1.2.0,2.0.0)"_ [Sanitized]
at org.eclipse.osgi.container.Module.start(Module.java:444)
at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:428)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1275)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1248)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startAllBundles(DirectoryWatcher.java:1237)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:515)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316)
2020-02-26 14:07:14.827 ERROR [fileinstall-C:/liferay-ce-portal-7.2.1-ga2/osgi/modules][LogService:93] Error while starting bundle: file:/C:/liferay-ce-portal-7.2.1-ga2/osgi/modules/varmailartifactscheduler-1.0.0.jar
org.osgi.framework.BundleException: Could not resolve module: varmailartifactscheduler [1072]_ Unresolved requirement: Import-Package: com.liferay.portal.kernel.exception; version="[7.0.0,8.0.0)"_ [Sanitized]
at org.eclipse.osgi.container.Module.start(Module.java:444)
at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:428)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1275)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1248)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startAllBundles(DirectoryWatcher.java:1237)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:515)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316)
I change the kernel version to 4.0.0 and get build error message in my IDE " The project was not built since its build path is incomplete. Cannot find the class file for com.liferay.petra.string.StringBundler. Fix the build path then try building this project. The type com.liferay.petra.string.StringBundler cannot be resolved. It is indirectly referenced from required .class files" This error is in the service/persistence/PersistenceImpl class.. I search the internet and it says to use 7.0.0 DTD in service.xml but if i use version 4.0.0 it doesnt resolve the error. if I use kernel 3.0.0 it resolve the error but give me the error below. I change the service builder version to 1.0.202 and it still referencing the Petra StringBundler class .
Attachments:
Kevin Matthews:
Christoph Rabel:Hi Chris,
When you build your module, the build process determines the module versions you need. It generates the necessary import directives for your module to work.
Your module currently wants that the runtime provides com.liferay.expando.kernel.model; version="[1.0.0,2.0.0). This worked for 7.0, but in 7.2 (and 7.1) other versions are needed. The build process uses the version you used to compile the module. So, you need to look into the build.gradle file and increase the versions there.A good way to find the correct version is by looking into the maven repository. Let's say you have a line like:in your build.gradle. I usually look up the module in maven repository:compileOnly group: "com.liferay.portal", name: "com.liferay.portal.kernel", version: "2.6.0"
https://mvnrepository.com/artifact/com.liferay.portal/com.liferay.portal.kernel
7.2 was released in June. And there was a 4.x version released in April. So, I would replace above line with
compileOnly group: "com.liferay.portal", name: "com.liferay.portal.kernel", version: "4.0.0"
You don't need to use a higher or exact version since this version is only used to determine the interfaces and just limits the runtime requirement to [4.00,5.0.0].
Can you help/advise in resolving this.
I am installing Liferay 7.2 directly and not using migration tools. As I have shown you the error above you mention to change the portal kernel version to 4.0.0 I did that and the error went away. Now I am running my service build and i get an error in my service builder module see below.
2020-02-26 14:07:14.823 ERROR [fileinstall-C:/liferay-ce-portal-7.2.1-ga2/osgi/modules][LogService:93] Error while starting bundle: file:/C:/liferay-ce-portal-7.2.1-ga2/osgi/modules/artifactprojectmanager-service-1.0.0.jar
org.osgi.framework.BundleException: Could not resolve module: artifactprojectmanager-service [1066]_ Unresolved requirement: Import-Package: com.liferay.asset.kernel.service.persistence; version="[1.2.0,2.0.0)"_ [Sanitized]
at org.eclipse.osgi.container.Module.start(Module.java:444)
at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:428)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1275)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1248)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startAllBundles(DirectoryWatcher.java:1237)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:515)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316)
2020-02-26 14:07:14.827 ERROR [fileinstall-C:/liferay-ce-portal-7.2.1-ga2/osgi/modules][LogService:93] Error while starting bundle: file:/C:/liferay-ce-portal-7.2.1-ga2/osgi/modules/varmailartifactscheduler-1.0.0.jar
org.osgi.framework.BundleException: Could not resolve module: varmailartifactscheduler [1072]_ Unresolved requirement: Import-Package: com.liferay.portal.kernel.exception; version="[7.0.0,8.0.0)"_ [Sanitized]
at org.eclipse.osgi.container.Module.start(Module.java:444)
at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:428)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1275)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1248)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startAllBundles(DirectoryWatcher.java:1237)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:515)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316)
I change the kernel version to 4.0.0 and get build error message in my IDE " The project was not built since its build path is incomplete. Cannot find the class file for com.liferay.petra.string.StringBundler. Fix the build path then try building this project. The type com.liferay.petra.string.StringBundler cannot be resolved. It is indirectly referenced from required .class files" This error is in the service/persistence/PersistenceImpl class.. I search the internet and it says to use 7.0.0 DTD in service.xml but if i use version 4.0.0 it doesnt resolve the error. if I use kernel 3.0.0 it resolve the error but give me the error below. I change the service builder version to 1.0.202 and it still referencing the Petra StringBundler class .
Hi Kris, I figured out the problem. Based on what was stated in the error above I just needed to added petra dependency. I used kernel 4.0.0 and dtd 7.2.0.0 and i added the petra dependency in my gradle build file and the error was gone.
apply plugin: "com.liferay.portal.tools.service.builder"dependencies {
compileOnly group: "biz.aQute.bnd", name: "biz.aQute.bndlib", version: "3.1.0"
compileOnly group: "com.liferay", name: "com.liferay.osgi.util", version: "3.0.0"
compileOnly group: "com.liferay", name: "com.liferay.portal.spring.extender", version: "2.0.0"
//compileOnly group: "com.liferay.portal", name: "com.liferay.portal.kernel", version: "2.6.0"
serviceBuilder group: "com.liferay", name: "com.liferay.portal.tools.service.builder", version: "1.0.202"
compileOnly group: "com.liferay.portal", name: "com.liferay.portal.kernel", version: "4.0.0"
compileOnly group: "com.liferay", name: "com.liferay.petra.string", version: "2.0.0"
compile 'org.apache.commons:commons-lang3:3.2.1'
compile 'commons-io:commons-io:2.4'
compile group: 'com.google.code.gson', name: 'gson', version: '2.8.0'
compileOnly project(":ArtifactProjectManager-api")
}buildService {
apiDir = "../ArtifactProjectManager-api/src/main/java"
osgiModule = true
propsUtil = "com.fdc.artifact.builder.service.util.PropsUtil"
We're on EE so have support. But no luck on upgrading so far to 7.2.
Our public pages have been wiped out. We can type in the urls and the pages are there but navigation is impossible. We lost navigation replaced by Miller but at upgrade Miller just didn't work. It's blank, you can't even add a new page.
So there is no way to manage or navigate pages at the moment.
Our public pages have been wiped out. We can type in the urls and the pages are there but navigation is impossible. We lost navigation replaced by Miller but at upgrade Miller just didn't work. It's blank, you can't even add a new page.
So there is no way to manage or navigate pages at the moment.
Copyright © 2025 Liferay, Inc
• Privacy Policy
Powered by Liferay™