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
bed8ff68
Commit
bed8ff68
authored
Feb 03, 2020
by
Stephane Nicoll
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #20020 from izeye
* pr/20020: Update copyright year of changed files Polish Closes gh-20020
parents
05e7cd6f
b5e23e74
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
23 additions
and
24 deletions
+23
-24
ArtifactoryServiceTests.java
...e/releasescripts/artifactory/ArtifactoryServiceTests.java
+10
-10
CompositeHealthTests.java
...ngframework/boot/actuate/health/CompositeHealthTests.java
+3
-3
SystemHealthTests.java
...pringframework/boot/actuate/health/SystemHealthTests.java
+2
-2
CacheAutoConfiguration.java
...work/boot/autoconfigure/cache/CacheAutoConfiguration.java
+2
-2
HibernateJpaConfiguration.java
...boot/autoconfigure/orm/jpa/HibernateJpaConfiguration.java
+2
-3
JarCommandIT.java
...tTest/java/org/springframework/boot/cli/JarCommandIT.java
+2
-2
ModifiedClassPathExtensionExclusionsTests.java
.../classpath/ModifiedClassPathExtensionExclusionsTests.java
+2
-2
No files found.
ci/images/releasescripts/src/test/java/io/spring/concourse/releasescripts/artifactory/ArtifactoryServiceTests.java
View file @
bed8ff68
...
@@ -76,7 +76,7 @@ class ArtifactoryServiceTests {
...
@@ -76,7 +76,7 @@ class ArtifactoryServiceTests {
void
promoteWhenSuccessful
()
{
void
promoteWhenSuccessful
()
{
this
.
server
this
.
server
.
expect
(
requestTo
(
.
expect
(
requestTo
(
"https://repo.spring.io/api/build/promote/
"
+
"example-build"
+
"/"
+
"
example-build-1"
))
"https://repo.spring.io/api/build/promote/
example-build/
example-build-1"
))
.
andExpect
(
method
(
HttpMethod
.
POST
))
.
andExpect
(
method
(
HttpMethod
.
POST
))
.
andExpect
(
content
().
json
(
.
andExpect
(
content
().
json
(
"{\"status\": \"staged\", \"sourceRepo\": \"libs-staging-local\", \"targetRepo\": \"libs-milestone-local\"}"
))
"{\"status\": \"staged\", \"sourceRepo\": \"libs-staging-local\", \"targetRepo\": \"libs-milestone-local\"}"
))
...
@@ -91,9 +91,9 @@ class ArtifactoryServiceTests {
...
@@ -91,9 +91,9 @@ class ArtifactoryServiceTests {
void
promoteWhenArtifactsAlreadyPromoted
()
{
void
promoteWhenArtifactsAlreadyPromoted
()
{
this
.
server
this
.
server
.
expect
(
requestTo
(
.
expect
(
requestTo
(
"https://repo.spring.io/api/build/promote/
"
+
"example-build"
+
"/"
+
"
example-build-1"
))
"https://repo.spring.io/api/build/promote/
example-build/
example-build-1"
))
.
andRespond
(
withStatus
(
HttpStatus
.
CONFLICT
));
.
andRespond
(
withStatus
(
HttpStatus
.
CONFLICT
));
this
.
server
.
expect
(
requestTo
(
"https://repo.spring.io/api/build/
"
+
"example-build"
+
"/"
+
"
example-build-1"
))
this
.
server
.
expect
(
requestTo
(
"https://repo.spring.io/api/build/
example-build/
example-build-1"
))
.
andRespond
(
withJsonFrom
(
"build-info-response.json"
));
.
andRespond
(
withJsonFrom
(
"build-info-response.json"
));
this
.
service
.
promote
(
"libs-release-local"
,
getReleaseInfo
());
this
.
service
.
promote
(
"libs-release-local"
,
getReleaseInfo
());
this
.
server
.
verify
();
this
.
server
.
verify
();
...
@@ -103,9 +103,9 @@ class ArtifactoryServiceTests {
...
@@ -103,9 +103,9 @@ class ArtifactoryServiceTests {
void
promoteWhenCheckForArtifactsAlreadyPromotedFails
()
{
void
promoteWhenCheckForArtifactsAlreadyPromotedFails
()
{
this
.
server
this
.
server
.
expect
(
requestTo
(
.
expect
(
requestTo
(
"https://repo.spring.io/api/build/promote/
"
+
"example-build"
+
"/"
+
"
example-build-1"
))
"https://repo.spring.io/api/build/promote/
example-build/
example-build-1"
))
.
andRespond
(
withStatus
(
HttpStatus
.
CONFLICT
));
.
andRespond
(
withStatus
(
HttpStatus
.
CONFLICT
));
this
.
server
.
expect
(
requestTo
(
"https://repo.spring.io/api/build/
"
+
"example-build"
+
"/"
+
"
example-build-1"
))
this
.
server
.
expect
(
requestTo
(
"https://repo.spring.io/api/build/
example-build/
example-build-1"
))
.
andRespond
(
withStatus
(
HttpStatus
.
FORBIDDEN
));
.
andRespond
(
withStatus
(
HttpStatus
.
FORBIDDEN
));
assertThatExceptionOfType
(
HttpClientErrorException
.
class
)
assertThatExceptionOfType
(
HttpClientErrorException
.
class
)
.
isThrownBy
(()
->
this
.
service
.
promote
(
"libs-release-local"
,
getReleaseInfo
()));
.
isThrownBy
(()
->
this
.
service
.
promote
(
"libs-release-local"
,
getReleaseInfo
()));
...
@@ -116,9 +116,9 @@ class ArtifactoryServiceTests {
...
@@ -116,9 +116,9 @@ class ArtifactoryServiceTests {
void
promoteWhenPromotionFails
()
{
void
promoteWhenPromotionFails
()
{
this
.
server
this
.
server
.
expect
(
requestTo
(
.
expect
(
requestTo
(
"https://repo.spring.io/api/build/promote/
"
+
"example-build"
+
"/"
+
"
example-build-1"
))
"https://repo.spring.io/api/build/promote/
example-build/
example-build-1"
))
.
andRespond
(
withStatus
(
HttpStatus
.
CONFLICT
));
.
andRespond
(
withStatus
(
HttpStatus
.
CONFLICT
));
this
.
server
.
expect
(
requestTo
(
"https://repo.spring.io/api/build/
"
+
"example-build"
+
"/"
+
"
example-build-1"
))
this
.
server
.
expect
(
requestTo
(
"https://repo.spring.io/api/build/
example-build/
example-build-1"
))
.
andRespond
(
withJsonFrom
(
"staged-build-info-response.json"
));
.
andRespond
(
withJsonFrom
(
"staged-build-info-response.json"
));
assertThatExceptionOfType
(
HttpClientErrorException
.
class
)
assertThatExceptionOfType
(
HttpClientErrorException
.
class
)
.
isThrownBy
(()
->
this
.
service
.
promote
(
"libs-release-local"
,
getReleaseInfo
()));
.
isThrownBy
(()
->
this
.
service
.
promote
(
"libs-release-local"
,
getReleaseInfo
()));
...
@@ -131,7 +131,7 @@ class ArtifactoryServiceTests {
...
@@ -131,7 +131,7 @@ class ArtifactoryServiceTests {
given
(
this
.
bintrayService
.
isDistributionComplete
(
releaseInfo
)).
willReturn
(
true
);
given
(
this
.
bintrayService
.
isDistributionComplete
(
releaseInfo
)).
willReturn
(
true
);
this
.
server
this
.
server
.
expect
(
requestTo
(
.
expect
(
requestTo
(
"https://repo.spring.io/api/build/distribute/
"
+
"example-build"
+
"/"
+
"
example-build-1"
))
"https://repo.spring.io/api/build/distribute/
example-build/
example-build-1"
))
.
andExpect
(
method
(
HttpMethod
.
POST
))
.
andExpect
(
method
(
HttpMethod
.
POST
))
.
andExpect
(
content
().
json
(
.
andExpect
(
content
().
json
(
"{\"sourceRepos\": [\"libs-release-local\"], \"targetRepo\" : \"spring-distributions\", \"async\":\"true\"}"
))
"{\"sourceRepos\": [\"libs-release-local\"], \"targetRepo\" : \"spring-distributions\", \"async\":\"true\"}"
))
...
@@ -148,7 +148,7 @@ class ArtifactoryServiceTests {
...
@@ -148,7 +148,7 @@ class ArtifactoryServiceTests {
ReleaseInfo
releaseInfo
=
getReleaseInfo
();
ReleaseInfo
releaseInfo
=
getReleaseInfo
();
this
.
server
this
.
server
.
expect
(
requestTo
(
.
expect
(
requestTo
(
"https://repo.spring.io/api/build/distribute/
"
+
"example-build"
+
"/"
+
"
example-build-1"
))
"https://repo.spring.io/api/build/distribute/
example-build/
example-build-1"
))
.
andExpect
(
method
(
HttpMethod
.
POST
))
.
andExpect
(
method
(
HttpMethod
.
POST
))
.
andExpect
(
content
().
json
(
.
andExpect
(
content
().
json
(
"{\"sourceRepos\": [\"libs-release-local\"], \"targetRepo\" : \"spring-distributions\", \"async\":\"true\"}"
))
"{\"sourceRepos\": [\"libs-release-local\"], \"targetRepo\" : \"spring-distributions\", \"async\":\"true\"}"
))
...
@@ -168,7 +168,7 @@ class ArtifactoryServiceTests {
...
@@ -168,7 +168,7 @@ class ArtifactoryServiceTests {
given
(
this
.
bintrayService
.
isDistributionComplete
(
releaseInfo
)).
willReturn
(
false
);
given
(
this
.
bintrayService
.
isDistributionComplete
(
releaseInfo
)).
willReturn
(
false
);
this
.
server
this
.
server
.
expect
(
requestTo
(
.
expect
(
requestTo
(
"https://repo.spring.io/api/build/distribute/
"
+
"example-build"
+
"/"
+
"
example-build-1"
))
"https://repo.spring.io/api/build/distribute/
example-build/
example-build-1"
))
.
andExpect
(
method
(
HttpMethod
.
POST
))
.
andExpect
(
method
(
HttpMethod
.
POST
))
.
andExpect
(
content
().
json
(
.
andExpect
(
content
().
json
(
"{\"sourceRepos\": [\"libs-release-local\"], \"targetRepo\" : \"spring-distributions\", \"async\":\"true\"}"
))
"{\"sourceRepos\": [\"libs-release-local\"], \"targetRepo\" : \"spring-distributions\", \"async\":\"true\"}"
))
...
...
spring-boot-project/spring-boot-actuator/src/test/java/org/springframework/boot/actuate/health/CompositeHealthTests.java
View file @
bed8ff68
/*
/*
* Copyright 2012-20
19
the original author or authors.
* Copyright 2012-20
20
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -64,7 +64,7 @@ class CompositeHealthTests {
...
@@ -64,7 +64,7 @@ class CompositeHealthTests {
CompositeHealth
health
=
new
CompositeHealth
(
ApiVersion
.
V3
,
Status
.
UP
,
components
);
CompositeHealth
health
=
new
CompositeHealth
(
ApiVersion
.
V3
,
Status
.
UP
,
components
);
ObjectMapper
mapper
=
new
ObjectMapper
();
ObjectMapper
mapper
=
new
ObjectMapper
();
String
json
=
mapper
.
writeValueAsString
(
health
);
String
json
=
mapper
.
writeValueAsString
(
health
);
assertThat
(
json
).
isEqualTo
(
"{\"status\":\"UP\",\"components\":{
"
+
"
\"db1\":{\"status\":\"UP\"},"
assertThat
(
json
).
isEqualTo
(
"{\"status\":\"UP\",\"components\":{\"db1\":{\"status\":\"UP\"},"
+
"\"db2\":{\"status\":\"DOWN\",\"details\":{\"a\":\"b\"}}}}"
);
+
"\"db2\":{\"status\":\"DOWN\",\"details\":{\"a\":\"b\"}}}}"
);
}
}
...
@@ -76,7 +76,7 @@ class CompositeHealthTests {
...
@@ -76,7 +76,7 @@ class CompositeHealthTests {
CompositeHealth
health
=
new
CompositeHealth
(
ApiVersion
.
V2
,
Status
.
UP
,
components
);
CompositeHealth
health
=
new
CompositeHealth
(
ApiVersion
.
V2
,
Status
.
UP
,
components
);
ObjectMapper
mapper
=
new
ObjectMapper
();
ObjectMapper
mapper
=
new
ObjectMapper
();
String
json
=
mapper
.
writeValueAsString
(
health
);
String
json
=
mapper
.
writeValueAsString
(
health
);
assertThat
(
json
).
isEqualTo
(
"{\"status\":\"UP\",\"details\":{
"
+
"
\"db1\":{\"status\":\"UP\"},"
assertThat
(
json
).
isEqualTo
(
"{\"status\":\"UP\",\"details\":{\"db1\":{\"status\":\"UP\"},"
+
"\"db2\":{\"status\":\"DOWN\",\"details\":{\"a\":\"b\"}}}}"
);
+
"\"db2\":{\"status\":\"DOWN\",\"details\":{\"a\":\"b\"}}}}"
);
}
}
...
...
spring-boot-project/spring-boot-actuator/src/test/java/org/springframework/boot/actuate/health/SystemHealthTests.java
View file @
bed8ff68
/*
/*
* Copyright 2012-20
19
the original author or authors.
* Copyright 2012-20
20
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -45,7 +45,7 @@ class SystemHealthTests {
...
@@ -45,7 +45,7 @@ class SystemHealthTests {
CompositeHealth
health
=
new
SystemHealth
(
ApiVersion
.
V3
,
Status
.
UP
,
components
,
groups
);
CompositeHealth
health
=
new
SystemHealth
(
ApiVersion
.
V3
,
Status
.
UP
,
components
,
groups
);
ObjectMapper
mapper
=
new
ObjectMapper
();
ObjectMapper
mapper
=
new
ObjectMapper
();
String
json
=
mapper
.
writeValueAsString
(
health
);
String
json
=
mapper
.
writeValueAsString
(
health
);
assertThat
(
json
).
isEqualTo
(
"{\"status\":\"UP\",\"components\":{
"
+
"
\"db1\":{\"status\":\"UP\"},"
assertThat
(
json
).
isEqualTo
(
"{\"status\":\"UP\",\"components\":{\"db1\":{\"status\":\"UP\"},"
+
"\"db2\":{\"status\":\"DOWN\",\"details\":{\"a\":\"b\"}}},"
+
"\"db2\":{\"status\":\"DOWN\",\"details\":{\"a\":\"b\"}}},"
+
"\"groups\":[\"liveness\",\"readiness\"]}"
);
+
"\"groups\":[\"liveness\",\"readiness\"]}"
);
}
}
...
...
spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/cache/CacheAutoConfiguration.java
View file @
bed8ff68
/*
/*
* Copyright 2012-20
19
the original author or authors.
* Copyright 2012-20
20
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -107,7 +107,7 @@ public class CacheAutoConfiguration {
...
@@ -107,7 +107,7 @@ public class CacheAutoConfiguration {
@Override
@Override
public
void
afterPropertiesSet
()
{
public
void
afterPropertiesSet
()
{
Assert
.
notNull
(
this
.
cacheManager
.
getIfAvailable
(),
Assert
.
notNull
(
this
.
cacheManager
.
getIfAvailable
(),
()
->
"No cache manager could be auto-configured, check your configuration (caching
"
+
"
type is '"
()
->
"No cache manager could be auto-configured, check your configuration (caching type is '"
+
this
.
cacheProperties
.
getType
()
+
"')"
);
+
this
.
cacheProperties
.
getType
()
+
"')"
);
}
}
...
...
spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/orm/jpa/HibernateJpaConfiguration.java
View file @
bed8ff68
/*
/*
* Copyright 2012-20
19
the original author or authors.
* Copyright 2012-20
20
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -183,8 +183,7 @@ class HibernateJpaConfiguration extends JpaBaseConfiguration {
...
@@ -183,8 +183,7 @@ class HibernateJpaConfiguration extends JpaBaseConfiguration {
// containers (e.g. JBoss EAP 6) wrap it in the superclass LinkageError
// containers (e.g. JBoss EAP 6) wrap it in the superclass LinkageError
if
(!
isUsingJndi
())
{
if
(!
isUsingJndi
())
{
throw
new
IllegalStateException
(
throw
new
IllegalStateException
(
"Unable to set Hibernate JTA platform, are you using the correct "
+
"version of Hibernate?"
,
"Unable to set Hibernate JTA platform, are you using the correct version of Hibernate?"
,
ex
);
ex
);
}
}
// Assume that Hibernate will use JNDI
// Assume that Hibernate will use JNDI
if
(
logger
.
isDebugEnabled
())
{
if
(
logger
.
isDebugEnabled
())
{
...
...
spring-boot-project/spring-boot-cli/src/intTest/java/org/springframework/boot/cli/JarCommandIT.java
View file @
bed8ff68
...
@@ -55,7 +55,7 @@ class JarCommandIT {
...
@@ -55,7 +55,7 @@ class JarCommandIT {
invocation
.
await
();
invocation
.
await
();
assertThat
(
invocation
.
getStandardOutput
()).
isEqualTo
(
""
);
assertThat
(
invocation
.
getStandardOutput
()).
isEqualTo
(
""
);
assertThat
(
invocation
.
getErrorOutput
())
assertThat
(
invocation
.
getErrorOutput
())
.
contains
(
"The name of the
"
+
"
resulting jar and at least one source file must be specified"
);
.
contains
(
"The name of the resulting jar and at least one source file must be specified"
);
}
}
@Test
@Test
...
@@ -64,7 +64,7 @@ class JarCommandIT {
...
@@ -64,7 +64,7 @@ class JarCommandIT {
invocation
.
await
();
invocation
.
await
();
assertThat
(
invocation
.
getStandardOutput
()).
isEqualTo
(
""
);
assertThat
(
invocation
.
getStandardOutput
()).
isEqualTo
(
""
);
assertThat
(
invocation
.
getErrorOutput
())
assertThat
(
invocation
.
getErrorOutput
())
.
contains
(
"The name of the
"
+
"
resulting jar and at least one source file must be specified"
);
.
contains
(
"The name of the resulting jar and at least one source file must be specified"
);
}
}
@Test
@Test
...
...
spring-boot-project/spring-boot-tools/spring-boot-test-support/src/test/java/org/springframework/boot/testsupport/classpath/ModifiedClassPathExtensionExclusionsTests.java
View file @
bed8ff68
/*
/*
* Copyright 2012-20
19
the original author or authors.
* Copyright 2012-20
20
the original author or authors.
*
*
* Licensed under the Apache License, Version 2.0 (the "License");
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* you may not use this file except in compliance with the License.
...
@@ -30,7 +30,7 @@ import static org.hamcrest.Matchers.isA;
...
@@ -30,7 +30,7 @@ import static org.hamcrest.Matchers.isA;
@ClassPathExclusions
(
"hibernate-validator-*.jar"
)
@ClassPathExclusions
(
"hibernate-validator-*.jar"
)
class
ModifiedClassPathExtensionExclusionsTests
{
class
ModifiedClassPathExtensionExclusionsTests
{
private
static
final
String
EXCLUDED_RESOURCE
=
"META-INF/services/
"
+
"
javax.validation.spi.ValidationProvider"
;
private
static
final
String
EXCLUDED_RESOURCE
=
"META-INF/services/javax.validation.spi.ValidationProvider"
;
@Test
@Test
void
entriesAreFilteredFromTestClassClassLoader
()
{
void
entriesAreFilteredFromTestClassClassLoader
()
{
...
...
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