judge-d-contract-publisher-maven-plugin

Maven plugin for contract publishing

License

License

Categories

Categories

Maven Build Tools
GroupId

GroupId

com.hltech
ArtifactId

ArtifactId

judge-d-contract-publisher-maven-plugin
Last Version

Last Version

0.3.2
Release Date

Release Date

Type

Type

maven-plugin
Description

Description

judge-d-contract-publisher-maven-plugin
Maven plugin for contract publishing
Project URL

Project URL

https://github.com/HLTech/judge-d-contract-publisher-maven-plugin
Source Code Management

Source Code Management

https://github.com/HLTech/judge-d-contract-publisher-maven-plugin.git

Download judge-d-contract-publisher-maven-plugin

How to add to project

<plugin>
    <groupId>com.hltech</groupId>
    <artifactId>judge-d-contract-publisher-maven-plugin</artifactId>
    <version>0.3.2</version>
</plugin>

Dependencies

compile (1)

Group / Artifact Type Version
com.hltech : judge-d-contract-publisher-core jar 0.1.6

provided (6)

Group / Artifact Type Version
org.apache.maven : maven-core jar 3.3.3
org.apache.maven : maven-model jar 3.3.3
org.apache.maven : maven-compat jar 3.3.3
org.apache.maven : maven-aether-provider jar 3.3.3
org.apache.maven : maven-plugin-api jar 3.3.3
org.apache.maven.plugin-tools : maven-plugin-annotations jar 3.4

test (6)

Group / Artifact Type Version
org.hamcrest : hamcrest jar 2.1
org.hamcrest : hamcrest-library jar 2.1
junit : junit jar 4.12
org.apache.maven.plugin-testing : maven-plugin-testing-harness jar 3.3.0
org.powermock : powermock-api-mockito2 jar 2.0.2
org.powermock : powermock-module-junit4 jar 2.0.2

Project Modules

There are no modules declared in this project.

judge-d-contract-publisher-maven-plugin Build Status Maven Central

Maven plugin to help integrate your project with judge-d in order to validate communication between microservices.

Usage

Add plugin to your pom.xml file:

<plugin>
    <groupId>com.hltech</groupId>
    <artifactId>judge-d-contract-publisher-maven-plugin</artifactId>
    <version>0.3.2</version>
</plugin>

If you have multi module maven app then you can add plugin to root pom.xml and set inherited to false:

<plugin>
    <groupId>com.hltech</groupId>
    <artifactId>judge-d-contract-publisher-maven-plugin</artifactId>
    <version>0.3.2</version>
    <inherited>false</inherited>
</plugin>

To publish contracts, run publish mojo:

./mvnw judge-d-contract-publisher:publish 
  -Dpublish.judgeDLocation=https://judge-d.tech.hl.uk
  -Dpublish.capabilities=rest
  -Dpublish.swaggerLocation=./build/swagger/
  -Dpublish.expectations=rest
  -Dpublish.pactsLocation=./build/pacts/

Parameters

  • publish.judgeDLocation - url of judge-d instance to which you contracts will be uploaded (required)
  • publish.expectations - list of comma separated values which determines expectations of you service against providers
  • publish.capabilities - list of comma separated values which determines what capabalities your service expose
  • publish.version - optional parameter to allow version override, by default value from pom.xml is used

Neither expectations nor capabilities are required for now but nothing will be published in such case

Expectations

Depending on what values you provide as expectations you also need to pass some additional parameters to make things work:

  • publish.pactsLocation - required for rest expectation, points to directory where pacts files are stored
  • publish.vauntLocation - required for jms expectation, points to directory where vaunt files are stored

Capabilities

Similar to expectations, you need to pass additional parameters for capabilities also:

  • publish.swaggerLocation - required for rest capability, points to directory where swagger specification is stored
  • publish.vauntLocation - required for jms capability, points to directory where vaunt files are stored

Useful links

com.hltech

HL Tech

Versions

Version
0.3.2
0.3.1
0.3.0
0.2.0
0.1.0