Hi,
all you have to do is to add
implements RootAction
to your class (which is also marked by @Extension annotation) and implement
public String getUrlName() method with returns correct URL of the page you want to display.
HTH
Vojta
Stapler processed this HTTP request as follows, but couldn't find the resource to consume the request
-> evaluate(<hudson.model.Hudson@1299db6> :hudson.model.Hudson,"/dummyurl")
-> evaluate(((StaplerProxy)<hudson.model.Hudson@1299db6>).getTarget(),"/dummyurl")
-> evaluate(<hudson.model.Hudson@1299db6>.getDynamic("dummyurl",...),"")
-> evaluate(<hudson.plugins.sidebar_link.LinkAction@ebb788> :hudson.plugins.sidebar_link.LinkAction,"")
-> No matching rule was found on <hudson.plugins.sidebar_link.LinkAction@ebb788> for ""
<hudson.plugins.sidebar_link.LinkAction@ebb788> has the following URL mappings, in the order of preference:
getUrlName() can return existing links or do the mapping of given object to URL, see Action javadoc [1] for details.
Probably the most easy way how to display something is e.g. this:
@Extension
public class DataPlotRoot implements RootAction {
public String getIconFileName() {
return "/plugin/data-processing-plugin/img/x-office-presentation.png";
}
public String getDisplayName() {
return "Data processing";
}
public String getUrlName() {
return "data-processing";
}
}
and in put into (applies for plugin org.jenkinsci.plugins.dataprocessing) src/main/resources/org/jenkinsci/plugins/dataprocessing/DataPlotRoot/
file called index.jelly
Content of this file will be shown when you click the link.
[1] http://javadoc.jenkins-ci.org/hudson/model/Action.html#getUrlName()