Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Sign in / Register
Toggle navigation
S
spring-boot
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
DEMO
spring-boot
Commits
8ec00c35
Commit
8ec00c35
authored
Nov 21, 2015
by
Johnny Lim
Committed by
Stephane Nicoll
Nov 21, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Polish
Closes gh-4572
parent
31d7ebc9
Changes
40
Show whitespace changes
Inline
Side-by-side
Showing
40 changed files
with
70 additions
and
70 deletions
+70
-70
CONTRIBUTING.adoc
CONTRIBUTING.adoc
+2
-2
README.adoc
README.adoc
+1
-1
Log4J2RestartListener.java
...framework/boot/devtools/log4j2/Log4J2RestartListener.java
+2
-2
LocalDevToolsAutoConfigurationTests.java
...ls/autoconfigure/LocalDevToolsAutoConfigurationTests.java
+2
-2
ClassPathFileSystemWatcherTests.java
...t/devtools/classpath/ClassPathFileSystemWatcherTests.java
+2
-2
ClassLoaderFilesTests.java
...t/devtools/restart/classloader/ClassLoaderFilesTests.java
+1
-1
HttpTunnelConnectionTests.java
...oot/devtools/tunnel/client/HttpTunnelConnectionTests.java
+5
-5
HttpTunnelServerTests.java
...rk/boot/devtools/tunnel/server/HttpTunnelServerTests.java
+2
-2
StaticPortProviderTests.java
.../boot/devtools/tunnel/server/StaticPortProviderTests.java
+1
-1
deployment.adoc
spring-boot-docs/src/main/asciidoc/deployment.adoc
+1
-1
spring-boot-features.adoc
spring-boot-docs/src/main/asciidoc/spring-boot-features.adoc
+1
-1
using-spring-boot.adoc
spring-boot-docs/src/main/asciidoc/using-spring-boot.adoc
+3
-3
Versions.java
...c/test/java/org/springframework/boot/gradle/Versions.java
+2
-2
WarPackagingTests.java
...va/org/springframework/boot/gradle/WarPackagingTests.java
+2
-2
SampleActuatorUiApplication.java
.../java/sample/actuator/ui/SampleActuatorUiApplication.java
+1
-1
InsecureManagementSampleActuatorApplicationTests.java
...tor/InsecureManagementSampleActuatorApplicationTests.java
+2
-2
InsecureSampleActuatorApplicationTests.java
...mple/actuator/InsecureSampleActuatorApplicationTests.java
+2
-2
ServletPathInsecureSampleActuatorApplicationTests.java
...or/ServletPathInsecureSampleActuatorApplicationTests.java
+2
-2
CityRepository.java
...rc/main/java/sample/data/rest/service/CityRepository.java
+1
-1
SampleDataRestApplicationTests.java
...java/sample/data/rest/SampleDataRestApplicationTests.java
+1
-1
SampleSolrApplication.java
...src/main/java/sample/data/solr/SampleSolrApplication.java
+1
-1
README.adoc
...t-samples/spring-boot-sample-metrics-opentsdb/README.adoc
+1
-1
InMemoryMessageRepository.java
...ava/sample/groovytemplates/InMemoryMessageRepository.java
+1
-1
SampleGroovyTemplateApplication.java
...mple/groovytemplates/SampleGroovyTemplateApplication.java
+1
-1
ConfigurationMetadataRepositoryJsonBuilder.java
...nmetadata/ConfigurationMetadataRepositoryJsonBuilder.java
+4
-4
JsonMarshaller.java
.../boot/configurationprocessor/metadata/JsonMarshaller.java
+1
-1
ConfigurationMetadataAnnotationProcessorTests.java
...cessor/ConfigurationMetadataAnnotationProcessorTests.java
+1
-1
ConfigurationMetadataTests.java
...urationprocessor/metadata/ConfigurationMetadataTests.java
+2
-2
AgentTasksEnhancer.java
...springframework/boot/gradle/agent/AgentTasksEnhancer.java
+2
-2
AgentAttacher.java
.../org/springframework/boot/loader/tools/AgentAttacher.java
+2
-2
FileUtilsTests.java
...org/springframework/boot/loader/tools/FileUtilsTests.java
+1
-1
RandomAccessData.java
...rg/springframework/boot/loader/data/RandomAccessData.java
+1
-1
RandomAccessDataFile.java
...pringframework/boot/loader/data/RandomAccessDataFile.java
+1
-1
JarEntryData.java
...ava/org/springframework/boot/loader/jar/JarEntryData.java
+1
-1
RandomAccessDataFileTests.java
...framework/boot/loader/data/RandomAccessDataFileTests.java
+1
-1
AbstractRunMojo.java
.../java/org/springframework/boot/maven/AbstractRunMojo.java
+3
-3
exclude-dependency.apt.vm
...en-plugin/src/site/apt/examples/exclude-dependency.apt.vm
+1
-1
usage.apt.vm
...-tools/spring-boot-maven-plugin/src/site/apt/usage.apt.vm
+7
-7
SpringApplicationJsonEnvironmentPostProcessor.java
...ot/env/SpringApplicationJsonEnvironmentPostProcessor.java
+1
-1
LogbackLoggingSystemTests.java
...ework/boot/logging/logback/LogbackLoggingSystemTests.java
+1
-1
No files found.
CONTRIBUTING.adoc
View file @
8ec00c35
...
@@ -60,7 +60,7 @@ added after the original pull request but before a merge.
...
@@ -60,7 +60,7 @@ added after the original pull request but before a merge.
If you don't have an IDE preference we would recommend that you use
If you don't have an IDE preference we would recommend that you use
http://www.springsource.com/developer/sts[Spring Tools Suite] or
http://www.springsource.com/developer/sts[Spring Tools Suite] or
http://eclipse.org[Eclipse] when working with the code. We use the
http://eclipse.org[Eclipse] when working with the code. We use the
http://eclipse.org/m2e/[
m2eclip
e] eclipse plugin for maven support. Other IDEs and tools
http://eclipse.org/m2e/[
M2Eclips
e] eclipse plugin for maven support. Other IDEs and tools
should also work without issue.
should also work without issue.
...
@@ -168,7 +168,7 @@ easier to navigate.
...
@@ -168,7 +168,7 @@ easier to navigate.
==== Manual installation with m2eclipse
==== Manual installation with m2eclipse
If you prefer to install Eclipse yourself we recommend that you use the
If you prefer to install Eclipse yourself we recommend that you use the
http://eclipse.org/m2e/[
m2eclip
e] eclipse plugin. If you don't already have m2eclipse
http://eclipse.org/m2e/[
M2Eclips
e] eclipse plugin. If you don't already have m2eclipse
installed it is available from the "Eclipse marketplace".
installed it is available from the "Eclipse marketplace".
Spring Boot includes project specific source formatting settings, in order to have these
Spring Boot includes project specific source formatting settings, in order to have these
...
...
README.adoc
View file @
8ec00c35
...
@@ -72,7 +72,7 @@ Having trouble with Spring Boot? We'd like to help!
...
@@ -72,7 +72,7 @@ Having trouble with Spring Boot? We'd like to help!
== Reporting Issues
== Reporting Issues
Spring Boot uses GitHub's integrated issue tracking system to record bugs and feature
Spring Boot uses GitHub's integrated issue tracking system to record bugs and feature
requests. If you want to raise an issue, please follow the recommendations bel
l
ow:
requests. If you want to raise an issue, please follow the recommendations below:
* Before you log a bug, please https://github.com/spring-projects/spring-boot/search?type=Issues[search the issue tracker]
* Before you log a bug, please https://github.com/spring-projects/spring-boot/search?type=Issues[search the issue tracker]
to see if someone has already reported the problem.
to see if someone has already reported the problem.
...
...
spring-boot-devtools/src/main/java/org/springframework/boot/devtools/log4j2/Log4J2RestartListener.java
View file @
8ec00c35
...
@@ -55,9 +55,9 @@ public class Log4J2RestartListener implements RestartListener {
...
@@ -55,9 +55,9 @@ public class Log4J2RestartListener implements RestartListener {
"hooks"
);
"hooks"
);
ReflectionUtils
.
makeAccessible
(
hooksField
);
ReflectionUtils
.
makeAccessible
(
hooksField
);
@SuppressWarnings
(
"unchecked"
)
@SuppressWarnings
(
"unchecked"
)
Collection
<
Cancellable
>
state
=
(
Collection
<
Cancellable
>)
ReflectionUtils
Collection
<
Cancellable
>
hooks
=
(
Collection
<
Cancellable
>)
ReflectionUtils
.
getField
(
hooksField
,
shutdownCallbackRegistry
);
.
getField
(
hooksField
,
shutdownCallbackRegistry
);
state
.
clear
();
hooks
.
clear
();
}
}
}
}
spring-boot-devtools/src/test/java/org/springframework/boot/devtools/autoconfigure/LocalDevToolsAutoConfigurationTests.java
View file @
8ec00c35
...
@@ -139,7 +139,7 @@ public class LocalDevToolsAutoConfigurationTests {
...
@@ -139,7 +139,7 @@ public class LocalDevToolsAutoConfigurationTests {
}
}
@Test
@Test
public
void
liveReloadTriggerdOnClassPathChangeWithoutRestart
()
throws
Exception
{
public
void
liveReloadTrigger
e
dOnClassPathChangeWithoutRestart
()
throws
Exception
{
this
.
context
=
initializeAndRun
(
ConfigWithMockLiveReload
.
class
);
this
.
context
=
initializeAndRun
(
ConfigWithMockLiveReload
.
class
);
LiveReloadServer
server
=
this
.
context
.
getBean
(
LiveReloadServer
.
class
);
LiveReloadServer
server
=
this
.
context
.
getBean
(
LiveReloadServer
.
class
);
reset
(
server
);
reset
(
server
);
...
@@ -150,7 +150,7 @@ public class LocalDevToolsAutoConfigurationTests {
...
@@ -150,7 +150,7 @@ public class LocalDevToolsAutoConfigurationTests {
}
}
@Test
@Test
public
void
liveReloadNotTriggerdOnClassPathChangeWithRestart
()
throws
Exception
{
public
void
liveReloadNotTrigger
e
dOnClassPathChangeWithRestart
()
throws
Exception
{
this
.
context
=
initializeAndRun
(
ConfigWithMockLiveReload
.
class
);
this
.
context
=
initializeAndRun
(
ConfigWithMockLiveReload
.
class
);
LiveReloadServer
server
=
this
.
context
.
getBean
(
LiveReloadServer
.
class
);
LiveReloadServer
server
=
this
.
context
.
getBean
(
LiveReloadServer
.
class
);
reset
(
server
);
reset
(
server
);
...
...
spring-boot-devtools/src/test/java/org/springframework/boot/devtools/classpath/ClassPathFileSystemWatcherTests.java
View file @
8ec00c35
...
@@ -94,12 +94,12 @@ public class ClassPathFileSystemWatcherTests {
...
@@ -94,12 +94,12 @@ public class ClassPathFileSystemWatcherTests {
public
static
class
Config
{
public
static
class
Config
{
@Autowired
@Autowired
public
Environment
environ
em
nt
;
public
Environment
environ
me
nt
;
@Bean
@Bean
public
ClassPathFileSystemWatcher
watcher
()
{
public
ClassPathFileSystemWatcher
watcher
()
{
FileSystemWatcher
watcher
=
new
FileSystemWatcher
(
false
,
100
,
10
);
FileSystemWatcher
watcher
=
new
FileSystemWatcher
(
false
,
100
,
10
);
URL
[]
urls
=
this
.
environ
em
nt
.
getProperty
(
"urls"
,
URL
[].
class
);
URL
[]
urls
=
this
.
environ
me
nt
.
getProperty
(
"urls"
,
URL
[].
class
);
return
new
ClassPathFileSystemWatcher
(
return
new
ClassPathFileSystemWatcher
(
new
MockFileSystemWatcherFactory
(
watcher
),
restartStrategy
(),
urls
);
new
MockFileSystemWatcherFactory
(
watcher
),
restartStrategy
(),
urls
);
}
}
...
...
spring-boot-devtools/src/test/java/org/springframework/boot/devtools/restart/classloader/ClassLoaderFilesTests.java
View file @
8ec00c35
...
@@ -123,7 +123,7 @@ public class ClassLoaderFilesTests {
...
@@ -123,7 +123,7 @@ public class ClassLoaderFilesTests {
}
}
@Test
@Test
public
void
serial
zi
e
()
throws
Exception
{
public
void
serial
iz
e
()
throws
Exception
{
ClassLoaderFile
file
=
new
ClassLoaderFile
(
Kind
.
ADDED
,
new
byte
[
10
]);
ClassLoaderFile
file
=
new
ClassLoaderFile
(
Kind
.
ADDED
,
new
byte
[
10
]);
this
.
files
.
addFile
(
"myfile"
,
file
);
this
.
files
.
addFile
(
"myfile"
,
file
);
ByteArrayOutputStream
bos
=
new
ByteArrayOutputStream
();
ByteArrayOutputStream
bos
=
new
ByteArrayOutputStream
();
...
...
spring-boot-devtools/src/test/java/org/springframework/boot/devtools/tunnel/client/HttpTunnelConnectionTests.java
View file @
8ec00c35
...
@@ -58,7 +58,7 @@ public class HttpTunnelConnectionTests {
...
@@ -58,7 +58,7 @@ public class HttpTunnelConnectionTests {
private
String
url
;
private
String
url
;
private
ByteArrayOutputStream
incom
m
ingData
;
private
ByteArrayOutputStream
incomingData
;
private
WritableByteChannel
incomingChannel
;
private
WritableByteChannel
incomingChannel
;
...
@@ -71,8 +71,8 @@ public class HttpTunnelConnectionTests {
...
@@ -71,8 +71,8 @@ public class HttpTunnelConnectionTests {
public
void
setup
()
{
public
void
setup
()
{
MockitoAnnotations
.
initMocks
(
this
);
MockitoAnnotations
.
initMocks
(
this
);
this
.
url
=
"http://localhost:"
+
this
.
port
;
this
.
url
=
"http://localhost:"
+
this
.
port
;
this
.
incom
m
ingData
=
new
ByteArrayOutputStream
();
this
.
incomingData
=
new
ByteArrayOutputStream
();
this
.
incomingChannel
=
Channels
.
newChannel
(
this
.
incom
m
ingData
);
this
.
incomingChannel
=
Channels
.
newChannel
(
this
.
incomingData
);
}
}
@Test
@Test
...
@@ -129,7 +129,7 @@ public class HttpTunnelConnectionTests {
...
@@ -129,7 +129,7 @@ public class HttpTunnelConnectionTests {
write
(
channel
,
"hello"
);
write
(
channel
,
"hello"
);
write
(
channel
,
"1+1"
);
write
(
channel
,
"1+1"
);
write
(
channel
,
"1+2"
);
write
(
channel
,
"1+2"
);
assertThat
(
this
.
incom
m
ingData
.
toString
(),
equalTo
(
"hi=2=3"
));
assertThat
(
this
.
incomingData
.
toString
(),
equalTo
(
"hi=2=3"
));
}
}
@Test
@Test
...
@@ -140,7 +140,7 @@ public class HttpTunnelConnectionTests {
...
@@ -140,7 +140,7 @@ public class HttpTunnelConnectionTests {
this
.
requestFactory
.
willRespond
(
"hi"
);
this
.
requestFactory
.
willRespond
(
"hi"
);
TunnelChannel
channel
=
openTunnel
(
true
);
TunnelChannel
channel
=
openTunnel
(
true
);
write
(
channel
,
"hello"
);
write
(
channel
,
"hello"
);
assertThat
(
this
.
incom
m
ingData
.
toString
(),
equalTo
(
"hi"
));
assertThat
(
this
.
incomingData
.
toString
(),
equalTo
(
"hi"
));
assertThat
(
this
.
requestFactory
.
getExecutedRequests
().
size
(),
greaterThan
(
10
));
assertThat
(
this
.
requestFactory
.
getExecutedRequests
().
size
(),
greaterThan
(
10
));
}
}
...
...
spring-boot-devtools/src/test/java/org/springframework/boot/devtools/tunnel/server/HttpTunnelServerTests.java
View file @
8ec00c35
...
@@ -146,7 +146,7 @@ public class HttpTunnelServerTests {
...
@@ -146,7 +146,7 @@ public class HttpTunnelServerTests {
}
}
@Test
@Test
public
void
intialRequestIsUsedForFirstServerResponse
()
throws
Exception
{
public
void
in
i
tialRequestIsUsedForFirstServerResponse
()
throws
Exception
{
this
.
servletRequest
.
addHeader
(
SEQ_HEADER
,
"1"
);
this
.
servletRequest
.
addHeader
(
SEQ_HEADER
,
"1"
);
this
.
servletRequest
.
setContent
(
"hello"
.
getBytes
());
this
.
servletRequest
.
setContent
(
"hello"
.
getBytes
());
this
.
server
.
handle
(
this
.
request
,
this
.
response
);
this
.
server
.
handle
(
this
.
request
,
this
.
response
);
...
@@ -167,7 +167,7 @@ public class HttpTunnelServerTests {
...
@@ -167,7 +167,7 @@ public class HttpTunnelServerTests {
}
}
@Test
@Test
public
void
typicalReqestResponseTraffic
()
throws
Exception
{
public
void
typicalReq
u
estResponseTraffic
()
throws
Exception
{
MockHttpConnection
h1
=
new
MockHttpConnection
();
MockHttpConnection
h1
=
new
MockHttpConnection
();
this
.
server
.
handle
(
h1
);
this
.
server
.
handle
(
h1
);
MockHttpConnection
h2
=
new
MockHttpConnection
(
"hello server"
,
1
);
MockHttpConnection
h2
=
new
MockHttpConnection
(
"hello server"
,
1
);
...
...
spring-boot-devtools/src/test/java/org/springframework/boot/devtools/tunnel/server/StaticPortProviderTests.java
View file @
8ec00c35
...
@@ -34,7 +34,7 @@ public class StaticPortProviderTests {
...
@@ -34,7 +34,7 @@ public class StaticPortProviderTests {
public
ExpectedException
thrown
=
ExpectedException
.
none
();
public
ExpectedException
thrown
=
ExpectedException
.
none
();
@Test
@Test
public
void
portMustBePostive
()
throws
Exception
{
public
void
portMustBePos
i
tive
()
throws
Exception
{
this
.
thrown
.
expect
(
IllegalArgumentException
.
class
);
this
.
thrown
.
expect
(
IllegalArgumentException
.
class
);
this
.
thrown
.
expectMessage
(
"Port must be positive"
);
this
.
thrown
.
expectMessage
(
"Port must be positive"
);
new
StaticPortProvider
(
0
);
new
StaticPortProvider
(
0
);
...
...
spring-boot-docs/src/main/asciidoc/deployment.adoc
View file @
8ec00c35
...
@@ -572,7 +572,7 @@ Spring Boot application can be started as Windows service using
...
@@ -572,7 +572,7 @@ Spring Boot application can be started as Windows service using
https://github.com/kohsuke/winsw[`winsw`].
https://github.com/kohsuke/winsw[`winsw`].
A sample https://github.com/snicoll-scratches/spring-boot-daemon[maintained separately]
A sample https://github.com/snicoll-scratches/spring-boot-daemon[maintained separately]
to the core of Spring Boot describes step
s by steps
how you can create a Windows service for
to the core of Spring Boot describes step
by step
how you can create a Windows service for
your Spring Boot application.
your Spring Boot application.
...
...
spring-boot-docs/src/main/asciidoc/spring-boot-features.adoc
View file @
8ec00c35
spring-boot-docs/src/main/asciidoc/using-spring-boot.adoc
View file @
8ec00c35
...
@@ -913,7 +913,7 @@ dependencies out-of-the-box so you may want to have a look to the
...
@@ -913,7 +913,7 @@ dependencies out-of-the-box so you may want to have a look to the
{propdeps-plugin}[`propdeps-plugin`] in the meantime.
{propdeps-plugin}[`propdeps-plugin`] in the meantime.
TIP: If you want to ensure that devtools is never included in a production build, you can
TIP: If you want to ensure that devtools is never included in a production build, you can
use
set
the `excludeDevtools` build property to completely remove the JAR. The property is
use the `excludeDevtools` build property to completely remove the JAR. The property is
supported with both the Maven and Gradle plugins.
supported with both the Maven and Gradle plugins.
...
@@ -1058,7 +1058,7 @@ in the same way.
...
@@ -1058,7 +1058,7 @@ in the same way.
==== Customizing the restart classloader
==== Customizing the restart classloader
As described in the <<using-spring-boot-restart-vs-reload>> section above, restart
As described in the <<using-spring-boot-restart-vs-reload>> section above, restart
functionality is implemented by using two classloaders. For most applications this
functionality is implemented by using two classloaders. For most applications this
approach works well, however, sometimes i
n
can cause classloading issues.
approach works well, however, sometimes i
t
can cause classloading issues.
By default, any open project in your IDE will be loaded using the "`restart`" classloader,
By default, any open project in your IDE will be loaded using the "`restart`" classloader,
and any regular `.jar` file will be loaded using the "`base`" classloader. If you work on
and any regular `.jar` file will be loaded using the "`base`" classloader. If you work on
...
@@ -1067,7 +1067,7 @@ customize things. To do this you can create a `META-INF/spring-devtools.properti
...
@@ -1067,7 +1067,7 @@ customize things. To do this you can create a `META-INF/spring-devtools.properti
The `spring-devtools.properties` file can contain `restart.exclude.` and
The `spring-devtools.properties` file can contain `restart.exclude.` and
`restart.include.` prefixed properties. The `include` elements are items that should be
`restart.include.` prefixed properties. The `include` elements are items that should be
pulled
-
up into the "`restart`" classloader, and the `exclude` elements are items that
pulled
up into the "`restart`" classloader, and the `exclude` elements are items that
should be pushed down into the "`base`" classloader. The value of the property is a regex
should be pushed down into the "`base`" classloader. The value of the property is a regex
pattern that will be applied to the classpath.
pattern that will be applied to the classpath.
...
...
spring-boot-integration-tests/spring-boot-gradle-tests/src/test/java/org/springframework/boot/gradle/Versions.java
View file @
8ec00c35
...
@@ -51,8 +51,8 @@ public final class Versions {
...
@@ -51,8 +51,8 @@ public final class Versions {
private
static
String
evaluateExpression
(
String
expression
)
{
private
static
String
evaluateExpression
(
String
expression
)
{
try
{
try
{
XPathFactory
xPath
f
actory
=
XPathFactory
.
newInstance
();
XPathFactory
xPath
F
actory
=
XPathFactory
.
newInstance
();
XPath
xpath
=
xPath
f
actory
.
newXPath
();
XPath
xpath
=
xPath
F
actory
.
newXPath
();
XPathExpression
expr
=
xpath
.
compile
(
expression
);
XPathExpression
expr
=
xpath
.
compile
(
expression
);
String
version
=
expr
.
evaluate
(
String
version
=
expr
.
evaluate
(
new
InputSource
(
new
FileReader
(
"target/dependencies-pom.xml"
)));
new
InputSource
(
new
FileReader
(
"target/dependencies-pom.xml"
)));
...
...
spring-boot-integration-tests/spring-boot-gradle-tests/src/test/java/org/springframework/boot/gradle/WarPackagingTests.java
View file @
8ec00c35
...
@@ -72,13 +72,13 @@ public class WarPackagingTests {
...
@@ -72,13 +72,13 @@ public class WarPackagingTests {
}
}
@Test
@Test
public
void
onlyTomcatIsPacka
ck
edInWebInfLibProvided
()
throws
IOException
{
public
void
onlyTomcatIsPacka
g
edInWebInfLibProvided
()
throws
IOException
{
checkWebInfEntriesForServletContainer
(
"tomcat"
,
checkWebInfEntriesForServletContainer
(
"tomcat"
,
TOMCAT_EXPECTED_IN_WEB_INF_LIB_PROVIDED
);
TOMCAT_EXPECTED_IN_WEB_INF_LIB_PROVIDED
);
}
}
@Test
@Test
public
void
onlyJettyIsPacka
ck
edInWebInfLibProvided
()
throws
IOException
{
public
void
onlyJettyIsPacka
g
edInWebInfLibProvided
()
throws
IOException
{
checkWebInfEntriesForServletContainer
(
"jetty"
,
checkWebInfEntriesForServletContainer
(
"jetty"
,
JETTY_EXPECTED_IN_WEB_INF_LIB_PROVIDED
);
JETTY_EXPECTED_IN_WEB_INF_LIB_PROVIDED
);
}
}
...
...
spring-boot-samples/spring-boot-sample-actuator-ui/src/main/java/sample/actuator/ui/SampleActuatorUiApplication.java
View file @
8ec00c35
...
@@ -48,7 +48,7 @@ public class SampleActuatorUiApplication {
...
@@ -48,7 +48,7 @@ public class SampleActuatorUiApplication {
@Bean
@Bean
public
SecurityProperties
securityProperties
()
{
public
SecurityProperties
securityProperties
()
{
SecurityProperties
security
=
new
SecurityProperties
();
SecurityProperties
security
=
new
SecurityProperties
();
security
.
getBasic
().
setPath
(
""
);
// empty so home page is
u
nsecured
security
.
getBasic
().
setPath
(
""
);
// empty so home page is
i
nsecured
return
security
;
return
security
;
}
}
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/
U
nsecureManagementSampleActuatorApplicationTests.java
→
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/
I
nsecureManagementSampleActuatorApplicationTests.java
View file @
8ec00c35
...
@@ -36,7 +36,7 @@ import static org.junit.Assert.assertFalse;
...
@@ -36,7 +36,7 @@ import static org.junit.Assert.assertFalse;
import
static
org
.
junit
.
Assert
.
assertTrue
;
import
static
org
.
junit
.
Assert
.
assertTrue
;
/**
/**
* Integration tests for
u
nsecured service endpoints (even with Spring Security on
* Integration tests for
i
nsecured service endpoints (even with Spring Security on
* classpath).
* classpath).
*
*
* @author Dave Syer
* @author Dave Syer
...
@@ -46,7 +46,7 @@ import static org.junit.Assert.assertTrue;
...
@@ -46,7 +46,7 @@ import static org.junit.Assert.assertTrue;
@WebIntegrationTest
(
value
=
{
"management.security.enabled:false"
},
randomPort
=
true
)
@WebIntegrationTest
(
value
=
{
"management.security.enabled:false"
},
randomPort
=
true
)
@DirtiesContext
@DirtiesContext
@ActiveProfiles
(
"unsecure-management"
)
@ActiveProfiles
(
"unsecure-management"
)
public
class
U
nsecureManagementSampleActuatorApplicationTests
{
public
class
I
nsecureManagementSampleActuatorApplicationTests
{
@Value
(
"${local.server.port}"
)
@Value
(
"${local.server.port}"
)
private
int
port
;
private
int
port
;
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/
U
nsecureSampleActuatorApplicationTests.java
→
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/
I
nsecureSampleActuatorApplicationTests.java
View file @
8ec00c35
...
@@ -34,7 +34,7 @@ import static org.junit.Assert.assertEquals;
...
@@ -34,7 +34,7 @@ import static org.junit.Assert.assertEquals;
import
static
org
.
junit
.
Assert
.
assertFalse
;
import
static
org
.
junit
.
Assert
.
assertFalse
;
/**
/**
* Integration tests for
u
nsecured service endpoints (even with Spring Security on
* Integration tests for
i
nsecured service endpoints (even with Spring Security on
* classpath).
* classpath).
*
*
* @author Dave Syer
* @author Dave Syer
...
@@ -43,7 +43,7 @@ import static org.junit.Assert.assertFalse;
...
@@ -43,7 +43,7 @@ import static org.junit.Assert.assertFalse;
@SpringApplicationConfiguration
(
SampleActuatorApplication
.
class
)
@SpringApplicationConfiguration
(
SampleActuatorApplication
.
class
)
@WebIntegrationTest
(
value
=
{
"security.basic.enabled:false"
},
randomPort
=
true
)
@WebIntegrationTest
(
value
=
{
"security.basic.enabled:false"
},
randomPort
=
true
)
@DirtiesContext
@DirtiesContext
public
class
U
nsecureSampleActuatorApplicationTests
{
public
class
I
nsecureSampleActuatorApplicationTests
{
@Value
(
"${local.server.port}"
)
@Value
(
"${local.server.port}"
)
private
int
port
;
private
int
port
;
...
...
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/ServletPath
U
nsecureSampleActuatorApplicationTests.java
→
spring-boot-samples/spring-boot-sample-actuator/src/test/java/sample/actuator/ServletPath
I
nsecureSampleActuatorApplicationTests.java
View file @
8ec00c35
...
@@ -34,7 +34,7 @@ import static org.junit.Assert.assertEquals;
...
@@ -34,7 +34,7 @@ import static org.junit.Assert.assertEquals;
import
static
org
.
junit
.
Assert
.
assertFalse
;
import
static
org
.
junit
.
Assert
.
assertFalse
;
/**
/**
* Integration tests for
u
nsecured service endpoints (even with Spring Security on
* Integration tests for
i
nsecured service endpoints (even with Spring Security on
* classpath).
* classpath).
*
*
* @author Dave Syer
* @author Dave Syer
...
@@ -44,7 +44,7 @@ import static org.junit.Assert.assertFalse;
...
@@ -44,7 +44,7 @@ import static org.junit.Assert.assertFalse;
@WebIntegrationTest
(
value
=
{
"security.basic.enabled:false"
,
@WebIntegrationTest
(
value
=
{
"security.basic.enabled:false"
,
"server.servletPath:/spring"
},
randomPort
=
true
)
"server.servletPath:/spring"
},
randomPort
=
true
)
@DirtiesContext
@DirtiesContext
public
class
ServletPath
U
nsecureSampleActuatorApplicationTests
{
public
class
ServletPath
I
nsecureSampleActuatorApplicationTests
{
@Value
(
"${local.server.port}"
)
@Value
(
"${local.server.port}"
)
private
int
port
;
private
int
port
;
...
...
spring-boot-samples/spring-boot-sample-data-rest/src/main/java/sample/data/rest/service/CityRepository.java
View file @
8ec00c35
...
@@ -24,7 +24,7 @@ import org.springframework.data.repository.PagingAndSortingRepository;
...
@@ -24,7 +24,7 @@ import org.springframework.data.repository.PagingAndSortingRepository;
import
org.springframework.data.repository.query.Param
;
import
org.springframework.data.repository.query.Param
;
import
org.springframework.data.rest.core.annotation.RepositoryRestResource
;
import
org.springframework.data.rest.core.annotation.RepositoryRestResource
;
@RepositoryRestResource
(
collectionResourceRel
=
"cit
y
s"
,
path
=
"cities"
)
@RepositoryRestResource
(
collectionResourceRel
=
"cit
ie
s"
,
path
=
"cities"
)
interface
CityRepository
extends
PagingAndSortingRepository
<
City
,
Long
>
{
interface
CityRepository
extends
PagingAndSortingRepository
<
City
,
Long
>
{
Page
<
City
>
findByNameContainingAndCountryContainingAllIgnoringCase
(
Page
<
City
>
findByNameContainingAndCountryContainingAllIgnoringCase
(
...
...
spring-boot-samples/spring-boot-sample-data-rest/src/test/java/sample/data/rest/SampleDataRestApplicationTests.java
View file @
8ec00c35
...
@@ -83,6 +83,6 @@ public class SampleDataRestApplicationTests {
...
@@ -83,6 +83,6 @@ public class SampleDataRestApplicationTests {
this
.
mvc
.
perform
(
this
.
mvc
.
perform
(
get
(
"/api/cities/search/findByNameContainingAndCountryContainingAllIgnoringCase?name=&country=UK"
))
get
(
"/api/cities/search/findByNameContainingAndCountryContainingAllIgnoringCase?name=&country=UK"
))
.
andExpect
(
status
().
isOk
())
.
andExpect
(
status
().
isOk
())
.
andExpect
(
jsonPath
(
"_embedded.cit
y
s"
,
hasSize
(
3
)));
.
andExpect
(
jsonPath
(
"_embedded.cit
ie
s"
,
hasSize
(
3
)));
}
}
}
}
spring-boot-samples/spring-boot-sample-data-solr/src/main/java/sample/data/solr/SampleSolrApplication.java
View file @
8ec00c35
...
@@ -46,7 +46,7 @@ public class SampleSolrApplication implements CommandLineRunner {
...
@@ -46,7 +46,7 @@ public class SampleSolrApplication implements CommandLineRunner {
System
.
out
.
println
();
System
.
out
.
println
();
// fetch a single product
// fetch a single product
System
.
out
.
println
(
"Products found
s
with findByNameStartingWith('So'):"
);
System
.
out
.
println
(
"Products found with findByNameStartingWith('So'):"
);
System
.
out
.
println
(
"--------------------------------"
);
System
.
out
.
println
(
"--------------------------------"
);
for
(
Product
product
:
this
.
repository
.
findByNameStartingWith
(
"So"
))
{
for
(
Product
product
:
this
.
repository
.
findByNameStartingWith
(
"So"
))
{
System
.
out
.
println
(
product
);
System
.
out
.
println
(
product
);
...
...
spring-boot-samples/spring-boot-sample-metrics-opentsdb/README.adoc
View file @
8ec00c35
...
@@ -8,7 +8,7 @@ $ docker-compose up
...
@@ -8,7 +8,7 @@ $ docker-compose up
----
----
Run the app and ping the home page (http://localhost:8080) a few times. Go and look at
Run the app and ping the home page (http://localhost:8080) a few times. Go and look at
the result in the T
DB
UI, e.g.
the result in the T
SD
UI, e.g.
[source,indent=0]
[source,indent=0]
----
----
...
...
spring-boot-samples/spring-boot-sample-web-groovy-templates/src/main/java/sample/groovytemplates/InMemoryMessageRe
s
pository.java
→
spring-boot-samples/spring-boot-sample-web-groovy-templates/src/main/java/sample/groovytemplates/InMemoryMessageRepository.java
View file @
8ec00c35
...
@@ -20,7 +20,7 @@ import java.util.concurrent.ConcurrentHashMap;
...
@@ -20,7 +20,7 @@ import java.util.concurrent.ConcurrentHashMap;
import
java.util.concurrent.ConcurrentMap
;
import
java.util.concurrent.ConcurrentMap
;
import
java.util.concurrent.atomic.AtomicLong
;
import
java.util.concurrent.atomic.AtomicLong
;
public
class
InMemoryMessageRe
s
pository
implements
MessageRepository
{
public
class
InMemoryMessageRepository
implements
MessageRepository
{
private
static
AtomicLong
counter
=
new
AtomicLong
();
private
static
AtomicLong
counter
=
new
AtomicLong
();
...
...
spring-boot-samples/spring-boot-sample-web-groovy-templates/src/main/java/sample/groovytemplates/SampleGroovyTemplateApplication.java
View file @
8ec00c35
...
@@ -26,7 +26,7 @@ public class SampleGroovyTemplateApplication {
...
@@ -26,7 +26,7 @@ public class SampleGroovyTemplateApplication {
@Bean
@Bean
public
MessageRepository
messageRepository
()
{
public
MessageRepository
messageRepository
()
{
return
new
InMemoryMessageRe
s
pository
();
return
new
InMemoryMessageRepository
();
}
}
@Bean
@Bean
...
...
spring-boot-tools/spring-boot-configuration-metadata/src/main/java/org/springframework/boot/configurationmetadata/ConfigurationMetadataRepositoryJsonBuilder.java
View file @
8ec00c35
...
@@ -71,17 +71,17 @@ public final class ConfigurationMetadataRepositoryJsonBuilder {
...
@@ -71,17 +71,17 @@ public final class ConfigurationMetadataRepositoryJsonBuilder {
* ignored.
* ignored.
* <p>
* <p>
* Leaves the stream open when done.
* Leaves the stream open when done.
* @param input
s
tream the source input stream
* @param input
S
tream the source input stream
* @param charset the charset of the input
* @param charset the charset of the input
* @return this builder
* @return this builder
* @throws IOException in case of I/O errors
* @throws IOException in case of I/O errors
*/
*/
public
ConfigurationMetadataRepositoryJsonBuilder
withJsonResource
(
public
ConfigurationMetadataRepositoryJsonBuilder
withJsonResource
(
InputStream
input
s
tream
,
Charset
charset
)
throws
IOException
{
InputStream
input
S
tream
,
Charset
charset
)
throws
IOException
{
if
(
input
s
tream
==
null
)
{
if
(
input
S
tream
==
null
)
{
throw
new
IllegalArgumentException
(
"InputStream must not be null."
);
throw
new
IllegalArgumentException
(
"InputStream must not be null."
);
}
}
this
.
repositories
.
add
(
add
(
input
s
tream
,
charset
));
this
.
repositories
.
add
(
add
(
input
S
tream
,
charset
));
return
this
;
return
this
;
}
}
...
...
spring-boot-tools/spring-boot-configuration-processor/src/main/java/org/springframework/boot/configurationprocessor/metadata/JsonMarshaller.java
View file @
8ec00c35
...
@@ -89,7 +89,7 @@ public class JsonMarshaller {
...
@@ -89,7 +89,7 @@ public class JsonMarshaller {
}
}
ItemDeprecation
deprecation
=
item
.
getDeprecation
();
ItemDeprecation
deprecation
=
item
.
getDeprecation
();
if
(
deprecation
!=
null
)
{
if
(
deprecation
!=
null
)
{
jsonObject
.
put
(
"deprecated"
,
true
);
// backward compat
jsonObject
.
put
(
"deprecated"
,
true
);
// backward compat
ibility
JSONObject
deprecationJsonObject
=
new
JSONObject
();
JSONObject
deprecationJsonObject
=
new
JSONObject
();
if
(
deprecation
.
getReason
()
!=
null
)
{
if
(
deprecation
.
getReason
()
!=
null
)
{
deprecationJsonObject
.
put
(
"reason"
,
deprecation
.
getReason
());
deprecationJsonObject
.
put
(
"reason"
,
deprecation
.
getReason
());
...
...
spring-boot-tools/spring-boot-configuration-processor/src/test/java/org/springframework/boot/configurationprocessor/ConfigurationMetadataAnnotationProcessorTests.java
View file @
8ec00c35
...
@@ -188,7 +188,7 @@ public class ConfigurationMetadataAnnotationProcessorTests {
...
@@ -188,7 +188,7 @@ public class ConfigurationMetadataAnnotationProcessorTests {
}
}
@Test
@Test
public
void
singleDeprecatedProp
re
ty
()
throws
Exception
{
public
void
singleDeprecatedProp
er
ty
()
throws
Exception
{
Class
<?>
type
=
DeprecatedSingleProperty
.
class
;
Class
<?>
type
=
DeprecatedSingleProperty
.
class
;
ConfigurationMetadata
metadata
=
compile
(
type
);
ConfigurationMetadata
metadata
=
compile
(
type
);
assertThat
(
metadata
,
containsGroup
(
"singledeprecated"
).
fromSource
(
type
));
assertThat
(
metadata
,
containsGroup
(
"singledeprecated"
).
fromSource
(
type
));
...
...
spring-boot-tools/spring-boot-configuration-processor/src/test/java/org/springframework/boot/configurationprocessor/metadata/ConfigurationMetadataTests.java
View file @
8ec00c35
...
@@ -34,12 +34,12 @@ public class ConfigurationMetadataTests {
...
@@ -34,12 +34,12 @@ public class ConfigurationMetadataTests {
}
}
@Test
@Test
public
void
toDashedCaseWordsUnder
S
core
()
{
public
void
toDashedCaseWordsUnder
s
core
()
{
assertThat
(
toDashedCase
(
"Word_With_underscore"
),
is
(
"word_with_underscore"
));
assertThat
(
toDashedCase
(
"Word_With_underscore"
),
is
(
"word_with_underscore"
));
}
}
@Test
@Test
public
void
toDashedCaseWordsSeveralUnder
S
cores
()
{
public
void
toDashedCaseWordsSeveralUnder
s
cores
()
{
assertThat
(
toDashedCase
(
"Word___With__underscore"
),
assertThat
(
toDashedCase
(
"Word___With__underscore"
),
is
(
"word___with__underscore"
));
is
(
"word___with__underscore"
));
}
}
...
...
spring-boot-tools/spring-boot-gradle-plugin/src/main/java/org/springframework/boot/gradle/agent/AgentTasksEnhancer.java
View file @
8ec00c35
...
@@ -43,7 +43,7 @@ import org.springframework.boot.gradle.SpringBootPluginExtension;
...
@@ -43,7 +43,7 @@ import org.springframework.boot.gradle.SpringBootPluginExtension;
*/
*/
public
class
AgentTasksEnhancer
implements
Action
<
Project
>
{
public
class
AgentTasksEnhancer
implements
Action
<
Project
>
{
private
static
final
String
SPRING_LOADED_AGENT_CLASSNAME
=
"org.springsource.loaded.agent.SpringLoadedAgent"
;
private
static
final
String
SPRING_LOADED_AGENT_CLASS
_
NAME
=
"org.springsource.loaded.agent.SpringLoadedAgent"
;
private
File
agent
;
private
File
agent
;
...
@@ -83,7 +83,7 @@ public class AgentTasksEnhancer implements Action<Project> {
...
@@ -83,7 +83,7 @@ public class AgentTasksEnhancer implements Action<Project> {
private
File
getSpringLoadedAgent
()
{
private
File
getSpringLoadedAgent
()
{
try
{
try
{
Class
<?>
loaded
=
Class
.
forName
(
SPRING_LOADED_AGENT_CLASSNAME
);
Class
<?>
loaded
=
Class
.
forName
(
SPRING_LOADED_AGENT_CLASS
_
NAME
);
if
(
loaded
!=
null
)
{
if
(
loaded
!=
null
)
{
CodeSource
source
=
loaded
.
getProtectionDomain
().
getCodeSource
();
CodeSource
source
=
loaded
.
getProtectionDomain
().
getCodeSource
();
if
(
source
!=
null
)
{
if
(
source
!=
null
)
{
...
...
spring-boot-tools/spring-boot-loader-tools/src/main/java/org/springframework/boot/loader/tools/AgentAttacher.java
View file @
8ec00c35
...
@@ -28,14 +28,14 @@ import java.util.List;
...
@@ -28,14 +28,14 @@ import java.util.List;
*/
*/
public
abstract
class
AgentAttacher
{
public
abstract
class
AgentAttacher
{
private
static
final
String
VIRTUAL_MACHINE_CLASSNAME
=
"com.sun.tools.attach.VirtualMachine"
;
private
static
final
String
VIRTUAL_MACHINE_CLASS
_
NAME
=
"com.sun.tools.attach.VirtualMachine"
;
public
static
void
attach
(
File
agent
)
{
public
static
void
attach
(
File
agent
)
{
try
{
try
{
String
name
=
ManagementFactory
.
getRuntimeMXBean
().
getName
();
String
name
=
ManagementFactory
.
getRuntimeMXBean
().
getName
();
String
pid
=
name
.
substring
(
0
,
name
.
indexOf
(
'@'
));
String
pid
=
name
.
substring
(
0
,
name
.
indexOf
(
'@'
));
ClassLoader
classLoader
=
JvmUtils
.
getToolsClassLoader
();
ClassLoader
classLoader
=
JvmUtils
.
getToolsClassLoader
();
Class
<?>
vmClass
=
classLoader
.
loadClass
(
VIRTUAL_MACHINE_CLASSNAME
);
Class
<?>
vmClass
=
classLoader
.
loadClass
(
VIRTUAL_MACHINE_CLASS
_
NAME
);
Method
attachMethod
=
vmClass
.
getDeclaredMethod
(
"attach"
,
String
.
class
);
Method
attachMethod
=
vmClass
.
getDeclaredMethod
(
"attach"
,
String
.
class
);
Object
vm
=
attachMethod
.
invoke
(
null
,
pid
);
Object
vm
=
attachMethod
.
invoke
(
null
,
pid
);
Method
loadAgentMethod
=
vmClass
.
getDeclaredMethod
(
"loadAgent"
,
String
.
class
);
Method
loadAgentMethod
=
vmClass
.
getDeclaredMethod
(
"loadAgent"
,
String
.
class
);
...
...
spring-boot-tools/spring-boot-loader-tools/src/test/java/org/springframework/boot/loader/tools/FileUtilsTests.java
View file @
8ec00c35
...
@@ -34,7 +34,7 @@ import static org.junit.Assert.assertThat;
...
@@ -34,7 +34,7 @@ import static org.junit.Assert.assertThat;
import
static
org
.
junit
.
Assert
.
assertTrue
;
import
static
org
.
junit
.
Assert
.
assertTrue
;
/**
/**
* Tests f
i
r {@link FileUtils}.
* Tests f
o
r {@link FileUtils}.
*
*
* @author Dave Syer
* @author Dave Syer
* @author Phillip Webb
* @author Phillip Webb
...
...
spring-boot-tools/spring-boot-loader/src/main/java/org/springframework/boot/loader/data/RandomAccessData.java
View file @
8ec00c35
...
@@ -28,7 +28,7 @@ import java.io.InputStream;
...
@@ -28,7 +28,7 @@ import java.io.InputStream;
public
interface
RandomAccessData
{
public
interface
RandomAccessData
{
/**
/**
* Returns an {@link InputStream} that can be used to read the underling data. The
* Returns an {@link InputStream} that can be used to read the underl
y
ing data. The
* caller is responsible close the underlying stream.
* caller is responsible close the underlying stream.
* @param access hint indicating how the underlying data should be accessed
* @param access hint indicating how the underlying data should be accessed
* @return a new input stream that can be used to read the underlying data.
* @return a new input stream that can be used to read the underlying data.
...
...
spring-boot-tools/spring-boot-loader/src/main/java/org/springframework/boot/loader/data/RandomAccessDataFile.java
View file @
8ec00c35
...
@@ -87,7 +87,7 @@ public class RandomAccessDataFile implements RandomAccessData {
...
@@ -87,7 +87,7 @@ public class RandomAccessDataFile implements RandomAccessData {
}
}
/**
/**
* Returns the underling File.
* Returns the underl
y
ing File.
* @return the underlying file
* @return the underlying file
*/
*/
public
File
getFile
()
{
public
File
getFile
()
{
...
...
spring-boot-tools/spring-boot-loader/src/main/java/org/springframework/boot/loader/jar/JarEntryData.java
View file @
8ec00c35
...
@@ -155,7 +155,7 @@ public final class JarEntryData {
...
@@ -155,7 +155,7 @@ public final class JarEntryData {
}
}
/**
/**
* Decode MSDOS Date Time details. See
* Decode MS
-
DOS Date Time details. See
* <a href="http://mindprod.com/jgloss/zip.html">mindprod.com/jgloss/zip.html</a> for
* <a href="http://mindprod.com/jgloss/zip.html">mindprod.com/jgloss/zip.html</a> for
* more details of the format.
* more details of the format.
* @param date the date part
* @param date the date part
...
...
spring-boot-tools/spring-boot-loader/src/test/java/org/springframework/boot/loader/data/RandomAccessDataFileTests.java
View file @
8ec00c35
...
@@ -145,7 +145,7 @@ public class RandomAccessDataFileTests {
...
@@ -145,7 +145,7 @@ public class RandomAccessDataFileTests {
}
}
@Test
@Test
public
void
inputSteamReadOffsetBytes
()
throws
Exception
{
public
void
inputSt
r
eamReadOffsetBytes
()
throws
Exception
{
byte
[]
b
=
new
byte
[
7
];
byte
[]
b
=
new
byte
[
7
];
this
.
inputStream
.
skip
(
1
);
this
.
inputStream
.
skip
(
1
);
int
amountRead
=
this
.
inputStream
.
read
(
b
,
2
,
3
);
int
amountRead
=
this
.
inputStream
.
read
(
b
,
2
,
3
);
...
...
spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/AbstractRunMojo.java
View file @
8ec00c35
...
@@ -52,7 +52,7 @@ import org.springframework.boot.loader.tools.MainClassFinder;
...
@@ -52,7 +52,7 @@ import org.springframework.boot.loader.tools.MainClassFinder;
*/
*/
public
abstract
class
AbstractRunMojo
extends
AbstractDependencyFilterMojo
{
public
abstract
class
AbstractRunMojo
extends
AbstractDependencyFilterMojo
{
private
static
final
String
SPRING_LOADED_AGENT_CLASSNAME
=
"org.springsource.loaded.agent.SpringLoadedAgent"
;
private
static
final
String
SPRING_LOADED_AGENT_CLASS
_
NAME
=
"org.springsource.loaded.agent.SpringLoadedAgent"
;
/**
/**
* The Maven project.
* The Maven project.
...
@@ -177,7 +177,7 @@ public abstract class AbstractRunMojo extends AbstractDependencyFilterMojo {
...
@@ -177,7 +177,7 @@ public abstract class AbstractRunMojo extends AbstractDependencyFilterMojo {
private
void
findAgent
()
{
private
void
findAgent
()
{
try
{
try
{
if
(
this
.
agent
==
null
||
this
.
agent
.
length
==
0
)
{
if
(
this
.
agent
==
null
||
this
.
agent
.
length
==
0
)
{
Class
<?>
loaded
=
Class
.
forName
(
SPRING_LOADED_AGENT_CLASSNAME
);
Class
<?>
loaded
=
Class
.
forName
(
SPRING_LOADED_AGENT_CLASS
_
NAME
);
if
(
loaded
!=
null
)
{
if
(
loaded
!=
null
)
{
if
(
this
.
noverify
==
null
)
{
if
(
this
.
noverify
==
null
)
{
this
.
noverify
=
true
;
this
.
noverify
=
true
;
...
@@ -434,7 +434,7 @@ public abstract class AbstractRunMojo extends AbstractDependencyFilterMojo {
...
@@ -434,7 +434,7 @@ public abstract class AbstractRunMojo extends AbstractDependencyFilterMojo {
public
synchronized
void
rethrowUncaughtException
()
public
synchronized
void
rethrowUncaughtException
()
throws
MojoExecutionException
{
throws
MojoExecutionException
{
if
(
this
.
exception
!=
null
)
{
if
(
this
.
exception
!=
null
)
{
throw
new
MojoExecutionException
(
"An exception occured while running. "
throw
new
MojoExecutionException
(
"An exception occur
r
ed while running. "
+
this
.
exception
.
getMessage
(),
this
.
exception
);
+
this
.
exception
.
getMessage
(),
this
.
exception
);
}
}
}
}
...
...
spring-boot-tools/spring-boot-maven-plugin/src/site/apt/examples/exclude-dependency.apt.vm
View file @
8ec00c35
...
@@ -18,7 +18,7 @@
...
@@ -18,7 +18,7 @@
There are tree ways one can exclude a dependency from being packaged/used at runtime
There are tree ways one can exclude a dependency from being packaged/used at runtime
* Exclude a specific artifact identified by <<<groupId>>> and <<<artifactId>>>
* Exclude a specific artifact identified by <<<groupId>>> and <<<artifactId>>>
(option
na
ly with a <<<classifier>>> if needed)
(option
al
ly with a <<<classifier>>> if needed)
* Exclude any artifact matching a given <<<artifactId>>>
* Exclude any artifact matching a given <<<artifactId>>>
...
...
spring-boot-tools/spring-boot-maven-plugin/src/site/apt/usage.apt.vm
View file @
8ec00c35
...
@@ -12,7 +12,7 @@ Usage
...
@@ -12,7 +12,7 @@ Usage
The plugin provides several goals to work with a Spring Boot application:
The plugin provides several goals to work with a Spring Boot application:
* <<<repackage>>>: create a jar or war file that is auto-executable. It can replace the regular artifact or can be
* <<<repackage>>>: create a jar or war file that is auto-executable. It can replace the regular artifact or can be
attached to the build lifecyle with a separate <<classifier>>.
attached to the build lifecy
c
le with a separate <<classifier>>.
* <<<run>>>: run your Spring Boot application with several options to pass parameters to it.
* <<<run>>>: run your Spring Boot application with several options to pass parameters to it.
...
@@ -56,7 +56,7 @@ Usage
...
@@ -56,7 +56,7 @@ Usage
need to be excluded, you can use one of the exclude options,
need to be excluded, you can use one of the exclude options,
see {{{./examples/exclude-dependency.html}Exclude a dependency}} for more details.
see {{{./examples/exclude-dependency.html}Exclude a dependency}} for more details.
The original (i.e. non exec
tu
able) artifact is renamed to <<<.original>>> by default but it is also
The original (i.e. non exec
ut
able) artifact is renamed to <<<.original>>> by default but it is also
possible to keep the original artifact using a custom classifier.
possible to keep the original artifact using a custom classifier.
The plugin rewrites your manifest, and in particular it manages the <<Main-Class>> and <<Start-Class>>
The plugin rewrites your manifest, and in particular it manages the <<Main-Class>> and <<Start-Class>>
...
@@ -116,7 +116,7 @@ mvn spring-boot:run
...
@@ -116,7 +116,7 @@ mvn spring-boot:run
If you need to specify some JVM arguments (i.e. for debugging purposes), you can use
If you need to specify some JVM arguments (i.e. for debugging purposes), you can use
the <<<jvmArguments>>> parameter, see {{{./examples/run-debug.html}Debug the application}}
the <<<jvmArguments>>> parameter, see {{{./examples/run-debug.html}Debug the application}}
for more details. As a convenience, the
profiles to enable are hand
ed by a specific
for more details. As a convenience, the
profiles to enable are handl
ed by a specific
property (<<<profiles>>>), see {{{./examples/run-profiles.html}Specify active profiles}}.
property (<<<profiles>>>), see {{{./examples/run-profiles.html}Specify active profiles}}.
Spring Boot 1.3 has introduced <<<devtools>>>, a module to improve the development-time
Spring Boot 1.3 has introduced <<<devtools>>>, a module to improve the development-time
...
@@ -135,7 +135,7 @@ mvn spring-boot:run
...
@@ -135,7 +135,7 @@ mvn spring-boot:run
---
---
When <<<devtools>>> is running, it detects change when you recompile your application and
When <<<devtools>>> is running, it detects change when you recompile your application and
automatically refreshes it. This
not only work for
resources but code as well. It also
automatically refreshes it. This
works for not only
resources but code as well. It also
provides a LiveReload server so that it can automatically trigger a browser refresh whenever
provides a LiveReload server so that it can automatically trigger a browser refresh whenever
things change.
things change.
...
@@ -148,7 +148,7 @@ spring.devtools.remote.restart.enabled=false
...
@@ -148,7 +148,7 @@ spring.devtools.remote.restart.enabled=false
---
---
Prior to <<<devtools>>>, the plugin supported hot refreshing of resources by default which has
Prior to <<<devtools>>>, the plugin supported hot refreshing of resources by default which has
now be disabled in favor of the solution desribed above. You can restore it at any time by
now be disabled in favor of the solution des
c
ribed above. You can restore it at any time by
configuring your project:
configuring your project:
---
---
...
@@ -173,7 +173,7 @@ spring.devtools.remote.restart.enabled=false
...
@@ -173,7 +173,7 @@ spring.devtools.remote.restart.enabled=false
When <<<addResources>>> is enabled, any <<src/main/resources>> folder will be added to
When <<<addResources>>> is enabled, any <<src/main/resources>> folder will be added to
the application classpath when you run the application and any duplicate found in
the application classpath when you run the application and any duplicate found in
<<target/classes>> will be removed. This allows hot refreshing of resources which can be very
<<target/classes>> will be removed. This allows hot refreshing of resources which can be very
useful when developing web applications. For example, you can work on HTML, CSS or JavaScipt
useful when developing web applications. For example, you can work on HTML, CSS or JavaSc
r
ipt
files and see your changes immediately without recompiling your application. It is also a helpful
files and see your changes immediately without recompiling your application. It is also a helpful
way of allowing your front end developers to work without needing to download and install a Java
way of allowing your front end developers to work without needing to download and install a Java
IDE.
IDE.
...
@@ -196,7 +196,7 @@ spring.devtools.remote.restart.enabled=false
...
@@ -196,7 +196,7 @@ spring.devtools.remote.restart.enabled=false
While you may start your Spring Boot application very easily from your test (or test suite) itself,
While you may start your Spring Boot application very easily from your test (or test suite) itself,
it may be desirable to handle that in the build itself. To make sure that the lifecycle of you Spring
it may be desirable to handle that in the build itself. To make sure that the lifecycle of you Spring
Boot application is properly managed <around> your integration tests, you can use the <<<start>>> and
Boot application is properly managed <around> your integration tests, you can use the <<<start>>> and
<<<stop>>> goals as desribed below:
<<<stop>>> goals as des
c
ribed below:
---
---
<build>
<build>
...
...
spring-boot/src/main/java/org/springframework/boot/env/SpringApplicationJsonEnvironmentPostProcessor.java
View file @
8ec00c35
...
@@ -40,7 +40,7 @@ import org.springframework.web.context.support.StandardServletEnvironment;
...
@@ -40,7 +40,7 @@ import org.springframework.web.context.support.StandardServletEnvironment;
/**
/**
* An {@link EnvironmentPostProcessor} that parses JSON from
* An {@link EnvironmentPostProcessor} that parses JSON from
* {@code spring.application.json} or equivalently
* {@code spring.application.json} or equivalently
* {@
link SpringApplicationJsonEnvironmentPostProcessor
} and adds it as a map property
* {@
code SPRING_APPLICATION_JSON
} and adds it as a map property
* source to the {@link Environment}. The new properties are added with higher priority
* source to the {@link Environment}. The new properties are added with higher priority
* than the system properties.
* than the system properties.
*
*
...
...
spring-boot/src/test/java/org/springframework/boot/logging/logback/LogbackLoggingSystemTests.java
View file @
8ec00c35
...
@@ -186,7 +186,7 @@ public class LogbackLoggingSystemTests extends AbstractLoggingSystemTests {
...
@@ -186,7 +186,7 @@ public class LogbackLoggingSystemTests extends AbstractLoggingSystemTests {
}
}
@Test
@Test
public
void
loggingLevelIsPropagatedToJul
I
()
{
public
void
loggingLevelIsPropagatedToJul
()
{
this
.
loggingSystem
.
beforeInitialize
();
this
.
loggingSystem
.
beforeInitialize
();
this
.
loggingSystem
.
initialize
(
this
.
initializationContext
,
null
,
null
);
this
.
loggingSystem
.
initialize
(
this
.
initializationContext
,
null
,
null
);
this
.
loggingSystem
.
setLogLevel
(
getClass
().
getName
(),
LogLevel
.
DEBUG
);
this
.
loggingSystem
.
setLogLevel
(
getClass
().
getName
(),
LogLevel
.
DEBUG
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment