Commit 1fe5eaf6 authored by ryszard.szopa's avatar ryszard.szopa
Browse files

now all connections made using with-class-collection are pooled.

darcs-hash:b8f0d3f420a76a6d38de1b255562b7c1424dfd33
parent d56db42c
......@@ -40,7 +40,7 @@
(defun with-object-connection-fun (object what-to-do)
"Functional interface to the macro WITH-OBJECT-CONNECTION."
(with-connection-fun (db-class-connection-spec (class-of object))
(with-class-connection-fun (class-of object)
what-to-do))
(defmacro with-object-connection ((object) &body body)
......@@ -51,8 +51,9 @@ specified by the DB-CLASS-CONNECTION-SPEC of the class of OBJECT."
(lambda () (progn ,@body))))
(defun with-class-connection-fun (class what-to-do)
"Functional interface to the macro WITH-CLASS-CONNECTION."
(with-connection-fun (append (db-class-connection-spec class) '(t))
"Functional interface to the macro WITH-CLASS-CONNECTION. the
connection will be pooled."
(with-connection-fun (append (db-class-connection-spec class) '(:pooled-p t))
what-to-do))
(defmacro with-class-connection ((class) &body body)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment