Giter Club home page Giter Club logo

judge-d-contract-publisher-gradle-plugin's Introduction

judge-d-contract-publisher-gradle-plugin Build Status Gradle Plugin Portal

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

Usage

Add plugin to your project using plugins DSL:

plugins {
  id "com.hltech.judged.contracts.publisher" version "1.0.5"
}

or legacy plugin application:

buildscript {
  repositories {
    maven {
      url "https://plugins.gradle.org/m2/"
    }
  }
  dependencies {
    classpath "gradle.plugin.com.hltech:judge-d-contract-publisher-gradle-plugin:1.0.5"
  }
}

apply plugin: "com.hltech.judged.contracts.publisher"

and run publishContracts task:

./gradlew publishContracts 
  -PjudgeDLocation=https://judge-d-ui.herokuapp.com/ 
  -Pcapabilities=rest 
  -PswaggerLocation=./build/swagger/ 
  -Pexpectations=rest 
  -PpactsLocation=./build/pacts/

Parameters

  • judgeDLocation - url of judge-d instance to which you contracts will be uploaded (required)
  • expectations - list of comma separated values which determines expectations of you service against providers
  • capabilities - list of comma separated values which determines what capabalities your service expose

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:

  • pactsLocation - required for rest expectation, points to directory where pacts files are stored
  • 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:

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

Useful links

judge-d-contract-publisher-gradle-plugin's People

Contributors

matek2305 avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

judge-d-contract-publisher-gradle-plugin's Issues

Please correct relative path handling

Hello,

If provide a relative path to the swagger.json file, the log message is:

Found swagger file: C:\Users\myusername\.gradle\daemon\6.3\src\main\resources\swagger\swagger.json

Which is confusing to me.

Thanks,
Piotr

Please add option to override the service name

Hello,

I have a multi-module project, and I created a submodule that would take care of publishing contracts. Unfortunately, the plugin assumes the service name is the same as project name, so I ended up registering a service named contracts:1.36-SNAPSHOT.

Please add option to override the service name.

Thanks,
Piotr

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.