// For early closing mode add an output listener to the script session that calls the
// "wake me" method on whatever is putting us to sleep - if the client
// does not support streaming or streaming has not been configured.
if (!canWeHaveFullStreaming) {
int earlyCloseTimeout = (maxWaitAfterWrite == -1) ? ProtocolConstants.DEFAULT_MAX_WAIT_AFTER_WRITE : maxWaitAfterWrite;
alarms.add(new OutputAlarm(sleeper, scriptSession, earlyCloseTimeout, executor));
}
if (clientSupportsLongRequests)
{
// Nasty 2 connection limit hack. How many times is this browser connected?