Skip to content

Commit

Permalink
fix failing tests
Browse files Browse the repository at this point in the history
  • Loading branch information
graemerocher committed Mar 27, 2015
1 parent db90b75 commit 834cd77
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,14 +56,18 @@ class EventBusGrailsPlugin extends Plugin {
@Override
@CompileStatic
void doWithApplicationContext() {
Environment.assign applicationContext.getBean('reactorEnv', Environment)
if( !Environment.alive() ) {
Environment.assign applicationContext.getBean('reactorEnv', Environment)
}
}

@Override
@CompileStatic
void onShutdown(Map<String, Object> event) {
try {
Environment.terminate()
if( Environment.alive() ) {
Environment.terminate()
}
} catch (Throwable e) {
log.warn("Error shutting down Reactor: ${e.message}", e)
}
Expand Down

0 comments on commit 834cd77

Please sign in to comment.