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
429eec0b
Commit
429eec0b
authored
Oct 22, 2019
by
Stephane Nicoll
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #18604 from wycm
* pr/18604: Optimize debug level logs Closes gh-18604
parents
91f4300f
681a94b0
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
19 additions
and
7 deletions
+19
-7
JobLauncherCommandLineRunner.java
...oot/autoconfigure/batch/JobLauncherCommandLineRunner.java
+6
-2
ArtemisEmbeddedConfigurationFactory.java
...gure/jms/artemis/ArtemisEmbeddedConfigurationFactory.java
+1
-1
Connection.java
.../springframework/boot/devtools/livereload/Connection.java
+6
-2
LiveReloadServer.java
...gframework/boot/devtools/livereload/LiveReloadServer.java
+3
-1
FailureAnalyzers.java
...rg/springframework/boot/diagnostics/FailureAnalyzers.java
+3
-1
No files found.
spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/batch/JobLauncherCommandLineRunner.java
View file @
429eec0b
...
@@ -174,7 +174,9 @@ public class JobLauncherCommandLineRunner implements CommandLineRunner, Ordered,
...
@@ -174,7 +174,9 @@ public class JobLauncherCommandLineRunner implements CommandLineRunner, Ordered,
if
(
StringUtils
.
hasText
(
this
.
jobNames
))
{
if
(
StringUtils
.
hasText
(
this
.
jobNames
))
{
String
[]
jobsToRun
=
this
.
jobNames
.
split
(
","
);
String
[]
jobsToRun
=
this
.
jobNames
.
split
(
","
);
if
(!
PatternMatchUtils
.
simpleMatch
(
jobsToRun
,
job
.
getName
()))
{
if
(!
PatternMatchUtils
.
simpleMatch
(
jobsToRun
,
job
.
getName
()))
{
logger
.
debug
(
"Skipped job: "
+
job
.
getName
());
if
(
logger
.
isDebugEnabled
())
{
logger
.
debug
(
"Skipped job: "
+
job
.
getName
());
}
continue
;
continue
;
}
}
}
}
...
@@ -194,7 +196,9 @@ public class JobLauncherCommandLineRunner implements CommandLineRunner, Ordered,
...
@@ -194,7 +196,9 @@ public class JobLauncherCommandLineRunner implements CommandLineRunner, Ordered,
execute
(
job
,
jobParameters
);
execute
(
job
,
jobParameters
);
}
}
catch
(
NoSuchJobException
ex
)
{
catch
(
NoSuchJobException
ex
)
{
logger
.
debug
(
"No job found in registry for job name: "
+
jobName
);
if
(
logger
.
isDebugEnabled
())
{
logger
.
debug
(
"No job found in registry for job name: "
+
jobName
);
}
}
}
}
}
}
}
...
...
spring-boot-project/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/jms/artemis/ArtemisEmbeddedConfigurationFactory.java
View file @
429eec0b
...
@@ -63,7 +63,7 @@ class ArtemisEmbeddedConfigurationFactory {
...
@@ -63,7 +63,7 @@ class ArtemisEmbeddedConfigurationFactory {
TransportConfiguration
transportConfiguration
=
new
TransportConfiguration
(
InVMAcceptorFactory
.
class
.
getName
(),
TransportConfiguration
transportConfiguration
=
new
TransportConfiguration
(
InVMAcceptorFactory
.
class
.
getName
(),
this
.
properties
.
generateTransportParameters
());
this
.
properties
.
generateTransportParameters
());
configuration
.
getAcceptorConfigurations
().
add
(
transportConfiguration
);
configuration
.
getAcceptorConfigurations
().
add
(
transportConfiguration
);
if
(
this
.
properties
.
isDefaultClusterPassword
())
{
if
(
this
.
properties
.
isDefaultClusterPassword
()
&&
logger
.
isDebugEnabled
()
)
{
logger
.
debug
(
"Using default Artemis cluster password: "
+
this
.
properties
.
getClusterPassword
());
logger
.
debug
(
"Using default Artemis cluster password: "
+
this
.
properties
.
getClusterPassword
());
}
}
configuration
.
setClusterPassword
(
this
.
properties
.
getClusterPassword
());
configuration
.
setClusterPassword
(
this
.
properties
.
getClusterPassword
());
...
...
spring-boot-project/spring-boot-devtools/src/main/java/org/springframework/boot/devtools/livereload/Connection.java
View file @
429eec0b
...
@@ -68,7 +68,9 @@ class Connection {
...
@@ -68,7 +68,9 @@ class Connection {
this
.
inputStream
=
new
ConnectionInputStream
(
inputStream
);
this
.
inputStream
=
new
ConnectionInputStream
(
inputStream
);
this
.
outputStream
=
new
ConnectionOutputStream
(
outputStream
);
this
.
outputStream
=
new
ConnectionOutputStream
(
outputStream
);
this
.
header
=
this
.
inputStream
.
readHeader
();
this
.
header
=
this
.
inputStream
.
readHeader
();
logger
.
debug
(
"Established livereload connection ["
+
this
.
header
+
"]"
);
if
(
logger
.
isDebugEnabled
())
{
logger
.
debug
(
"Established livereload connection ["
+
this
.
header
+
"]"
);
}
}
}
/**
/**
...
@@ -107,7 +109,9 @@ class Connection {
...
@@ -107,7 +109,9 @@ class Connection {
throw
new
ConnectionClosedException
();
throw
new
ConnectionClosedException
();
}
}
else
if
(
frame
.
getType
()
==
Frame
.
Type
.
TEXT
)
{
else
if
(
frame
.
getType
()
==
Frame
.
Type
.
TEXT
)
{
logger
.
debug
(
"Received LiveReload text frame "
+
frame
);
if
(
logger
.
isDebugEnabled
())
{
logger
.
debug
(
"Received LiveReload text frame "
+
frame
);
}
}
}
else
{
else
{
throw
new
IOException
(
"Unexpected Frame Type "
+
frame
.
getType
());
throw
new
IOException
(
"Unexpected Frame Type "
+
frame
.
getType
());
...
...
spring-boot-project/spring-boot-devtools/src/main/java/org/springframework/boot/devtools/livereload/LiveReloadServer.java
View file @
429eec0b
...
@@ -109,7 +109,9 @@ public class LiveReloadServer {
...
@@ -109,7 +109,9 @@ public class LiveReloadServer {
public
int
start
()
throws
IOException
{
public
int
start
()
throws
IOException
{
synchronized
(
this
.
monitor
)
{
synchronized
(
this
.
monitor
)
{
Assert
.
state
(!
isStarted
(),
"Server already started"
);
Assert
.
state
(!
isStarted
(),
"Server already started"
);
logger
.
debug
(
"Starting live reload server on port "
+
this
.
port
);
if
(
logger
.
isDebugEnabled
())
{
logger
.
debug
(
"Starting live reload server on port "
+
this
.
port
);
}
this
.
serverSocket
=
new
ServerSocket
(
this
.
port
);
this
.
serverSocket
=
new
ServerSocket
(
this
.
port
);
int
localPort
=
this
.
serverSocket
.
getLocalPort
();
int
localPort
=
this
.
serverSocket
.
getLocalPort
();
this
.
listenThread
=
this
.
threadFactory
.
newThread
(
this
::
acceptConnections
);
this
.
listenThread
=
this
.
threadFactory
.
newThread
(
this
::
acceptConnections
);
...
...
spring-boot-project/spring-boot/src/main/java/org/springframework/boot/diagnostics/FailureAnalyzers.java
View file @
429eec0b
...
@@ -113,7 +113,9 @@ final class FailureAnalyzers implements SpringBootExceptionReporter {
...
@@ -113,7 +113,9 @@ final class FailureAnalyzers implements SpringBootExceptionReporter {
}
}
}
}
catch
(
Throwable
ex
)
{
catch
(
Throwable
ex
)
{
logger
.
debug
(
"FailureAnalyzer "
+
analyzer
+
" failed"
,
ex
);
if
(
logger
.
isDebugEnabled
())
{
logger
.
debug
(
"FailureAnalyzer "
+
analyzer
+
" failed"
,
ex
);
}
}
}
}
}
return
null
;
return
null
;
...
...
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