All the other portlet settings can be configured by specifying
<init-param>
entities in the
portlet.xml
. The common init-parameters supported by every portlet are:
monitored.resource
It is used only for display purposes, doesn't affect the functionality.
service.url
It points to the appropriate Hessian-service. For
example, in the case of
SfMonitoringPortlet
it can be:
http://localhost:8080/kosmos-server/sf-service
.
A quick check to test whether the service is available at
the given URL is opening the URL in a normal browser
window. You should see a “Hessian requires
POST” error message if everything is fine.
monitored.urls
(or
monitored.dirs
)Comma-separated list of items to monitor. Depending on the portlet, items can be URLs or directory paths:
CcMonitoringPortlet
: path
of the directories where CruiseControl produces its
logfiles related to the projects to monitor. For
example:
/cruisecontrol/logs/myproject1,/cruisecontrol/logs/myproject2
.
This portlet is not configured properly in the default
portlet.xml
shipped in the package,
because it requires local paths!
JiraMonitoringPortlet
:
URLs of the JIRA home pages related to the projects to monitor.
For example:
http://jira.jboss.com/jira/browse/JBWIKI,http://jira.jboss.com/jira/browse/JBLAB
.
SFMonitoringPortlet
: URLs
of the SourceForge pages which host the projects to
monitor. For example:
http://www.sourceforge.net/projects/springframework,http://sourceforge.net/projects/acegisecurity
.
SvnMonitoringPortlet
: URLs
of the Subversion repositories to monitor. For
example:
http://svn.apache.org/repos/asf/commons,http://svn.apache.org/repos/asf/db
.
If you have secure repositories, you must include the username
and the password in the URL:
http://myusername:mypassword@www.mycompany.com/svn/mysecurerepo
.
Please note that the security information will not appear in
the user interface, so if you restrict the access to portlet.xml
and the serverside log, then it's completely safe.
Here is a section of the default
portlet.xml
file shipped in the distribution:
<portlet> <portlet-name>KosmosDependenciesSfMonitoringPortlet</portlet-name> <portlet-class>hu.midori.kosmos.portlet.sf.SfMonitoringPortlet</portlet-class> <supported-locale>en</supported-locale> <supported-locale>hu</supported-locale> <resource-bundle>hu.midori.kosmos.portlet.sf.sf_monitoring</resource-bundle> <init-param> <name>monitored.resource</name> <value>Kosmos Dependencies</value> </init-param> <init-param> <name>service.url</name> <value>http://localhost:8080/kosmos-server/kosmos-services/sf-service</value> </init-param> <init-param> <name>monitored.urls</name> <value> http://sourceforge.net/projects/cruisecontrol/, http://sourceforge.net/projects/displaytag/, http://sourceforge.net/projects/jfreechart/, http://sourceforge.net/projects/jtidy/, http://sourceforge.net/projects/saxon/, http://www.sourceforge.net/projects/springframework </value> </init-param> <supports> <mime-type>text/html</mime-type> <portlet-mode>HELP</portlet-mode> <portlet-mode>VIEW</portlet-mode> </supports> <portlet-info> <title>SourceForge Monitoring</title> </portlet-info> </portlet>
Had you any problems or question, first please study the
default
portlet.xml
, probably you will find
the answer there.