Remove . from default classpath for cli launcher

Since "." is already on the search path for config files, it is
not obviously necessary to add "." to the classpath as well.
This commit is contained in:
Dave Syer
2016-10-06 10:44:59 +02:00
parent 2e0dda930d
commit 8587791549
3 changed files with 31 additions and 5 deletions

View File

@@ -69,6 +69,36 @@ spring:
uri: file://${user.home}/dev/demo/config-repo
----
=== Adding Additional Applications
Additional applications can be added to `./config/cloud.yml` (not
`./config.yml` because that would replace the defaults), e.g. with
.config/cloud.yml
[source,yaml]
----
spring:
cloud:
launcher:
deployables:
source:
coordinates: maven://com.example:source:0.0.1-SNAPSHOT
port: 7000
sink:
coordinates: maven://com.example:sink:0.0.1-SNAPSHOT
port: 7001
----
when you list the apps:
[source]
----
$ spring cloud --list
source sink configserver dataflow eureka h2 hystrixdashboard kafka zipkin
----
(notice the additional apps at the start of the list).
== Writing Groovy Scripts and Running Applications
Spring Cloud CLI has support for most of the Spring Cloud declarative

View File

@@ -166,11 +166,6 @@ public class LauncherCommand extends OptionParsingCommand {
repositoryConfiguration.add(0, new RepositoryConfiguration("local",
new File("repository").toURI(), true));
String[] classpaths = { "." };
for (String classpath : classpaths) {
loader.addClasspath(classpath);
}
if (options.has(debugOption)) {
System.setProperty("groovy.grape.report.downloads", "true");
}

View File

@@ -1,3 +1,4 @@
debug: true
spring:
cloud:
launcher: