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
4963cfd6
Commit
4963cfd6
authored
Jul 11, 2016
by
Andy Wilkinson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Reset thread's interrupted flag when catching InterruptedException
Closes gh-6360
parent
e53d3167
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
12 additions
and
7 deletions
+12
-7
ShutdownEndpoint.java
...ringframework/boot/actuate/endpoint/ShutdownEndpoint.java
+1
-1
RemoteSpringApplication.java
...pringframework/boot/devtools/RemoteSpringApplication.java
+1
-1
FileWatchingFailureHandler.java
...ot/devtools/autoconfigure/FileWatchingFailureHandler.java
+1
-1
FileSystemWatcher.java
...gframework/boot/devtools/filewatch/FileSystemWatcher.java
+1
-1
DelayedLiveReloadTrigger.java
...boot/devtools/remote/client/DelayedLiveReloadTrigger.java
+1
-1
TunnelClient.java
...ngframework/boot/devtools/tunnel/client/TunnelClient.java
+1
-1
HttpTunnelServer.java
...amework/boot/devtools/tunnel/server/HttpTunnelServer.java
+2
-1
RandomAccessDataFile.java
...pringframework/boot/loader/data/RandomAccessDataFile.java
+2
-0
StartMojo.java
...c/main/java/org/springframework/boot/maven/StartMojo.java
+2
-0
No files found.
spring-boot-actuator/src/main/java/org/springframework/boot/actuate/endpoint/ShutdownEndpoint.java
View file @
4963cfd6
...
@@ -66,7 +66,7 @@ public class ShutdownEndpoint extends AbstractEndpoint<Map<String, Object>>
...
@@ -66,7 +66,7 @@ public class ShutdownEndpoint extends AbstractEndpoint<Map<String, Object>>
Thread
.
sleep
(
500L
);
Thread
.
sleep
(
500L
);
}
}
catch
(
InterruptedException
ex
)
{
catch
(
InterruptedException
ex
)
{
// Swallow exception and continue
Thread
.
currentThread
().
interrupt
();
}
}
ShutdownEndpoint
.
this
.
context
.
close
();
ShutdownEndpoint
.
this
.
context
.
close
();
}
}
...
...
spring-boot-devtools/src/main/java/org/springframework/boot/devtools/RemoteSpringApplication.java
View file @
4963cfd6
...
@@ -91,7 +91,7 @@ public final class RemoteSpringApplication {
...
@@ -91,7 +91,7 @@ public final class RemoteSpringApplication {
Thread
.
sleep
(
1000
);
Thread
.
sleep
(
1000
);
}
}
catch
(
InterruptedException
ex
)
{
catch
(
InterruptedException
ex
)
{
// Ignore
Thread
.
currentThread
().
interrupt
();
}
}
}
}
}
}
...
...
spring-boot-devtools/src/main/java/org/springframework/boot/devtools/autoconfigure/FileWatchingFailureHandler.java
View file @
4963cfd6
...
@@ -52,7 +52,7 @@ class FileWatchingFailureHandler implements FailureHandler {
...
@@ -52,7 +52,7 @@ class FileWatchingFailureHandler implements FailureHandler {
latch
.
await
();
latch
.
await
();
}
}
catch
(
InterruptedException
ex
)
{
catch
(
InterruptedException
ex
)
{
// Ignore
Thread
.
currentThread
().
interrupt
();
}
}
return
Outcome
.
RETRY
;
return
Outcome
.
RETRY
;
}
}
...
...
spring-boot-devtools/src/main/java/org/springframework/boot/devtools/filewatch/FileSystemWatcher.java
View file @
4963cfd6
...
@@ -239,7 +239,7 @@ public class FileSystemWatcher {
...
@@ -239,7 +239,7 @@ public class FileSystemWatcher {
scan
();
scan
();
}
}
catch
(
InterruptedException
ex
)
{
catch
(
InterruptedException
ex
)
{
// Ignore
Thread
.
currentThread
().
interrupt
();
}
}
remainingScans
=
this
.
remainingScans
.
get
();
remainingScans
=
this
.
remainingScans
.
get
();
}
}
...
...
spring-boot-devtools/src/main/java/org/springframework/boot/devtools/remote/client/DelayedLiveReloadTrigger.java
View file @
4963cfd6
...
@@ -96,7 +96,7 @@ class DelayedLiveReloadTrigger implements Runnable {
...
@@ -96,7 +96,7 @@ class DelayedLiveReloadTrigger implements Runnable {
this
.
liveReloadServer
.
triggerReload
();
this
.
liveReloadServer
.
triggerReload
();
}
}
catch
(
InterruptedException
ex
)
{
catch
(
InterruptedException
ex
)
{
// Ignore
Thread
.
currentThread
().
interrupt
();
}
}
}
}
...
...
spring-boot-devtools/src/main/java/org/springframework/boot/devtools/tunnel/client/TunnelClient.java
View file @
4963cfd6
...
@@ -98,7 +98,7 @@ public class TunnelClient implements SmartInitializingSingleton {
...
@@ -98,7 +98,7 @@ public class TunnelClient implements SmartInitializingSingleton {
this
.
serverThread
.
join
(
2000
);
this
.
serverThread
.
join
(
2000
);
}
}
catch
(
InterruptedException
ex
)
{
catch
(
InterruptedException
ex
)
{
// Ignore
Thread
.
currentThread
().
interrupt
();
}
}
this
.
serverThread
=
null
;
this
.
serverThread
=
null
;
}
}
...
...
spring-boot-devtools/src/main/java/org/springframework/boot/devtools/tunnel/server/HttpTunnelServer.java
View file @
4963cfd6
...
@@ -273,6 +273,7 @@ public class HttpTunnelServer {
...
@@ -273,6 +273,7 @@ public class HttpTunnelServer {
this
.
httpConnections
.
wait
(
HttpTunnelServer
.
this
.
longPollTimeout
);
this
.
httpConnections
.
wait
(
HttpTunnelServer
.
this
.
longPollTimeout
);
}
}
catch
(
InterruptedException
ex
)
{
catch
(
InterruptedException
ex
)
{
Thread
.
currentThread
().
interrupt
();
closeHttpConnections
();
closeHttpConnections
();
}
}
httpConnection
=
this
.
httpConnections
.
pollFirst
();
httpConnection
=
this
.
httpConnections
.
pollFirst
();
...
@@ -442,7 +443,7 @@ public class HttpTunnelServer {
...
@@ -442,7 +443,7 @@ public class HttpTunnelServer {
}
}
}
}
catch
(
InterruptedException
ex
)
{
catch
(
InterruptedException
ex
)
{
// Ignore
Thread
.
currentThread
().
interrupt
();
}
}
}
}
}
}
...
...
spring-boot-tools/spring-boot-loader/src/main/java/org/springframework/boot/loader/data/RandomAccessDataFile.java
View file @
4963cfd6
...
@@ -252,6 +252,7 @@ public class RandomAccessDataFile implements RandomAccessData {
...
@@ -252,6 +252,7 @@ public class RandomAccessDataFile implements RandomAccessData {
:
file
);
:
file
);
}
}
catch
(
InterruptedException
ex
)
{
catch
(
InterruptedException
ex
)
{
Thread
.
currentThread
().
interrupt
();
throw
new
IOException
(
ex
);
throw
new
IOException
(
ex
);
}
}
}
}
...
@@ -276,6 +277,7 @@ public class RandomAccessDataFile implements RandomAccessData {
...
@@ -276,6 +277,7 @@ public class RandomAccessDataFile implements RandomAccessData {
}
}
}
}
catch
(
InterruptedException
ex
)
{
catch
(
InterruptedException
ex
)
{
Thread
.
currentThread
().
interrupt
();
throw
new
IOException
(
ex
);
throw
new
IOException
(
ex
);
}
}
}
}
...
...
spring-boot-tools/spring-boot-maven-plugin/src/main/java/org/springframework/boot/maven/StartMojo.java
View file @
4963cfd6
...
@@ -167,6 +167,7 @@ public class StartMojo extends AbstractRunMojo {
...
@@ -167,6 +167,7 @@ public class StartMojo extends AbstractRunMojo {
this
.
lock
.
wait
(
wait
);
this
.
lock
.
wait
(
wait
);
}
}
catch
(
InterruptedException
ex
)
{
catch
(
InterruptedException
ex
)
{
Thread
.
currentThread
().
interrupt
();
throw
new
IllegalStateException
(
throw
new
IllegalStateException
(
"Interrupted while waiting for Spring Boot app to start."
);
"Interrupted while waiting for Spring Boot app to start."
);
}
}
...
@@ -275,6 +276,7 @@ public class StartMojo extends AbstractRunMojo {
...
@@ -275,6 +276,7 @@ public class StartMojo extends AbstractRunMojo {
this
.
lock
.
wait
(
wait
);
this
.
lock
.
wait
(
wait
);
}
}
catch
(
InterruptedException
ex
)
{
catch
(
InterruptedException
ex
)
{
Thread
.
currentThread
().
interrupt
();
throw
new
IllegalStateException
(
throw
new
IllegalStateException
(
"Interrupted while waiting for Spring Boot app to start."
);
"Interrupted while waiting for Spring Boot app to start."
);
}
}
...
...
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