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
c5cc626d
Commit
c5cc626d
authored
Oct 11, 2016
by
Stephane Nicoll
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove remote shell support
See gh-7044
parent
66a3df45
Changes
36
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
36 changed files
with
5 additions
and
2498 deletions
+5
-2498
pom.xml
spring-boot-actuator/pom.xml
+0
-20
CrshAutoConfiguration.java
...ork/boot/actuate/autoconfigure/CrshAutoConfiguration.java
+0
-573
ShellProperties.java
...framework/boot/actuate/autoconfigure/ShellProperties.java
+0
-547
additional-spring-configuration-metadata.json
...es/META-INF/additional-spring-configuration-metadata.json
+0
-21
spring.factories
...oot-actuator/src/main/resources/META-INF/spring.factories
+0
-1
CrshAutoConfigurationTests.java
...oot/actuate/autoconfigure/CrshAutoConfigurationTests.java
+0
-372
ShellPropertiesTests.java
...work/boot/actuate/autoconfigure/ShellPropertiesTests.java
+0
-271
ReproIntegrationTests.java
...a/org/springframework/boot/cli/ReproIntegrationTests.java
+1
-7
crsh.groovy
spring-boot-cli/src/test/resources/repro-samples/crsh.groovy
+0
-14
pom.xml
spring-boot-dependencies/pom.xml
+0
-47
pom.xml
spring-boot-docs/pom.xml
+0
-16
appendix-application-properties.adoc
...cs/src/main/asciidoc/appendix-application-properties.adoc
+0
-20
documentation-overview.adoc
...g-boot-docs/src/main/asciidoc/documentation-overview.adoc
+0
-1
production-ready-features.adoc
...oot-docs/src/main/asciidoc/production-ready-features.adoc
+2
-144
generateStarterTables.groovy
...ng-boot-docs/src/main/groovy/generateStarterTables.groovy
+1
-1
application.properties
...actuator-log4j2/src/main/resources/application.properties
+0
-8
pom.xml
...ng-boot-samples/spring-boot-sample-actuator-noweb/pom.xml
+0
-4
application.properties
...-actuator-noweb/src/main/resources/application.properties
+0
-5
pom.xml
spring-boot-samples/spring-boot-sample-actuator/pom.xml
+0
-18
application.properties
...sample-actuator/src/main/resources/application.properties
+0
-8
pom.xml
spring-boot-starters/pom.xml
+0
-1
pom.xml
...ng-boot-starters/spring-boot-starter-remote-shell/pom.xml
+0
-142
RemoteShellStarterDeprecatedWarningAutoConfiguration.java
...RemoteShellStarterDeprecatedWarningAutoConfiguration.java
+0
-49
spring.factories
...remote-shell/src/main/resources/META-INF/spring.factories
+0
-2
spring.provides
...-remote-shell/src/main/resources/META-INF/spring.provides
+0
-1
autoconfig.groovy
...shell/src/main/resources/commands/crash/autoconfig.groovy
+0
-29
beans.groovy
...mote-shell/src/main/resources/commands/crash/beans.groovy
+0
-17
endpoint.groovy
...e-shell/src/main/resources/commands/crash/endpoint.groovy
+0
-46
login.groovy
...mote-shell/src/main/resources/commands/crash/login.groovy
+0
-48
metrics.groovy
...te-shell/src/main/resources/commands/crash/metrics.groovy
+0
-49
DefaultLogbackConfiguration.java
...ork/boot/logging/logback/DefaultLogbackConfiguration.java
+1
-5
logging-file.properties
...springframework/boot/logging/java/logging-file.properties
+0
-1
logging.properties
.../org/springframework/boot/logging/java/logging.properties
+0
-1
log4j2-file.xml
...s/org/springframework/boot/logging/log4j2/log4j2-file.xml
+0
-3
log4j2.xml
...ources/org/springframework/boot/logging/log4j2/log4j2.xml
+0
-3
defaults.xml
...ces/org/springframework/boot/logging/logback/defaults.xml
+0
-3
No files found.
spring-boot-actuator/pom.xml
View file @
c5cc626d
...
@@ -234,21 +234,6 @@
...
@@ -234,21 +234,6 @@
<artifactId>
tomcat-embed-el
</artifactId>
<artifactId>
tomcat-embed-el
</artifactId>
<optional>
true
</optional>
<optional>
true
</optional>
</dependency>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.shell
</artifactId>
<optional>
true
</optional>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.cli
</artifactId>
<optional>
true
</optional>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.embed.spring
</artifactId>
<optional>
true
</optional>
</dependency>
<dependency>
<dependency>
<groupId>
org.jolokia
</groupId>
<groupId>
org.jolokia
</groupId>
<artifactId>
jolokia-core
</artifactId>
<artifactId>
jolokia-core
</artifactId>
...
@@ -334,11 +319,6 @@
...
@@ -334,11 +319,6 @@
<artifactId>
aspectjrt
</artifactId>
<artifactId>
aspectjrt
</artifactId>
<scope>
test
</scope>
<scope>
test
</scope>
</dependency>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.connectors.telnet
</artifactId>
<scope>
test
</scope>
</dependency>
<dependency>
<dependency>
<groupId>
org.hsqldb
</groupId>
<groupId>
org.hsqldb
</groupId>
<artifactId>
hsqldb
</artifactId>
<artifactId>
hsqldb
</artifactId>
...
...
spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/CrshAutoConfiguration.java
deleted
100644 → 0
View file @
66a3df45
This diff is collapsed.
Click to expand it.
spring-boot-actuator/src/main/java/org/springframework/boot/actuate/autoconfigure/ShellProperties.java
deleted
100644 → 0
View file @
66a3df45
This diff is collapsed.
Click to expand it.
spring-boot-actuator/src/main/resources/META-INF/additional-spring-configuration-metadata.json
View file @
c5cc626d
...
@@ -253,27 +253,6 @@
...
@@ -253,27 +253,6 @@
"name"
:
"any"
"name"
:
"any"
}
}
]
]
},
{
"name"
:
"management.shell.auth.type"
,
"values"
:
[
{
"value"
:
"simple"
,
"description"
:
"Use a simple user/password based authentication."
},
{
"value"
:
"spring"
,
"description"
:
"Integrate with Spring Security."
},
{
"value"
:
"key"
,
"description"
:
"Use a Key-based authentication."
},
{
"value"
:
"jaas"
,
"description"
:
"Use JAAS authentication."
}
]
}
}
]}
]}
spring-boot-actuator/src/main/resources/META-INF/spring.factories
View file @
c5cc626d
org.springframework.boot.autoconfigure.EnableAutoConfiguration=\
org.springframework.boot.autoconfigure.EnableAutoConfiguration=\
org.springframework.boot.actuate.autoconfigure.AuditAutoConfiguration,\
org.springframework.boot.actuate.autoconfigure.AuditAutoConfiguration,\
org.springframework.boot.actuate.autoconfigure.CacheStatisticsAutoConfiguration,\
org.springframework.boot.actuate.autoconfigure.CacheStatisticsAutoConfiguration,\
org.springframework.boot.actuate.autoconfigure.CrshAutoConfiguration,\
org.springframework.boot.actuate.autoconfigure.EndpointAutoConfiguration,\
org.springframework.boot.actuate.autoconfigure.EndpointAutoConfiguration,\
org.springframework.boot.actuate.autoconfigure.EndpointMBeanExportAutoConfiguration,\
org.springframework.boot.actuate.autoconfigure.EndpointMBeanExportAutoConfiguration,\
org.springframework.boot.actuate.autoconfigure.EndpointWebMvcAutoConfiguration,\
org.springframework.boot.actuate.autoconfigure.EndpointWebMvcAutoConfiguration,\
...
...
spring-boot-actuator/src/test/java/org/springframework/boot/actuate/autoconfigure/CrshAutoConfigurationTests.java
deleted
100644 → 0
View file @
66a3df45
This diff is collapsed.
Click to expand it.
spring-boot-actuator/src/test/java/org/springframework/boot/actuate/autoconfigure/ShellPropertiesTests.java
deleted
100644 → 0
View file @
66a3df45
/*
* Copyright 2012-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
.
boot
.
actuate
.
autoconfigure
;
import
java.util.Properties
;
import
java.util.UUID
;
import
org.crsh.plugin.PluginLifeCycle
;
import
org.junit.After
;
import
org.junit.Assert
;
import
org.junit.Rule
;
import
org.junit.Test
;
import
org.junit.rules.ExpectedException
;
import
org.springframework.beans.factory.BeanCreationException
;
import
org.springframework.boot.actuate.autoconfigure.ShellProperties.CrshShellProperties
;
import
org.springframework.boot.actuate.autoconfigure.ShellProperties.JaasAuthenticationProperties
;
import
org.springframework.boot.actuate.autoconfigure.ShellProperties.KeyAuthenticationProperties
;
import
org.springframework.boot.actuate.autoconfigure.ShellProperties.SimpleAuthenticationProperties
;
import
org.springframework.boot.actuate.autoconfigure.ShellProperties.SpringAuthenticationProperties
;
import
org.springframework.boot.context.properties.EnableConfigurationProperties
;
import
org.springframework.boot.test.util.EnvironmentTestUtils
;
import
org.springframework.context.annotation.AnnotationConfigApplicationContext
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.Configuration
;
import
org.springframework.mock.env.MockEnvironment
;
import
org.springframework.mock.web.MockServletContext
;
import
org.springframework.web.context.support.AnnotationConfigWebApplicationContext
;
import
static
org
.
assertj
.
core
.
api
.
Assertions
.
assertThat
;
/**
* Tests for {@link ShellProperties}.
*
* @author Christian Dupuis
* @author Stephane Nicoll
*/
@Deprecated
public
class
ShellPropertiesTests
{
@Rule
public
final
ExpectedException
thrown
=
ExpectedException
.
none
();
private
AnnotationConfigApplicationContext
context
;
@After
public
void
close
()
{
if
(
this
.
context
!=
null
)
{
this
.
context
.
close
();
}
}
@Test
public
void
testBindingAuth
()
{
ShellProperties
props
=
load
(
ShellProperties
.
class
,
"management.shell.auth.type=spring"
);
assertThat
(
props
.
getAuth
().
getType
()).
isEqualTo
(
"spring"
);
}
@Test
public
void
testBindingAuthIfEmpty
()
{
this
.
thrown
.
expect
(
BeanCreationException
.
class
);
this
.
thrown
.
expectMessage
(
"Auth type must not be empty"
);
load
(
ShellProperties
.
class
,
"management.shell.auth.type= "
);
}
@Test
public
void
testBindingCommandRefreshInterval
()
{
ShellProperties
props
=
load
(
ShellProperties
.
class
,
"management.shell.command-refresh-interval=1"
);
assertThat
(
props
.
getCommandRefreshInterval
()).
isEqualTo
(
1
);
}
@Test
public
void
testBindingCommandPathPatterns
()
{
ShellProperties
props
=
load
(
ShellProperties
.
class
,
"management.shell.command-path-patterns=pattern1, pattern2"
);
assertThat
(
props
.
getCommandPathPatterns
().
length
).
isEqualTo
(
2
);
Assert
.
assertArrayEquals
(
new
String
[]
{
"pattern1"
,
"pattern2"
},
props
.
getCommandPathPatterns
());
}
@Test
public
void
testBindingConfigPathPatterns
()
{
ShellProperties
props
=
load
(
ShellProperties
.
class
,
"management.shell.config-path-patterns=pattern1, pattern2"
);
assertThat
(
props
.
getConfigPathPatterns
().
length
).
isEqualTo
(
2
);
Assert
.
assertArrayEquals
(
new
String
[]
{
"pattern1"
,
"pattern2"
},
props
.
getConfigPathPatterns
());
}
@Test
public
void
testBindingDisabledPlugins
()
{
ShellProperties
props
=
load
(
ShellProperties
.
class
,
"management.shell.disabled-plugins=pattern1, pattern2"
);
assertThat
(
props
.
getDisabledPlugins
().
length
).
isEqualTo
(
2
);
assertThat
(
props
.
getDisabledPlugins
()).
containsExactly
(
"pattern1"
,
"pattern2"
);
}
@Test
public
void
testBindingDisabledCommands
()
{
ShellProperties
props
=
load
(
ShellProperties
.
class
,
"management.shell.disabled-commands=pattern1, pattern2"
);
assertThat
(
props
.
getDisabledCommands
()).
containsExactly
(
"pattern1"
,
"pattern2"
);
}
@Test
public
void
testBindingSsh
()
{
ShellProperties
props
=
load
(
ShellProperties
.
class
,
"management.shell.ssh.enabled=true"
,
"management.shell.ssh.port=2222"
,
"management.shell.ssh.key-path=~/.ssh/test.pem"
);
Properties
p
=
props
.
asCrshShellConfig
();
assertThat
(
p
.
get
(
"crash.ssh.port"
)).
isEqualTo
(
"2222"
);
assertThat
(
p
.
get
(
"crash.ssh.keypath"
)).
isEqualTo
(
"~/.ssh/test.pem"
);
}
@Test
public
void
testBindingSshIgnored
()
{
ShellProperties
props
=
load
(
ShellProperties
.
class
,
"management.shell.ssh.enabled=false"
,
"management.shell.ssh.port=2222"
,
"management.shell.ssh.key-path=~/.ssh/test.pem"
);
Properties
p
=
props
.
asCrshShellConfig
();
assertThat
(
p
.
get
(
"crash.ssh.port"
)).
isNull
();
assertThat
(
p
.
get
(
"crash.ssh.keypath"
)).
isNull
();
}
@Test
public
void
testBindingTelnet
()
{
ShellProperties
props
=
load
(
ShellProperties
.
class
,
"management.shell.telnet.enabled=true"
,
"management.shell.telnet.port=2222"
);
Properties
p
=
props
.
asCrshShellConfig
();
assertThat
(
p
.
get
(
"crash.telnet.port"
)).
isEqualTo
(
"2222"
);
}
@Test
public
void
testBindingTelnetIgnored
()
{
ShellProperties
props
=
load
(
ShellProperties
.
class
,
"management.shell.telnet.enabled=false"
,
"management.shell.telnet.port=2222"
);
Properties
p
=
props
.
asCrshShellConfig
();
assertThat
(
p
.
get
(
"crash.telnet.port"
)).
isNull
();
}
@Test
public
void
testBindingJaas
()
{
JaasAuthenticationProperties
props
=
load
(
JaasAuthenticationProperties
.
class
,
"management.shell.auth.jaas.domain=my-test-domain"
);
Properties
p
=
new
Properties
();
props
.
applyToCrshShellConfig
(
p
);
assertThat
(
p
.
get
(
"crash.auth.jaas.domain"
)).
isEqualTo
(
"my-test-domain"
);
}
@Test
public
void
testBindingKey
()
{
KeyAuthenticationProperties
props
=
load
(
KeyAuthenticationProperties
.
class
,
"management.shell.auth.key.path=~/.ssh/test.pem"
);
Properties
p
=
new
Properties
();
props
.
applyToCrshShellConfig
(
p
);
assertThat
(
p
.
get
(
"crash.auth.key.path"
)).
isEqualTo
(
"~/.ssh/test.pem"
);
}
@Test
public
void
testBindingKeyIgnored
()
{
KeyAuthenticationProperties
props
=
load
(
KeyAuthenticationProperties
.
class
);
Properties
p
=
new
Properties
();
props
.
applyToCrshShellConfig
(
p
);
assertThat
(
p
.
get
(
"crash.auth.key.path"
)).
isNull
();
}
@Test
public
void
testBindingSimple
()
{
SimpleAuthenticationProperties
props
=
load
(
SimpleAuthenticationProperties
.
class
,
"management.shell.auth.simple.user.name=username123"
,
"management.shell.auth.simple.user.password=password123"
);
Properties
p
=
new
Properties
();
props
.
applyToCrshShellConfig
(
p
);
assertThat
(
p
.
get
(
"crash.auth.simple.username"
)).
isEqualTo
(
"username123"
);
assertThat
(
p
.
get
(
"crash.auth.simple.password"
)).
isEqualTo
(
"password123"
);
}
@Test
public
void
testDefaultPasswordAutoGeneratedIfUnresolvedPlaceholder
()
{
SimpleAuthenticationProperties
security
=
load
(
SimpleAuthenticationProperties
.
class
,
"management.shell.auth.simple.user.password=${ADMIN_PASSWORD}"
);
assertThat
(
security
.
getUser
().
isDefaultPassword
()).
isTrue
();
}
@Test
public
void
testDefaultPasswordAutoGeneratedIfEmpty
()
{
SimpleAuthenticationProperties
security
=
load
(
SimpleAuthenticationProperties
.
class
,
"management.shell.auth.simple.user.password="
);
assertThat
(
security
.
getUser
().
isDefaultPassword
()).
isTrue
();
}
@Test
public
void
testBindingSpring
()
{
SpringAuthenticationProperties
props
=
load
(
SpringAuthenticationProperties
.
class
,
"management.shell.auth.spring.roles=role1,role2"
);
Properties
p
=
new
Properties
();
props
.
applyToCrshShellConfig
(
p
);
assertThat
(
p
.
get
(
"crash.auth.spring.roles"
)).
isEqualTo
(
"role1,role2"
);
}
@Test
public
void
testCustomShellProperties
()
throws
Exception
{
MockEnvironment
env
=
new
MockEnvironment
();
env
.
setProperty
(
"management.shell.auth.type"
,
"simple"
);
AnnotationConfigWebApplicationContext
ctx
=
new
AnnotationConfigWebApplicationContext
();
ctx
.
setEnvironment
(
env
);
ctx
.
setServletContext
(
new
MockServletContext
());
ctx
.
register
(
TestShellConfiguration
.
class
);
ctx
.
register
(
CrshAutoConfiguration
.
class
);
ctx
.
refresh
();
PluginLifeCycle
lifeCycle
=
ctx
.
getBean
(
PluginLifeCycle
.
class
);
String
uuid
=
lifeCycle
.
getConfig
().
getProperty
(
"test.uuid"
);
assertThat
(
uuid
).
isEqualTo
(
TestShellConfiguration
.
uuid
);
ctx
.
close
();
}
private
<
T
>
T
load
(
Class
<
T
>
type
,
String
...
environment
)
{
AnnotationConfigApplicationContext
ctx
=
new
AnnotationConfigApplicationContext
();
EnvironmentTestUtils
.
addEnvironment
(
ctx
,
environment
);
ctx
.
register
(
TestConfiguration
.
class
);
ctx
.
refresh
();
this
.
context
=
ctx
;
return
this
.
context
.
getBean
(
type
);
}
@Configuration
@EnableConfigurationProperties
({
ShellProperties
.
class
,
JaasAuthenticationProperties
.
class
,
KeyAuthenticationProperties
.
class
,
SimpleAuthenticationProperties
.
class
,
SpringAuthenticationProperties
.
class
})
static
class
TestConfiguration
{
}
@Configuration
public
static
class
TestShellConfiguration
{
public
static
String
uuid
=
UUID
.
randomUUID
().
toString
();
@Bean
public
CrshShellProperties
testProperties
()
{
return
new
CrshShellProperties
()
{
@Override
protected
void
applyToCrshShellConfig
(
Properties
config
)
{
config
.
put
(
"test.uuid"
,
uuid
);
}
};
}
}
}
spring-boot-cli/src/test/java/org/springframework/boot/cli/ReproIntegrationTests.java
View file @
c5cc626d
...
@@ -51,12 +51,6 @@ public class ReproIntegrationTests {
...
@@ -51,12 +51,6 @@ public class ReproIntegrationTests {
assertThat
(
this
.
cli
.
getOutput
()).
contains
(
"Hello World"
);
assertThat
(
this
.
cli
.
getOutput
()).
contains
(
"Hello World"
);
}
}
@Test
public
void
shellDependencies
()
throws
Exception
{
this
.
cli
.
run
(
"crsh.groovy"
);
assertThat
(
this
.
cli
.
getHttpOutput
()).
contains
(
"{\"message\":\"Hello World\"}"
);
}
@Test
@Test
public
void
dataJpaDependencies
()
throws
Exception
{
public
void
dataJpaDependencies
()
throws
Exception
{
this
.
cli
.
run
(
"data-jpa.groovy"
);
this
.
cli
.
run
(
"data-jpa.groovy"
);
...
@@ -67,7 +61,7 @@ public class ReproIntegrationTests {
...
@@ -67,7 +61,7 @@ public class ReproIntegrationTests {
public
void
jarFileExtensionNeeded
()
throws
Exception
{
public
void
jarFileExtensionNeeded
()
throws
Exception
{
this
.
thrown
.
expect
(
IllegalStateException
.
class
);
this
.
thrown
.
expect
(
IllegalStateException
.
class
);
this
.
thrown
.
expectMessage
(
"is not a JAR file"
);
this
.
thrown
.
expectMessage
(
"is not a JAR file"
);
this
.
cli
.
jar
(
"secure.groovy"
,
"crsh.groovy"
);
this
.
cli
.
jar
(
"secure.groovy"
);
}
}
}
}
spring-boot-cli/src/test/resources/repro-samples/crsh.groovy
deleted
100644 → 0
View file @
66a3df45
package
org.test
@Grab
(
"spring-boot-starter-remote-shell"
)
@RestController
class
SampleController
{
@RequestMapping
(
"/"
)
public
def
hello
()
{
[
message:
"Hello World"
]
}
}
spring-boot-dependencies/pom.xml
View file @
c5cc626d
...
@@ -63,7 +63,6 @@
...
@@ -63,7 +63,6 @@
<commons-pool2.version>
2.4.2
</commons-pool2.version>
<commons-pool2.version>
2.4.2
</commons-pool2.version>
<couchbase-client.version>
2.2.8
</couchbase-client.version>
<couchbase-client.version>
2.2.8
</couchbase-client.version>
<couchbase-cache-client.version>
2.0.0
</couchbase-cache-client.version>
<couchbase-cache-client.version>
2.0.0
</couchbase-cache-client.version>
<crashub.version>
1.3.2
</crashub.version>
<derby.version>
10.12.1.1
</derby.version>
<derby.version>
10.12.1.1
</derby.version>
<dom4j.version>
1.6.1
</dom4j.version>
<dom4j.version>
1.6.1
</dom4j.version>
<dropwizard-metrics.version>
3.1.2
</dropwizard-metrics.version>
<dropwizard-metrics.version>
3.1.2
</dropwizard-metrics.version>
...
@@ -442,11 +441,6 @@
...
@@ -442,11 +441,6 @@
<artifactId>
spring-boot-starter-jta-narayana
</artifactId>
<artifactId>
spring-boot-starter-jta-narayana
</artifactId>
<version>
2.0.0.BUILD-SNAPSHOT
</version>
<version>
2.0.0.BUILD-SNAPSHOT
</version>
</dependency>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-remote-shell
</artifactId>
<version>
2.0.0.BUILD-SNAPSHOT
</version>
</dependency>
<dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-security
</artifactId>
<artifactId>
spring-boot-starter-security
</artifactId>
...
@@ -1454,47 +1448,6 @@
...
@@ -1454,47 +1448,6 @@
<artifactId>
janino
</artifactId>
<artifactId>
janino
</artifactId>
<version>
${janino.version}
</version>
<version>
${janino.version}
</version>
</dependency>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.cli
</artifactId>
<version>
${crashub.version}
</version>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.connectors.ssh
</artifactId>
<version>
${crashub.version}
</version>
<exclusions>
<exclusion>
<groupId>
commons-logging
</groupId>
<artifactId>
commons-logging
</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.connectors.telnet
</artifactId>
<version>
${crashub.version}
</version>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.embed.spring
</artifactId>
<version>
${crashub.version}
</version>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.plugins.cron
</artifactId>
<version>
${crashub.version}
</version>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.plugins.mail
</artifactId>
<version>
${crashub.version}
</version>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.shell
</artifactId>
<version>
${crashub.version}
</version>
</dependency>
<dependency>
<dependency>
<groupId>
org.eclipse.jetty
</groupId>
<groupId>
org.eclipse.jetty
</groupId>
<artifactId>
jetty-annotations
</artifactId>
<artifactId>
jetty-annotations
</artifactId>
...
...
spring-boot-docs/pom.xml
View file @
c5cc626d
...
@@ -348,22 +348,6 @@
...
@@ -348,22 +348,6 @@
<artifactId>
groovy-templates
</artifactId>
<artifactId>
groovy-templates
</artifactId>
<optional>
true
</optional>
<optional>
true
</optional>
</dependency>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.cli
</artifactId>
<optional>
true
</optional>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.shell
</artifactId>
<optional>
true
</optional>
<exclusions>
<exclusion>
<artifactId>
groovy-all
</artifactId>
<groupId>
org.codehaus.groovy
</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<dependency>
<groupId>
org.eclipse.jetty
</groupId>
<groupId>
org.eclipse.jetty
</groupId>
<artifactId>
jetty-util
</artifactId>
<artifactId>
jetty-util
</artifactId>
...
...
spring-boot-docs/src/main/asciidoc/appendix-application-properties.adoc
View file @
c5cc626d
...
@@ -1042,26 +1042,6 @@ content into your application; rather pick only the properties that you need.
...
@@ -1042,26 +1042,6 @@ content into your application; rather pick only the properties that you need.
management.info.git.enabled=true # Enable git info.
management.info.git.enabled=true # Enable git info.
management.info.git.mode=simple # Mode to use to expose git information.
management.info.git.mode=simple # Mode to use to expose git information.
# REMOTE SHELL ({sc-spring-boot-actuator}/autoconfigure/ShellProperties.{sc-ext}[ShellProperties])
management.shell.auth.type=simple # Authentication type. Auto-detected according to the environment.
management.shell.auth.jaas.domain=my-domain # JAAS domain.
management.shell.auth.key.path= # Path to the authentication key. This should point to a valid ".pem" file.
management.shell.auth.simple.user.name=user # Login user.
management.shell.auth.simple.user.password= # Login password.
management.shell.auth.spring.roles=ADMIN # Comma-separated list of required roles to login to the CRaSH console.
management.shell.command-path-patterns=classpath*:/commands/**,classpath*:/crash/commands/** # Patterns to use to look for commands.
management.shell.command-refresh-interval=-1 # Scan for changes and update the command if necessary (in seconds).
management.shell.config-path-patterns=classpath*:/crash/* # Patterns to use to look for configurations.
management.shell.disabled-commands=jpa*,jdbc*,jndi* # Comma-separated list of commands to disable.
management.shell.disabled-plugins= # Comma-separated list of plugins to disable. Certain plugins are disabled by default based on the environment.
management.shell.ssh.auth-timeout = # Number of milliseconds after user will be prompted to login again.
management.shell.ssh.enabled=true # Enable CRaSH SSH support.
management.shell.ssh.idle-timeout = # Number of milliseconds after which unused connections are closed.
management.shell.ssh.key-path= # Path to the SSH server key.
management.shell.ssh.port=2000 # SSH port.
management.shell.telnet.enabled=false # Enable CRaSH telnet support. Enabled by default if the TelnetPlugin is available.
management.shell.telnet.port=5000 # Telnet port.
# TRACING ({sc-spring-boot-actuator}/trace/TraceProperties.{sc-ext}[TraceProperties])
# TRACING ({sc-spring-boot-actuator}/trace/TraceProperties.{sc-ext}[TraceProperties])
management.trace.include=request-headers,response-headers,cookies,errors # Items to be included in the trace.
management.trace.include=request-headers,response-headers,cookies,errors # Items to be included in the trace.
...
...
spring-boot-docs/src/main/asciidoc/documentation-overview.adoc
View file @
c5cc626d
...
@@ -124,7 +124,6 @@ When you're ready to push your Spring Boot application to production, we've got
...
@@ -124,7 +124,6 @@ When you're ready to push your Spring Boot application to production, we've got
* *Connection options:*
* *Connection options:*
<<production-ready-features.adoc#production-ready-monitoring, HTTP>> |
<<production-ready-features.adoc#production-ready-monitoring, HTTP>> |
<<production-ready-features.adoc#production-ready-jmx, JMX>> |
<<production-ready-features.adoc#production-ready-jmx, JMX>> |
<<production-ready-features.adoc#production-ready-remote-shell, SSH>>
* *Monitoring:*
* *Monitoring:*
<<production-ready-features.adoc#production-ready-metrics, Metrics>> |
<<production-ready-features.adoc#production-ready-metrics, Metrics>> |
<<production-ready-features.adoc#production-ready-auditing, Auditing>> |
<<production-ready-features.adoc#production-ready-auditing, Auditing>> |
...
...
spring-boot-docs/src/main/asciidoc/production-ready-features.adoc
View file @
c5cc626d
...
@@ -5,8 +5,8 @@
...
@@ -5,8 +5,8 @@
--
--
Spring Boot includes a number of additional features to help you monitor and manage your
Spring Boot includes a number of additional features to help you monitor and manage your
application when it's pushed to production. You can choose to manage and monitor your
application when it's pushed to production. You can choose to manage and monitor your
application using HTTP endpoints
, with JMX or even by remote shell (SSH or Telnet).
application using HTTP endpoints
or with JMX. Auditing, health and metrics gathering can
Auditing, health and metrics gathering can
be automatically applied to your application.
be automatically applied to your application.
Actuator HTTP endpoints are only available with a Spring MVC-based application. In
Actuator HTTP endpoints are only available with a Spring MVC-based application. In
particular, it will not work with Jersey <<howto.adoc#howto-use-actuator-with-jersey,
particular, it will not work with Jersey <<howto.adoc#howto-use-actuator-with-jersey,
...
@@ -802,148 +802,6 @@ If you are using Jolokia but you don't want Spring Boot to configure it, simply
...
@@ -802,148 +802,6 @@ If you are using Jolokia but you don't want Spring Boot to configure it, simply
[[
production
-
ready
-
remote
-
shell
]]
==
Monitoring
and
management
using
a
remote
shell
(
deprecated
)
Spring
Boot
supports
an
integrated
Java
shell
called
'`CRaSH`'
.
You
can
use
CRaSH
to
`
ssh
`
or
`
telnet
`
into
your
running
application
.
To
enable
remote
shell
support
,
add
the
following
dependency
to
your
project
:
[
source
,
xml
,
indent
=
0
]
----
<
dependency
>
<
groupId
>
org
.
springframework
.
boot
</
groupId
>
<
artifactId
>
spring
-
boot
-
starter
-
remote
-
shell
</
artifactId
>
</
dependency
>
----
TIP
:
If
you
want
to
also
enable
telnet
access
you
will
additionally
need
a
dependency
on
`
org
.
crsh
:
crsh
.
shell
.
telnet
`.
NOTE
:
CRaSH
requires
to
run
with
a
JDK
as
it
compiles
commands
on
the
fly
.
If
a
basic
`
help
`
command
fails
,
you
are
probably
running
with
a
JRE
.
[[
production
-
ready
-
connecting
-
to
-
the
-
remote
-
shell
]]
===
Connecting
to
the
remote
shell
By
default
the
remote
shell
will
listen
for
connections
on
port
`
2000
`.
The
default
user
is
`
user
`
and
the
default
password
will
be
randomly
generated
and
displayed
in
the
log
output
.
If
your
application
is
using
Spring
Security
,
the
shell
will
use
<<
boot
-
features
-
security
,
the
same
configuration
>>
by
default
.
If
not
,
a
simple
authentication
will
be
applied
and
you
should
see
a
message
like
this
:
[
indent
=
0
]
----
Using
default
password
for
shell
access
:
ec03e16c
-
4
cf4
-
49
ee
-
b745
-
7
c8255c1dd7e
----
Linux
and
OSX
users
can
use
`
ssh
`
to
connect
to
the
remote
shell
,
Windows
users
can
download
and
install
http
://
www
.
putty
.
org
/[
PuTTY
].
[
indent
=
0
,
subs
=
"attributes"
]
----
$
ssh
-
p
2000
user
@
localhost
user
@
localhost
's password:
. ____ _ __ _ _
/\\ / ___'
_
__
_
_
(
_
)
_
__
__
_
\
\
\
\
(
(
)\
___
|
'_ | '
_
|
|
'_ \/ _` | \ \ \ \
\\/ ___)| |_)| | | | | || (_| | ) ) ) )
'
|
____
|
.
__
|
_
|
|
_
|
_
|
|
_
\
__
,
|
/
/
/
/
=========|
_
|==============|
___
/=/
_
/
_
/
_
/
::
Spring
Boot
::
(
v
{
spring
-
boot
-
version
})
on
myhost
----
Type
`
help
`
for
a
list
of
commands
.
Spring
Boot
provides
`
metrics
`,
`
beans
`,
`
autoconfig
`
and
`
endpoint
`
commands
.
[[
production
-
ready
-
remote
-
shell
-
credentials
]]
====
Remote
shell
credentials
You
can
use
the
`
management
.
shell
.
auth
.
simple
.
user
.
name
`
and
`
management
.
shell
.
auth
.
simple
.
user
.
password
`
properties
to
configure
custom
connection
credentials
.
It
is
also
possible
to
use
a
'`Spring Security`'
`
AuthenticationManager
`
to
handle
login
duties
.
See
the
{
dc
-
spring
-
boot
-
actuator
}/
autoconfigure
/
CrshAutoConfiguration
.{
dc
-
ext
}[`
CrshAutoConfiguration
`]
and
{
dc
-
spring
-
boot
-
actuator
}/
autoconfigure
/
ShellProperties
.{
dc
-
ext
}[`
ShellProperties
`]
Javadoc
for
full
details
.
[[
production
-
ready
-
extending
-
the
-
remote
-
shell
]]
===
Extending
the
remote
shell
The
remote
shell
can
be
extended
in
a
number
of
interesting
ways
.
[[
production
-
ready
-
remote
-
commands
]]
====
Remote
shell
commands
You
can
write
additional
shell
commands
using
Groovy
or
Java
(
see
the
CRaSH
documentation
for
details
).
By
default
Spring
Boot
will
search
for
commands
in
the
following
locations
:
*
`+
classpath
*:/
commands
/**+`
*
`+
classpath
*:/
crash
/
commands
/**+`
TIP
:
You
can
change
the
search
path
by
settings
a
`
shell
.
command
-
path
-
patterns
`
property
.
NOTE
:
If
you
are
using
an
executable
archive
,
any
classes
that
a
shell
command
depends
upon
must
be
packaged
in
a
nested
jar
rather
than
directly
in
the
executable
jar
or
war
.
Here
is
a
simple
'`hello`'
command
that
could
be
loaded
from
`
src
/
main
/
resources
/
commands
/
hello
.
groovy
`
[
source
,
groovy
,
indent
=
0
]
----
package
commands
import
org
.
crsh
.
cli
.
Command
import
org
.
crsh
.
cli
.
Usage
import
org
.
crsh
.
command
.
InvocationContext
class
hello
{
@
Usage
(
"Say Hello"
)
@
Command
def
main
(
InvocationContext
context
)
{
return
"Hello"
}
}
----
Spring
Boot
adds
some
additional
attributes
to
`
InvocationContext
`
that
you
can
access
from
your
command
:
[
cols
=
"2,3"
]
|===
|
Attribute
Name
|
Description
|`
spring
.
boot
.
version
`
|
The
version
of
Spring
Boot
|`
spring
.
version
`
|
The
version
of
the
core
Spring
Framework
|`
spring
.
beanfactory
`
|
Access
to
the
Spring
`
BeanFactory
`
|`
spring
.
environment
`
|
Access
to
the
Spring
`
Environment
`
|===
[[
production
-
ready
-
remote
-
shell
-
plugins
]]
====
Remote
shell
plugins
In
addition
to
new
commands
,
it
is
also
possible
to
extend
other
CRaSH
shell
features
.
All
Spring
Beans
that
extend
`
org
.
crsh
.
plugin
.
CRaSHPlugin
`
will
be
automatically
registered
with
the
shell
.
For
more
information
please
refer
to
the
http
://
www
.
crashub
.
org
/[
CRaSH
reference
documentation
].
[[production-ready-metrics]]
[[production-ready-metrics]]
== Metrics
== Metrics
Spring Boot Actuator includes a metrics service with '`gauge`' and '`counter`' support.
Spring Boot Actuator includes a metrics service with '`gauge`' and '`counter`' support.
...
...
spring-boot-docs/src/main/groovy/generateStarterTables.groovy
View file @
c5cc626d
...
@@ -29,7 +29,7 @@ boolean isTechnicalStarter(def starter) {
...
@@ -29,7 +29,7 @@ boolean isTechnicalStarter(def starter) {
}
}
boolean
isProductionStarter
(
def
starter
)
{
boolean
isProductionStarter
(
def
starter
)
{
starter
.
name
in
[
'spring-boot-starter-actuator'
,
'spring-boot-starter-remote-shell'
]
starter
.
name
in
[
'spring-boot-starter-actuator'
]
}
}
boolean
isStarter
(
def
dependencies
)
{
boolean
isStarter
(
def
dependencies
)
{
...
...
spring-boot-samples/spring-boot-sample-actuator-log4j2/src/main/resources/application.properties
View file @
c5cc626d
...
@@ -2,14 +2,6 @@
...
@@ -2,14 +2,6 @@
#server.port=8080
#server.port=8080
#management.port=8080
#management.port=8080
management.address
=
127.0.0.1
management.address
=
127.0.0.1
management.shell.ssh.enabled
=
true
management.shell.ssh.port
=
2222
#management.shell.telnet.enabled=false
#management.shell.telnet.port=1111
management.shell.auth.type
=
spring
#management.shell.auth.type=key
#management.shell.auth.key.path=${user.home}/test/id_rsa.pub.pem
#management.shell.auth.type=simple
endpoints.shutdown.enabled
=
true
endpoints.shutdown.enabled
=
true
server.tomcat.basedir
=
target/tomcat
server.tomcat.basedir
=
target/tomcat
...
...
spring-boot-samples/spring-boot-sample-actuator-noweb/pom.xml
View file @
c5cc626d
...
@@ -23,10 +23,6 @@
...
@@ -23,10 +23,6 @@
<groupId>
org.springframework.boot
</groupId>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-actuator
</artifactId>
<artifactId>
spring-boot-starter-actuator
</artifactId>
</dependency>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-remote-shell
</artifactId>
</dependency>
<dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-test
</artifactId>
<artifactId>
spring-boot-starter-test
</artifactId>
...
...
spring-boot-samples/spring-boot-sample-actuator-noweb/src/main/resources/application.properties
View file @
c5cc626d
service.name
=
Phil
service.name
=
Phil
management.shell.ssh.enabled
=
true
management.shell.ssh.port
=
2222
management.shell.auth.type
=
simple
management.shell.auth.simple.user.password
=
password
spring-boot-samples/spring-boot-sample-actuator/pom.xml
View file @
c5cc626d
...
@@ -35,10 +35,6 @@
...
@@ -35,10 +35,6 @@
<groupId>
org.springframework.boot
</groupId>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-jdbc
</artifactId>
<artifactId>
spring-boot-starter-jdbc
</artifactId>
</dependency>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-remote-shell
</artifactId>
</dependency>
<dependency>
<dependency>
<groupId>
com.h2database
</groupId>
<groupId>
com.h2database
</groupId>
<artifactId>
h2
</artifactId>
<artifactId>
h2
</artifactId>
...
@@ -48,20 +44,6 @@
...
@@ -48,20 +44,6 @@
<artifactId>
spring-boot-starter-test
</artifactId>
<artifactId>
spring-boot-starter-test
</artifactId>
<scope>
test
</scope>
<scope>
test
</scope>
</dependency>
</dependency>
<!-- <dependency>
<groupId>org.crashub</groupId>
<artifactId>crash.connectors.telnet</artifactId>
<exclusions>
<exclusion>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
</exclusion>
<exclusion>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
</exclusion>
</exclusions>
</dependency> -->
</dependencies>
</dependencies>
<build>
<build>
<plugins>
<plugins>
...
...
spring-boot-samples/spring-boot-sample-actuator/src/main/resources/application.properties
View file @
c5cc626d
...
@@ -2,14 +2,6 @@
...
@@ -2,14 +2,6 @@
# logging.level.org.springframework.security=DEBUG
# logging.level.org.springframework.security=DEBUG
management.address
=
127.0.0.1
management.address
=
127.0.0.1
#management.port=8181
#management.port=8181
management.shell.ssh.enabled
=
true
management.shell.ssh.port
=
2222
#management.shell.telnet.enabled=false
#management.shell.telnet.port=1111
management.shell.auth.type
=
spring
#management.shell.auth.type=key
#management.shell.auth.key.path=${user.home}/test/id_rsa.pub.pem
#management.shell.auth.type=simple
management.info.build.mode
=
full
management.info.build.mode
=
full
...
...
spring-boot-starters/pom.xml
View file @
c5cc626d
...
@@ -60,7 +60,6 @@
...
@@ -60,7 +60,6 @@
<module>
spring-boot-starter-social-facebook
</module>
<module>
spring-boot-starter-social-facebook
</module>
<module>
spring-boot-starter-social-twitter
</module>
<module>
spring-boot-starter-social-twitter
</module>
<module>
spring-boot-starter-social-linkedin
</module>
<module>
spring-boot-starter-social-linkedin
</module>
<module>
spring-boot-starter-remote-shell
</module>
<module>
spring-boot-starter-test
</module>
<module>
spring-boot-starter-test
</module>
<module>
spring-boot-starter-thymeleaf
</module>
<module>
spring-boot-starter-thymeleaf
</module>
<module>
spring-boot-starter-tomcat
</module>
<module>
spring-boot-starter-tomcat
</module>
...
...
spring-boot-starters/spring-boot-starter-remote-shell/pom.xml
deleted
100644 → 0
View file @
66a3df45
<?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>
<parent>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starters
</artifactId>
<version>
2.0.0.BUILD-SNAPSHOT
</version>
</parent>
<artifactId>
spring-boot-starter-remote-shell
</artifactId>
<name>
spring-boot-starter-remote-shell (DEPRECATED)
</name>
<description>
Starter for using the CRaSH remote shell to monitor and manage your
application over SSH. Deprecated since 1.5
</description>
<url>
http://projects.spring.io/spring-boot/
</url>
<organization>
<name>
Pivotal Software, Inc.
</name>
<url>
http://www.spring.io
</url>
</organization>
<properties>
<main.basedir>
${basedir}/../..
</main.basedir>
</properties>
<dependencies>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter
</artifactId>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter-actuator
</artifactId>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.cli
</artifactId>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.connectors.ssh
</artifactId>
<exclusions>
<exclusion>
<groupId>
org.codehaus.groovy
</groupId>
<artifactId>
groovy-all
</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.connectors.telnet
</artifactId>
<exclusions>
<exclusion>
<groupId>
javax.servlet
</groupId>
<artifactId>
servlet-api
</artifactId>
</exclusion>
<exclusion>
<groupId>
log4j
</groupId>
<artifactId>
log4j
</artifactId>
</exclusion>
<exclusion>
<groupId>
commons-logging
</groupId>
<artifactId>
commons-logging
</artifactId>
</exclusion>
</exclusions>
<optional>
true
</optional>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.embed.spring
</artifactId>
<exclusions>
<exclusion>
<artifactId>
spring-web
</artifactId>
<groupId>
org.springframework
</groupId>
</exclusion>
<exclusion>
<groupId>
org.codehaus.groovy
</groupId>
<artifactId>
groovy-all
</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.plugins.cron
</artifactId>
<exclusions>
<exclusion>
<groupId>
org.codehaus.groovy
</groupId>
<artifactId>
groovy-all
</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.plugins.mail
</artifactId>
<exclusions>
<exclusion>
<groupId>
org.codehaus.groovy
</groupId>
<artifactId>
groovy-all
</artifactId>
</exclusion>
<exclusion>
<groupId>
javax.mail
</groupId>
<artifactId>
mail
</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>
org.crashub
</groupId>
<artifactId>
crash.shell
</artifactId>
<exclusions>
<exclusion>
<groupId>
org.codehaus.groovy
</groupId>
<artifactId>
groovy-all
</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>
org.codehaus.groovy
</groupId>
<artifactId>
groovy
</artifactId>
</dependency>
<dependency>
<groupId>
com.sun.mail
</groupId>
<artifactId>
javax.mail
</artifactId>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>
org.basepom.maven
</groupId>
<artifactId>
duplicate-finder-maven-plugin
</artifactId>
<executions>
<execution>
<id>
duplicate-dependencies
</id>
<phase>
validate
</phase>
<goals>
<goal>
check
</goal>
</goals>
<configuration>
<ignoredResourcePatterns>
<ignoredResourcePattern>
crash/crash.properties
</ignoredResourcePattern>
</ignoredResourcePatterns>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>
spring-boot-starters/spring-boot-starter-remote-shell/src/main/java/org/springframework/boot/starter/remote/shell/RemoteShellStarterDeprecatedWarningAutoConfiguration.java
deleted
100644 → 0
View file @
66a3df45
/*
* Copyright 2012-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
.
boot
.
starter
.
remote
.
shell
;
import
javax.annotation.PostConstruct
;
import
org.apache.commons.logging.Log
;
import
org.apache.commons.logging.LogFactory
;
import
org.springframework.boot.autoconfigure.EnableAutoConfiguration
;
import
org.springframework.context.annotation.Configuration
;
/**
* {@link EnableAutoConfiguration Auto-configuration} to print a deprecation warning about
* the starter.
*
* @author Stephane Nicoll
* @since 1.4.0
*/
@Configuration
@Deprecated
public
class
RemoteShellStarterDeprecatedWarningAutoConfiguration
{
private
static
final
Log
logger
=
LogFactory
.
getLog
(
RemoteShellStarterDeprecatedWarningAutoConfiguration
.
class
);
@PostConstruct
public
void
logWarning
()
{
logger
.
warn
(
"spring-boot-starter-remote-shell is deprecated since Spring Boot "
+
"1.5 and will be removed in Spring Boot 2.0"
);
}
}
spring-boot-starters/spring-boot-starter-remote-shell/src/main/resources/META-INF/spring.factories
deleted
100644 → 0
View file @
66a3df45
org.springframework.boot.autoconfigure.EnableAutoConfiguration=\
org.springframework.boot.starter.remote.shell.RemoteShellStarterDeprecatedWarningAutoConfiguration
\ No newline at end of file
spring-boot-starters/spring-boot-starter-remote-shell/src/main/resources/META-INF/spring.provides
deleted
100644 → 0
View file @
66a3df45
provides: crash.cli,crash.shell,crash.plugins.cron,crash.embed.spring,crash.connectors.ssh
\ No newline at end of file
spring-boot-starters/spring-boot-starter-remote-shell/src/main/resources/commands/crash/autoconfig.groovy
deleted
100644 → 0
View file @
66a3df45
package
commands
import
org.springframework.boot.actuate.endpoint.AutoConfigurationReportEndpoint
class
autoconfig
{
@Usage
(
"Display auto configuration report from ApplicationContext"
)
@Command
void
main
(
InvocationContext
context
)
{
context
.
attributes
[
'spring.beanfactory'
].
getBeansOfType
(
AutoConfigurationReportEndpoint
.
class
).
each
{
name
,
endpoint
->
def
report
=
endpoint
.
invoke
()
out
.
println
"Endpoint: "
+
name
+
"\n\nPositive Matches:\n================\n"
report
.
positiveMatches
.
each
{
key
,
list
->
out
.
println
key
+
":"
list
.
each
{
mandc
->
out
.
println
" "
+
mandc
.
condition
+
": "
+
mandc
.
message
}
}
out
.
println
"\nNegative Matches\n================\n"
report
.
negativeMatches
.
each
{
key
,
list
->
out
.
println
key
+
":"
list
.
each
{
mandc
->
out
.
println
" "
+
mandc
.
condition
+
": "
+
mandc
.
message
}
}
}
}
}
\ No newline at end of file
spring-boot-starters/spring-boot-starter-remote-shell/src/main/resources/commands/crash/beans.groovy
deleted
100644 → 0
View file @
66a3df45
package
commands
import
org.springframework.boot.actuate.endpoint.BeansEndpoint
class
beans
{
@Usage
(
"Display beans in ApplicationContext"
)
@Command
def
main
(
InvocationContext
context
)
{
def
result
=
[:]
context
.
attributes
[
'spring.beanfactory'
].
getBeansOfType
(
BeansEndpoint
.
class
).
each
{
name
,
endpoint
->
result
.
put
(
name
,
endpoint
.
invoke
())
}
result
.
size
()
==
1
?
result
.
values
()[
0
]
:
result
}
}
\ No newline at end of file
spring-boot-starters/spring-boot-starter-remote-shell/src/main/resources/commands/crash/endpoint.groovy
deleted
100644 → 0
View file @
66a3df45
package
commands
import
org.springframework.boot.actuate.endpoint.Endpoint
import
org.springframework.boot.actuate.endpoint.jmx.*
@Usage
(
"Invoke actuator endpoints"
)
class
endpoint
{
@Usage
(
"List all available and enabled actuator endpoints"
)
@Command
def
list
(
InvocationContext
context
)
{
context
.
attributes
[
'spring.beanfactory'
].
getBeansOfType
(
Endpoint
.
class
).
each
{
name
,
endpoint
->
if
(
endpoint
.
isEnabled
())
{
out
.
println
name
}
}
""
}
@Usage
(
"Invoke provided actuator endpoint"
)
@Command
def
invoke
(
InvocationContext
context
,
@Usage
(
"The name of the Endpoint to invoke"
)
@Required
@Argument
String
name
)
{
// Don't require passed argument to end with 'Endpoint'
if
(!
name
.
endsWith
(
"Endpoint"
))
{
name
=
name
+
"Endpoint"
}
context
.
attributes
[
'spring.beanfactory'
].
getBeansOfType
(
Endpoint
.
class
).
each
{
n
,
endpoint
->
if
(
n
.
equals
(
name
)
&&
endpoint
.
isEnabled
())
{
EndpointMBean
mbean
=
context
.
attributes
[
'spring.beanfactory'
].
getBean
(
EndpointMBeanExporter
.
class
).
getEndpointMBean
(
name
,
endpoint
)
if
(
mbean
instanceof
DataEndpointMBean
)
{
out
.
println
mbean
.
getData
()
}
else
{
out
.
println
mbean
.
endpoint
.
invoke
()
}
}
}
""
}
}
spring-boot-starters/spring-boot-starter-remote-shell/src/main/resources/commands/crash/login.groovy
deleted
100644 → 0
View file @
66a3df45
welcome
=
{
->
def
environment
=
crash
.
context
.
attributes
[
'spring.environment'
]
def
propertyResolver
=
new
org
.
springframework
.
boot
.
bind
.
RelaxedPropertyResolver
(
environment
,
"spring.main."
);
def
beanFactory
=
crash
.
context
.
attributes
[
'spring.beanfactory'
]
if
(!
propertyResolver
.
getProperty
(
"show-banner"
,
Boolean
.
class
,
Boolean
.
TRUE
))
{
return
""
}
// Try to print using the banner interface
if
(
beanFactory
!=
null
)
{
try
{
def
banner
=
beanFactory
.
getBean
(
"springBootBanner"
)
def
out
=
new
java
.
io
.
ByteArrayOutputStream
()
banner
.
printBanner
(
environment
,
null
,
new
java
.
io
.
PrintStream
(
out
))
return
out
.
toString
()
}
catch
(
Exception
ex
)
{
// Ignore
}
}
// Resolve hostname
def
hostName
;
try
{
hostName
=
java
.
net
.
InetAddress
.
getLocalHost
().
getHostName
();
}
catch
(
java
.
net
.
UnknownHostException
ignore
)
{
hostName
=
"localhost"
;
}
// Get Spring Boot version from context
def
version
=
crash
.
context
.
attributes
.
get
(
"spring.boot.version"
)
return
"""\
. ____ _ __ _ _
/\\\\ / ___'_ __ _ _(_)_ __ __ _ \\ \\ \\ \\
( ( )\\___ | '_ | '_| | '_ \\/ _` | \\ \\ \\ \\
\\\\/ ___)| |_)| | | | | || (_| | ) ) ) )
' |____| .__|_| |_|_| |_\\__, | / / / /
=========|_|==============|___/=/_/_/_/
:: Spring Boot :: (v$version) on $hostName
"""
;
}
prompt
=
{
->
return
"> "
;
}
spring-boot-starters/spring-boot-starter-remote-shell/src/main/resources/commands/crash/metrics.groovy
deleted
100644 → 0
View file @
66a3df45
package
commands
import
org.crsh.text.ui.UIBuilder
import
org.springframework.boot.actuate.endpoint.MetricsEndpoint
class
metrics
{
@Usage
(
"Display metrics provided by Spring Boot"
)
@Command
public
void
main
(
InvocationContext
context
)
{
context
.
takeAlternateBuffer
();
try
{
while
(!
Thread
.
interrupted
())
{
out
.
cls
()
out
.
show
(
new
UIBuilder
().
table
(
columns:
[
1
])
{
header
{
table
(
columns:
[
1
],
separator:
dashed
)
{
header
(
bold:
true
,
fg:
black
,
bg:
white
)
{
label
(
"metrics"
);
}
}
}
row
{
table
(
columns:
[
1
,
1
])
{
header
(
bold:
true
,
fg:
black
,
bg:
white
)
{
label
(
"NAME"
)
label
(
"VALUE"
)
}
context
.
attributes
[
'spring.beanfactory'
].
getBeansOfType
(
MetricsEndpoint
.
class
).
each
{
name
,
metrics
->
metrics
.
invoke
().
each
{
k
,
v
->
row
{
label
(
k
)
label
(
v
)
}
}
}
}
}
}
);
out
.
flush
();
Thread
.
sleep
(
1000
);
}
}
finally
{
context
.
releaseAlternateBuffer
();
}
}
}
\ No newline at end of file
spring-boot/src/main/java/org/springframework/boot/logging/logback/DefaultLogbackConfiguration.java
View file @
c5cc626d
/*
/*
* Copyright 2012-201
5
the original author or authors.
* Copyright 2012-201
6
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.
...
@@ -101,12 +101,8 @@ class DefaultLogbackConfiguration {
...
@@ -101,12 +101,8 @@ class DefaultLogbackConfiguration {
config
.
logger
(
"org.apache.coyote.http11.Http11NioProtocol"
,
Level
.
WARN
);
config
.
logger
(
"org.apache.coyote.http11.Http11NioProtocol"
,
Level
.
WARN
);
config
.
logger
(
"org.apache.sshd.common.util.SecurityUtils"
,
Level
.
WARN
);
config
.
logger
(
"org.apache.sshd.common.util.SecurityUtils"
,
Level
.
WARN
);
config
.
logger
(
"org.apache.tomcat.util.net.NioSelectorPool"
,
Level
.
WARN
);
config
.
logger
(
"org.apache.tomcat.util.net.NioSelectorPool"
,
Level
.
WARN
);
config
.
logger
(
"org.crsh.plugin"
,
Level
.
WARN
);
config
.
logger
(
"org.crsh.ssh"
,
Level
.
WARN
);
config
.
logger
(
"org.eclipse.jetty.util.component.AbstractLifeCycle"
,
Level
.
ERROR
);
config
.
logger
(
"org.eclipse.jetty.util.component.AbstractLifeCycle"
,
Level
.
ERROR
);
config
.
logger
(
"org.hibernate.validator.internal.util.Version"
,
Level
.
WARN
);
config
.
logger
(
"org.hibernate.validator.internal.util.Version"
,
Level
.
WARN
);
config
.
logger
(
"org.springframework.boot.actuate.autoconfigure."
+
"CrshAutoConfiguration"
,
Level
.
WARN
);
config
.
logger
(
"org.springframework.boot.actuate.endpoint.jmx"
,
null
,
false
,
config
.
logger
(
"org.springframework.boot.actuate.endpoint.jmx"
,
null
,
false
,
debugRemapAppender
);
debugRemapAppender
);
config
.
logger
(
"org.thymeleaf"
,
null
,
false
,
debugRemapAppender
);
config
.
logger
(
"org.thymeleaf"
,
null
,
false
,
debugRemapAppender
);
...
...
spring-boot/src/main/resources/org/springframework/boot/logging/java/logging-file.properties
View file @
c5cc626d
...
@@ -13,7 +13,6 @@ java.util.logging.ConsoleHandler.level = ALL
...
@@ -13,7 +13,6 @@ java.util.logging.ConsoleHandler.level = ALL
org.hibernate.validator.internal.util.Version.level
=
WARNING
org.hibernate.validator.internal.util.Version.level
=
WARNING
org.apache.coyote.http11.Http11NioProtocol.level
=
WARNING
org.apache.coyote.http11.Http11NioProtocol.level
=
WARNING
org.crsh.plugin.level
=
WARNING
org.apache.tomcat.util.net.NioSelectorPool.level
=
WARNING
org.apache.tomcat.util.net.NioSelectorPool.level
=
WARNING
org.apache.catalina.startup.DigesterFactory.level
=
SEVERE
org.apache.catalina.startup.DigesterFactory.level
=
SEVERE
org.apache.catalina.util.LifecycleBase.level
=
SEVERE
org.apache.catalina.util.LifecycleBase.level
=
SEVERE
...
...
spring-boot/src/main/resources/org/springframework/boot/logging/java/logging.properties
View file @
c5cc626d
...
@@ -6,7 +6,6 @@ java.util.logging.ConsoleHandler.level = ALL
...
@@ -6,7 +6,6 @@ java.util.logging.ConsoleHandler.level = ALL
org.hibernate.validator.internal.util.Version.level
=
WARNING
org.hibernate.validator.internal.util.Version.level
=
WARNING
org.apache.coyote.http11.Http11NioProtocol.level
=
WARNING
org.apache.coyote.http11.Http11NioProtocol.level
=
WARNING
org.crsh.plugin.level
=
WARNING
org.apache.tomcat.util.net.NioSelectorPool.level
=
WARNING
org.apache.tomcat.util.net.NioSelectorPool.level
=
WARNING
org.apache.catalina.startup.DigesterFactory.level
=
SEVERE
org.apache.catalina.startup.DigesterFactory.level
=
SEVERE
org.apache.catalina.util.LifecycleBase.level
=
SEVERE
org.apache.catalina.util.LifecycleBase.level
=
SEVERE
...
...
spring-boot/src/main/resources/org/springframework/boot/logging/log4j2/log4j2-file.xml
View file @
c5cc626d
...
@@ -25,11 +25,8 @@
...
@@ -25,11 +25,8 @@
<Logger
name=
"org.apache.coyote.http11.Http11NioProtocol"
level=
"warn"
/>
<Logger
name=
"org.apache.coyote.http11.Http11NioProtocol"
level=
"warn"
/>
<logger
name=
"org.apache.sshd.common.util.SecurityUtils"
level=
"warn"
/>
<logger
name=
"org.apache.sshd.common.util.SecurityUtils"
level=
"warn"
/>
<Logger
name=
"org.apache.tomcat.util.net.NioSelectorPool"
level=
"warn"
/>
<Logger
name=
"org.apache.tomcat.util.net.NioSelectorPool"
level=
"warn"
/>
<Logger
name=
"org.crsh.plugin"
level=
"warn"
/>
<logger
name=
"org.crsh.ssh"
level=
"warn"
/>
<Logger
name=
"org.eclipse.jetty.util.component.AbstractLifeCycle"
level=
"error"
/>
<Logger
name=
"org.eclipse.jetty.util.component.AbstractLifeCycle"
level=
"error"
/>
<Logger
name=
"org.hibernate.validator.internal.util.Version"
level=
"warn"
/>
<Logger
name=
"org.hibernate.validator.internal.util.Version"
level=
"warn"
/>
<logger
name=
"org.springframework.boot.actuate.autoconfigure.CrshAutoConfiguration"
level=
"warn"
/>
<logger
name=
"org.springframework.boot.actuate.endpoint.jmx"
level=
"warn"
/>
<logger
name=
"org.springframework.boot.actuate.endpoint.jmx"
level=
"warn"
/>
<logger
name=
"org.thymeleaf"
level=
"warn"
/>
<logger
name=
"org.thymeleaf"
level=
"warn"
/>
<Root
level=
"info"
>
<Root
level=
"info"
>
...
...
spring-boot/src/main/resources/org/springframework/boot/logging/log4j2/log4j2.xml
View file @
c5cc626d
...
@@ -17,11 +17,8 @@
...
@@ -17,11 +17,8 @@
<Logger
name=
"org.apache.coyote.http11.Http11NioProtocol"
level=
"warn"
/>
<Logger
name=
"org.apache.coyote.http11.Http11NioProtocol"
level=
"warn"
/>
<logger
name=
"org.apache.sshd.common.util.SecurityUtils"
level=
"warn"
/>
<logger
name=
"org.apache.sshd.common.util.SecurityUtils"
level=
"warn"
/>
<Logger
name=
"org.apache.tomcat.util.net.NioSelectorPool"
level=
"warn"
/>
<Logger
name=
"org.apache.tomcat.util.net.NioSelectorPool"
level=
"warn"
/>
<Logger
name=
"org.crsh.plugin"
level=
"warn"
/>
<logger
name=
"org.crsh.ssh"
level=
"warn"
/>
<Logger
name=
"org.eclipse.jetty.util.component.AbstractLifeCycle"
level=
"error"
/>
<Logger
name=
"org.eclipse.jetty.util.component.AbstractLifeCycle"
level=
"error"
/>
<Logger
name=
"org.hibernate.validator.internal.util.Version"
level=
"warn"
/>
<Logger
name=
"org.hibernate.validator.internal.util.Version"
level=
"warn"
/>
<logger
name=
"org.springframework.boot.actuate.autoconfigure.CrshAutoConfiguration"
level=
"warn"
/>
<logger
name=
"org.springframework.boot.actuate.endpoint.jmx"
level=
"warn"
/>
<logger
name=
"org.springframework.boot.actuate.endpoint.jmx"
level=
"warn"
/>
<logger
name=
"org.thymeleaf"
level=
"warn"
/>
<logger
name=
"org.thymeleaf"
level=
"warn"
/>
<Root
level=
"info"
>
<Root
level=
"info"
>
...
...
spring-boot/src/main/resources/org/springframework/boot/logging/logback/defaults.xml
View file @
c5cc626d
...
@@ -21,11 +21,8 @@ initialization performed by Boot
...
@@ -21,11 +21,8 @@ initialization performed by Boot
<logger
name=
"org.apache.coyote.http11.Http11NioProtocol"
level=
"WARN"
/>
<logger
name=
"org.apache.coyote.http11.Http11NioProtocol"
level=
"WARN"
/>
<logger
name=
"org.apache.sshd.common.util.SecurityUtils"
level=
"WARN"
/>
<logger
name=
"org.apache.sshd.common.util.SecurityUtils"
level=
"WARN"
/>
<logger
name=
"org.apache.tomcat.util.net.NioSelectorPool"
level=
"WARN"
/>
<logger
name=
"org.apache.tomcat.util.net.NioSelectorPool"
level=
"WARN"
/>
<logger
name=
"org.crsh.plugin"
level=
"WARN"
/>
<logger
name=
"org.crsh.ssh"
level=
"WARN"
/>
<logger
name=
"org.eclipse.jetty.util.component.AbstractLifeCycle"
level=
"ERROR"
/>
<logger
name=
"org.eclipse.jetty.util.component.AbstractLifeCycle"
level=
"ERROR"
/>
<logger
name=
"org.hibernate.validator.internal.util.Version"
level=
"WARN"
/>
<logger
name=
"org.hibernate.validator.internal.util.Version"
level=
"WARN"
/>
<logger
name=
"org.springframework.boot.actuate.autoconfigure.CrshAutoConfiguration"
level=
"WARN"
/>
<logger
name=
"org.springframework.boot.actuate.endpoint.jmx"
additivity=
"false"
>
<logger
name=
"org.springframework.boot.actuate.endpoint.jmx"
additivity=
"false"
>
<appender-ref
ref=
"DEBUG_LEVEL_REMAPPER"
/>
<appender-ref
ref=
"DEBUG_LEVEL_REMAPPER"
/>
</logger>
</logger>
...
...
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