Accessing Maven Build Info


We are developing a plugin that will queue new builds when some maven depenedcies changes. To do that, it would be very nice to access the Maven Build Info that is generated by the Maven runner for the latest build.

I know how to get an object of SBuild describing the latest build, is there a possibility to access the MavenBuildInfo associated with that build?

Second questions - is there a possibility to use MavenChangeDetector implementation from Maven2 plugin in our own plugin? As for now, I wasn't able to use autowire to get an instance of that class injected into constructor of my own plugin (even when I changed useSepearteClassLoader to false for maven2 plugin). Are such dependencies between plugins possible?


1 comment
Comment actions Permalink
Hi Grzegorz,
1. Maven Build Info is stored in a compressed XML file as a hidden build artifact under path <build_artifact_directory>/.teamcity/maven-build-info.N.xml.gz where N is a number or empty (one build may have multiple maven steps). See
Please be warned that this feature isn't a part of TeamCity Open API. So use it at your own risk.
2. If you mean class MavenArtifactChangeDetector I strongly don't recommend using it. Besides it's not in Open API and highly specific to the needs it's created for, it also holds a global state. Using it in places other than those specially indended for it will have negative side effects. Currently it's used solely for Maven artifact trigger.

Could you please describe what you want to achieve? Why Maven artifact trigger doesn't fit your needs?

Thank you

Please sign in to leave a comment.