I’m hopefully near the end of the TeamCity plugin development process and I have one more hurdle to jump.
My plugin has a server and an agent part.
The server plugin is an Admin Page extension which adds one more tab, and that is used for a single item of global configuration.
The agent plugin is in two parts: an implementation of a BuildCommandLineProcessor, and an extension of an AgentLifeCycleAdapter. The former captures the BuildRunner’s command line prior to its execution and then modifies it to suit my requirements and then returns it to be executed (code compilation) by the underlying TeamCity framework. The latter listens for the beforeBuildFinish event, which occurs after the runners have all been run, but before the build is given a final status, generally Success or Failure. During this ‘phase’, an external utility is called using Java’s ProcessBuilder. The output from this utility is logged and is available, still within this ‘phase’. This output, for the purpose of this issue, is a String, which is a URL that shows analysis results from the custom processing.
My objective is to display this URL as a functional link in the, ‘Build shortcuts’, ‘popup’, which appears when clicking the ‘drop-arrow’ right next to the build status. More specifically, the, ‘Build shortcuts’, ‘popup’, usually shows something like:
Build log | .zip
I’d like it to show something very much like the above, but underneath, ‘Parameters’, I’d like to show the URL.
I’m hoping that something like this has already been done, or if not, you could give me some pointers on the ‘architecture’ & requirements behind getting this up and running. As a milestone, just getting the URL to display there as plain text would be good.
I hope the requirements are clear and if so, if you feel that there is a better way of accomplishing this task, feel free to suggest it.
Thank you very much,
ps: some other questions:
- What is the mechanism by which the build agent that performed the processing, makes the url available to the server to be displayed as described?
- Where are there examples of the locations that PlaceId s define (the java docs aren't explicit)?
Message was edited by: Nic Pantieras, to add postscript questions