Skip to content
This repository has been archived by the owner on Sep 18, 2021. It is now read-only.

Commit

Permalink
More clarifying comments
Browse files Browse the repository at this point in the history
  • Loading branch information
Raghavendra Prabhu committed Mar 23, 2012
1 parent 4a59a6a commit 3404caa
Showing 1 changed file with 4 additions and 0 deletions.
Expand Up @@ -70,6 +70,9 @@ extends AsyncDatabase {

future.within(checkoutTimer, openTimeout) rescue { e =>
e match {
// openTimeout elapsed. If our task has still not started, cancel it and return the
// exception. If not, rescue the exception with the original future, as if nothing
// happened.
case e: TimeoutException => {
val cancellable = startCoordinator.compareAndSet(true, false)
if (cancellable) {
Expand All @@ -81,6 +84,7 @@ extends AsyncDatabase {
}
}

// Any other exception - just propagate unchanged.
case _ => Future.exception(e)
}
}
Expand Down

0 comments on commit 3404caa

Please sign in to comment.