                       k (cond
                          (and (not= "http.connection-manager.timeout" k)
                               (instance? Long v)) (Integer. ^Long v)
-                              true v))))
+                              true v)))))
 
 
 (defn- coerce-body-entity

(defn add-client-params!
  "Add various client params to the http-client object, if needed."
  [http-client kvs]
  (doto http-client
    (set-client-param ClientPNames/COOKIE_POLICY
                      CookiePolicy/BROWSER_COMPATIBILITY)
    (set-client-param CookieSpecPNames/SINGLE_COOKIE_HEADER true)
    (set-client-param ClientPNames/HANDLE_REDIRECTS false))


           socket-timeout conn-timeout  ;; in milliseconds
           insecure? save-request? proxy-host proxy-port as cookie-store
           retry-handler response-interceptor digest-auth connection-manager
           client-params] :as req}]  
  (let [^ClientConnectionManager conn-mgr
        (or connection-manager
            conn/*connection-manager*
