         (System/setErr err)))))
 
 (defmacro with-logs
-  "Evaluates exprs in a context in which *out* and *err* write to the logger. The
-  specified log-ns value will be used to namespace all log entries.
+  "Evaluates exprs in a context in which *out* and *err* write to the log. The
+  specified logger-ns value will be used to namespace all log entries.
 
   By default *out* and *err* write to :info and :error, respectively."
-  {:arglists '([log-ns & body]
-               [[log-ns out-level err-level] & body])}
+  {:arglists '([logger-ns & body]
+               [[logger-ns out-level err-level] & body])}
   [arg & body]
   ; Implementation Notes:
   ; - no enabled? check before making writers since that may change later
-  (let [[log-ns out-level err-level] (if (vector? arg)
+  (let [[logger-ns out-level err-level] (if (vector? arg)
                                        arg
                                        [arg :info :error])]
-    (if (and log-ns (seq body))
+    (if (and logger-ns (seq body))
       `(binding [*out* (java.io.OutputStreamWriter.
-                         (log-stream ~out-level ~log-ns))
+                         (log-stream ~out-level ~logger-ns))
                  *err* (java.io.OutputStreamWriter.
-                         (log-stream ~err-level ~log-ns))]
+                         (log-stream ~err-level ~logger-ns))]
          ~@body))))
 
 

      monitor (Object.)] ; sync monitor for calling setOut/setErr
  (defn log-capture!
    "Captures System.out and System.err, piping all writes of those streams to
    the logger. If unspecified, levels default to :info and :error, respectively.
    The specified log-ns value will be used to namespace all log entries.

    Note: use with-logs to redirect output of *out* or *err*.

    Warning: if the logging implementation is configured to output to System.out
    (as is the default with java.util.logging) then using this function will
    result in StackOverflowException when writing to the logger."
    ; Implementation Notes:
    ; - only set orig when nil to preserve original out/err
    ; - no enabled? check before making streams since that may change later
    ([log-ns]
      (log-capture! log-ns :info :error))
    ([log-ns out-level err-level]
      (locking monitor
        (compare-and-set! orig nil [System/out System/err])
        (System/setOut  (log-stream out-level log-ns))
        (System/setErr (log-stream err-level log-ns)))))
  (defn log-uncapture!
    "Restores System.out and System.err to their original values."
    []

         (reify LoggerFactory
           (impl-name [_#]
             "org.apache.commons.logging")
           (impl-get-logger [_# logger-ns#]
             (org.apache.commons.logging.LogFactory/getLog (str logger-ns#))))))
    (catch Exception e nil)))

(defn slf4j-logging
