Browse files

Fix Issue 77: RoutedStore.close should perhaps call shutdownNow if aw…

…aitTermination timeout expires.
  • Loading branch information...
1 parent f001fac commit e44ec88c57c1293a5b71598e0ad0fed403387744 @ijuma ijuma committed Mar 29, 2009
Showing with 2 additions and 1 deletion.
  1. +2 −1 src/java/voldemort/store/routed/RoutedStore.java
View
3 src/java/voldemort/store/routed/RoutedStore.java
@@ -530,7 +530,8 @@ private void markUnavailable(Node node, Exception e) {
public void close() {
this.executor.shutdown();
try {
- this.executor.awaitTermination(10, TimeUnit.SECONDS);
+ if(!this.executor.awaitTermination(10, TimeUnit.SECONDS))
+ this.executor.shutdownNow();
} catch(InterruptedException e) {
// okay, fine, playing nice didn't work
this.executor.shutdownNow();

0 comments on commit e44ec88

Please sign in to comment.