Shim for GoCD package repository poller plugin

A shim to help upgrade GoCD package repository poller plugins to work with GoCD 17.1 (if they use the old API-based extension point)

License

License

GroupId

GroupId

cd.go.plugin
ArtifactId

ArtifactId

gocd-package-material-plugin-shim
Last Version

Last Version

16.12.0
Release Date

Release Date

Type

Type

jar
Description

Description

Shim for GoCD package repository poller plugin
A shim to help upgrade GoCD package repository poller plugins to work with GoCD 17.1 (if they use the old API-based extension point)
Project URL

Project URL

https://www.go.cd/
Source Code Management

Source Code Management

https://github.com/gocd-contrib/gocd-package-material-plugin-shim/

Download gocd-package-material-plugin-shim

How to add to project

<!-- https://jarcasting.com/artifacts/cd.go.plugin/gocd-package-material-plugin-shim/ -->
<dependency>
    <groupId>cd.go.plugin</groupId>
    <artifactId>gocd-package-material-plugin-shim</artifactId>
    <version>16.12.0</version>
</dependency>
// https://jarcasting.com/artifacts/cd.go.plugin/gocd-package-material-plugin-shim/
implementation 'cd.go.plugin:gocd-package-material-plugin-shim:16.12.0'
// https://jarcasting.com/artifacts/cd.go.plugin/gocd-package-material-plugin-shim/
implementation ("cd.go.plugin:gocd-package-material-plugin-shim:16.12.0")
'cd.go.plugin:gocd-package-material-plugin-shim:jar:16.12.0'
<dependency org="cd.go.plugin" name="gocd-package-material-plugin-shim" rev="16.12.0">
  <artifact name="gocd-package-material-plugin-shim" type="jar" />
</dependency>
@Grapes(
@Grab(group='cd.go.plugin', module='gocd-package-material-plugin-shim', version='16.12.0')
)
libraryDependencies += "cd.go.plugin" % "gocd-package-material-plugin-shim" % "16.12.0"
[cd.go.plugin/gocd-package-material-plugin-shim "16.12.0"]

Dependencies

compile (2)

Group / Artifact Type Version
cd.go.plugin : go-plugin-api jar 16.11.0
com.google.code.gson : gson jar 2.3.1

Project Modules

There are no modules declared in this project.

GoCD package material plugin shim

GoCD 17.1 will deprecate the old-style API-based extension points. The new-style JSON-message-based extension points will be the only way forward. For the package repository material plugin, the new extension point is described here.

Instead of having to rewrite an existing plugin to use the new APIs immediately, this shim gives you a little time and makes the move easier. It brings over the deprecated classes of the old-style extension point and does the translation to and from the new APIs so that most of the existing code can be used as is.

How do I use this?

  1. Add a dependency to Google's GSON library (available at Maven Central).
  2. Add a dependency to this library (available at Maven Central).
  3. Remove the @Extension annotation from your plugin's main provider class.
  4. Copy over the class found in this file into your plugin and replace the text YourOriginalProviderWhichHadExtensionAnnotationOnIt with the class you removed the @Extension annotation from in step 3.

Examples

  1. Moving over the go-maven-poller.
  2. Moving over the go-puppet-forge-poller.
cd.go.plugin

gocd-contrib

The place for all code (plugins, cookbooks etc.) supporting GoCD that isn't part of the core app. These repos are not covered by the official GoCD support.

Versions

Version
16.12.0