Skip to content
This repository has been archived by the owner on May 6, 2020. It is now read-only.

Commit

Permalink
RAYO-122 : Allow apps to skip Moho's default behaviour
Browse files Browse the repository at this point in the history
  • Loading branch information
mpermar committed Sep 19, 2013
1 parent 0fa7ae2 commit 2f5aa9a
Showing 1 changed file with 6 additions and 4 deletions.
@@ -1,8 +1,7 @@
package com.rayo.server;

import java.util.concurrent.TimeUnit;

import com.voxeo.moho.common.util.SettableResultFuture;
import com.voxeo.moho.event.AcceptableEvent;
import com.voxeo.moho.event.Event;
import com.voxeo.moho.event.EventSource;
import com.voxeo.moho.utils.EventListener;
Expand All @@ -27,7 +26,10 @@ public void handle(Response response) throws Exception {

actor.publish(request);

future.get(30, TimeUnit.SECONDS);

if (event instanceof AcceptableEvent) {
// MOHO-83 : Skip contention by setting async on moho level
((AcceptableEvent)event).setAsync(true);
}
}
}

0 comments on commit 2f5aa9a

Please sign in to comment.