I'm developing my own custom Jenkins plugin that generates a report from GT Metrix. The lack of documentation is making this extremely difficult.
What I have so far:
I've successfully built a plugin that compiles. You set a username and api key in the global Jenkins setting. You set a website in your build config. When you build the project it will run a GT Metrix report and wait for it to finish, then download all of the information from the report. I've set up a project action with a floatingBox.jelly and the HTML shows up on the project page.
What I need:
Now that I have the report and I have the floatingBox.jelly showing up on the project page I want it to display values from the reports so I do ${from.report.pageLoadTime}
. I believe I've set up everything correctly. If I do ${from.report}
it displays the reference like org.jenkinsci.plugins.gtmetrix.GtMetrixReportResource@1bd5b1dc
. but the extra .pageLoadTime
displays nothing. I don't get why it has the resource but it won't call any functions from inside that resource.
Source Code https://github.com/chrislondon/jenkins-gtmetrix-plugin