Foren
portal-ext.properties is not recognized
Christian Straube, geändert vor 11 Jahren.
portal-ext.properties is not recognized
New Member Beiträge: 18 Beitrittsdatum: 25.04.12 Neueste Beiträge
Hi,
I want to avoid that Liferay queries the repositories, since I'm developing my own portlets. To do so I did the following:
1) Look in my Server > Server Administration > Properties > System properties for "default.liferay.home" (is set to "/opt/apache")
2) Put in "/opt/apache" the file portal-ext.properties with the following content
plugin.repositories.trusted=
plugin.notifications.enabled=false
3) restart Liferay
But it is still trying to connect :-( When I go to the upload page for new portlets, I get this message in the logfile:
17:32:29,294 WARN [PluginPackageUtil:1399] Unable to communicate with repository http://plugins.liferay.com/official
17:32:29,445 WARN [PluginPackageUtil:333] Unable to communicate with repository http://plugins.liferay.com/official
17:32:39,306 WARN [browse_repository_jspf:3221] Unable to communicate with repository http://plugins.liferay.com/official
17:32:39,454 WARN [PluginPackageUtil:333] Unable to communicate with repository http://plugins.liferay.com/community
Where is my mistake?
Thank you!!
I want to avoid that Liferay queries the repositories, since I'm developing my own portlets. To do so I did the following:
1) Look in my Server > Server Administration > Properties > System properties for "default.liferay.home" (is set to "/opt/apache")
2) Put in "/opt/apache" the file portal-ext.properties with the following content
plugin.repositories.trusted=
plugin.notifications.enabled=false
3) restart Liferay
But it is still trying to connect :-( When I go to the upload page for new portlets, I get this message in the logfile:
17:32:29,294 WARN [PluginPackageUtil:1399] Unable to communicate with repository http://plugins.liferay.com/official
17:32:29,445 WARN [PluginPackageUtil:333] Unable to communicate with repository http://plugins.liferay.com/official
17:32:39,306 WARN [browse_repository_jspf:3221] Unable to communicate with repository http://plugins.liferay.com/official
17:32:39,454 WARN [PluginPackageUtil:333] Unable to communicate with repository http://plugins.liferay.com/community
Where is my mistake?
Thank you!!
Milen Dyankov, geändert vor 11 Jahren.
RE: portal-ext.properties is not recognized
Regular Member Beiträge: 171 Beitrittsdatum: 23.09.09 Neueste Beiträge
Similar issue was reported some time ago: http://issues.liferay.com/browse/LPS-7792.
Perhaps the value is persisted in the database and thus can not be changed via portal-ext.properties.
Perhaps the value is persisted in the database and thus can not be changed via portal-ext.properties.
Christian Straube, geändert vor 11 Jahren.
RE: portal-ext.properties is not recognized
New Member Beiträge: 18 Beitrittsdatum: 25.04.12 Neueste Beiträge
I have searched the DB
No results... What exactly is the result of the ticket you referenced :-) It was closed due to inactivity
SELECT * FROM lportal.PortletPreferences WHERE preferences LIKE '%repositories%';
No results... What exactly is the result of the ticket you referenced :-) It was closed due to inactivity
Milen Dyankov, geändert vor 11 Jahren.
RE: portal-ext.properties is not recognized
Regular Member Beiträge: 171 Beitrittsdatum: 23.09.09 Neueste Beiträge
OK, so it's not in the database! Of course assuming you are absolutely sure you are checking in the correct database!
Make sure you are placing your portal-ext.properties in the folder where Liferay is installed. Don't know your setup but /opt/apache just does not sound like Liferay home. The folder you are looking for, is the one containing something similar to:
Make sure you are placing your portal-ext.properties in the folder where Liferay is installed. Don't know your setup but /opt/apache just does not sound like Liferay home. The folder you are looking for, is the one containing something similar to:
drwxr-xr-x 7 liferay liferay 4096 2011-12-21 10:37 data
drwxr-xr-x 2 liferay liferay 4096 2012-05-28 14:03 deploy
drwxr-xr-x 2 liferay liferay 4096 2011-12-19 11:05 license
drwxr-xr-x 2 liferay liferay 4096 2012-05-28 13:21 logs
drwxr-xr-x 10 liferay liferay 4096 2011-12-19 11:15 tomcat-7.0.23
Zsolt Balogh, geändert vor 11 Jahren.
RE: portal-ext.properties is not recognized
Expert Beiträge: 463 Beitrittsdatum: 23.03.09 Neueste Beiträge
Hi,
Liferay is using EasyConf to load the properties files. Easyconf has the following loading order when checking files:
(Copied from here).
You can also verify which properties file is loaded by checking the system output while starting Liferay:
Loading file:[..]portal-ext.properties
Usually the problem is that the file is not picked up (it's not on Liferay home / class path). Please note that the Liferay home is different in various app servers, you can find the defaults here: https://github.com/liferay/liferay-portal-ee/blob/master/portal-impl/src/com/liferay/portal/util/PropsUtil.java#L252
I hope this will help you to find the root of the problem.
Zsolt
Liferay is using EasyConf to load the properties files. Easyconf has the following loading order when checking files:
- URL: checks if the specified file name is a valid URL and if it is tries to get it.
- File system: if it is an absolute path (starts with a slash) it is interpreted from the root of the file system. Otherwise the directory where the JVM is being executed will be used as the base directory.
- User home directory: the home directory obtained with the user.home system property will be used as the base directory
- Context classpath
- System claspath
(Copied from here).
You can also verify which properties file is loaded by checking the system output while starting Liferay:
Loading file:[..]portal-ext.properties
Usually the problem is that the file is not picked up (it's not on Liferay home / class path). Please note that the Liferay home is different in various app servers, you can find the defaults here: https://github.com/liferay/liferay-portal-ee/blob/master/portal-impl/src/com/liferay/portal/util/PropsUtil.java#L252
I hope this will help you to find the root of the problem.
Zsolt
JB Burbea, geändert vor 11 Jahren.
RE: portal-ext.properties is not recognized
Junior Member Beiträge: 37 Beitrittsdatum: 05.04.12 Neueste Beiträge
Hi Zsolt,
Thanks for a good post on handling the LifeRay home portal-ext.properties.
How do teams deal with separate deployments of the LifeRay instance in the same JVM with different context paths on the same app server?
Most expensive app servers on a mid-range like to WebSphere can have several instances of the same app deployed on the same app server.
How would you point a specific deployment of LifeRay war to point to specific LifeRay home?
Thanks for a good post on handling the LifeRay home portal-ext.properties.
How do teams deal with separate deployments of the LifeRay instance in the same JVM with different context paths on the same app server?
Most expensive app servers on a mid-range like to WebSphere can have several instances of the same app deployed on the same app server.
How would you point a specific deployment of LifeRay war to point to specific LifeRay home?
Hitoshi Ozawa, geändert vor 11 Jahren.
RE: portal-ext.properties is not recognized
Liferay Legend Beiträge: 7942 Beitrittsdatum: 24.03.10 Neueste Beiträge
Try putting in portal-ext.properties in ROOT\WEB-INF\classes directory
plugin.repositories.trusted=
plugin.repositories.untrusted=
plugin.repositories.trusted=
plugin.repositories.untrusted=