/*package*/
  TwitterStreamImpl(Configuration conf, Authorization auth) {
    super(conf, auth);
    http = HttpClientFactory.getInstance(new StreamingReadTimeoutConfiguration(conf));
    // turning off keepalive connection explicitly because Streaming API doesn't need keepalive
    // connection.
    // and this will reduce the shutdown latency of streaming api connection
    // see also - http://jira.twitter4j.org/browse/TFJ-556
    http.addDefaultRequestHeader("Connection", "close");

    stallWarningsGetParam = "stall_warnings=" + (conf.isStallWarningsEnabled() ? "true" : "false");
    stallWarningsParam = new HttpParameter("stall_warnings", conf.isStallWarningsEnabled());
  }
 /*package*/
 TwitterStreamImpl(Configuration conf, Authorization auth) {
   super(conf, auth);
   http = new HttpClientWrapper(new StreamingReadTimeoutConfiguration(conf));
   stallWarningsGetParam = "stall_warnings=" + (conf.isStallWarningsEnabled() ? "true" : "false");
   stallWarningsParam = new HttpParameter("stall_warnings", conf.isStallWarningsEnabled());
 }