Added Stub Runner, fixes #64
This commit is contained in:
@@ -30,6 +30,7 @@
|
||||
<module>spring-cloud-launcher-h2</module>
|
||||
<module>spring-cloud-launcher-hystrixdashboard</module>
|
||||
<module>spring-cloud-launcher-kafka</module>
|
||||
<module>spring-cloud-launcher-stubrunner</module>
|
||||
<module>spring-cloud-launcher-zipkin</module>
|
||||
</modules>
|
||||
|
||||
|
||||
@@ -79,6 +79,16 @@ spring:
|
||||
spring.cloud.deployer.local.javaOpts: ${dt.opts}
|
||||
application-properties:
|
||||
management.security.enabled: false
|
||||
stubrunner:
|
||||
coordinates: ${dt.pre}stubrunner:${dt.ver}
|
||||
port: 8750
|
||||
message: To see the registered stubs open http://localhost:8750/stubs
|
||||
order: 0
|
||||
properties:
|
||||
spring.cloud.deployer.memory: ${dt.mem}
|
||||
spring.cloud.deployer.local.javaOpts: ${dt.opts}
|
||||
application-properties:
|
||||
management.security.enabled: false
|
||||
zipkin:
|
||||
coordinates: ${dt.pre}zipkin:${dt.ver}
|
||||
port: 9411
|
||||
@@ -121,6 +131,11 @@ spring:
|
||||
spring.cloud.deployer.thin.profile: rabbit
|
||||
application-properties:
|
||||
spring.cloud.bus.enabled: true
|
||||
stubrunner:
|
||||
properties:
|
||||
spring.cloud.deployer.thin.profile: rabbit
|
||||
application-properties:
|
||||
spring.cloud.bus.enabled: true
|
||||
zipkin:
|
||||
properties:
|
||||
spring.cloud.deployer.thin.profile: rabbit
|
||||
|
||||
@@ -0,0 +1,43 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<groupId>org.springframework.cloud.launcher</groupId>
|
||||
<artifactId>spring-cloud-launcher-stubrunner</artifactId>
|
||||
<packaging>jar</packaging>
|
||||
|
||||
<name>spring-cloud-launcher-stubrunner</name>
|
||||
<description>Spring Cloud Launcher Stub Runner</description>
|
||||
|
||||
<parent>
|
||||
<groupId>org.springframework.cloud</groupId>
|
||||
<artifactId>spring-cloud-launcher</artifactId>
|
||||
<version>1.4.0.BUILD-SNAPSHOT</version>
|
||||
</parent>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-actuator</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.cloud</groupId>
|
||||
<artifactId>spring-cloud-starter-contract-stub-runner</artifactId>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-starter-test</artifactId>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
<plugins>
|
||||
<plugin>
|
||||
<groupId>org.springframework.boot</groupId>
|
||||
<artifactId>spring-boot-maven-plugin</artifactId>
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
||||
@@ -0,0 +1,32 @@
|
||||
/*
|
||||
* Copyright 2013-2016 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
* You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing, software
|
||||
* distributed under the License is distributed on an "AS IS" BASIS,
|
||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
package org.springframework.cloud.launcher.stubrunner;
|
||||
|
||||
import org.springframework.boot.SpringApplication;
|
||||
import org.springframework.boot.autoconfigure.SpringBootApplication;
|
||||
import org.springframework.cloud.contract.stubrunner.server.EnableStubRunnerServer;
|
||||
|
||||
/**
|
||||
* @author Marcin Grzejszczak
|
||||
*/
|
||||
@EnableStubRunnerServer
|
||||
@SpringBootApplication
|
||||
public class StubRunnerApplication {
|
||||
public static void main(String[] args) {
|
||||
SpringApplication.run(StubRunnerApplication.class, args);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,2 @@
|
||||
exclusions.spring-cloud-starter-bus-kafka: org.springframework.cloud:spring-cloud-starter-bus-kafka
|
||||
dependencies.spring-cloud-starter-bus-amqp: org.springframework.cloud:spring-cloud-starter-bus-amqp
|
||||
@@ -0,0 +1,11 @@
|
||||
spring:
|
||||
application:
|
||||
name: stubrunner
|
||||
|
||||
server:
|
||||
port: 8750
|
||||
|
||||
info:
|
||||
artifactId: "@project.artifactId@"
|
||||
description: "@project.description@"
|
||||
version: "@project.version@"
|
||||
@@ -0,0 +1,30 @@
|
||||
info:
|
||||
description: Spring Cloud Launcher
|
||||
|
||||
eureka:
|
||||
client:
|
||||
instance-info-replication-interval-seconds: 5
|
||||
initial-instance-info-replication-interval-seconds: 5
|
||||
serviceUrl:
|
||||
defaultZone: http://localhost:8761/eureka/
|
||||
|
||||
endpoints:
|
||||
restart:
|
||||
enabled: true
|
||||
|
||||
ribbon:
|
||||
ConnectTimeout: 3000
|
||||
ReadTimeout: 60000
|
||||
|
||||
h2.datasource.url: jdbc:h2:tcp://localhost:9096/./target/test
|
||||
#spring:
|
||||
# datasource:
|
||||
# url: ${h2.datasource.url}
|
||||
|
||||
logging:
|
||||
level:
|
||||
kafka: WARN
|
||||
org.apache.zookeeper: WARN
|
||||
org.apache.zookeeper.ClientCnxn: ERROR
|
||||
org.apache.kafka: WARN
|
||||
org.I0Itec: WARN
|
||||
@@ -0,0 +1,17 @@
|
||||
package org.springframework.cloud.launcher.stubrunner;
|
||||
|
||||
import org.junit.Test;
|
||||
import org.junit.runner.RunWith;
|
||||
|
||||
import org.springframework.boot.test.context.SpringBootTest;
|
||||
import org.springframework.test.context.junit4.SpringRunner;
|
||||
|
||||
@RunWith(SpringRunner.class)
|
||||
@SpringBootTest
|
||||
public class DeployerApplicationTests {
|
||||
|
||||
@Test
|
||||
public void contextLoads() {
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user