Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Comment out log traces #193

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/toucan2/jdbc/read.clj
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
[_conn _model ^ResultSet rset _rsmeta ^Long i]
(log/debugf "Fetching values in column %s with %s" i (list '.getObject 'rs i))
(fn default-read-column-thunk []
(log/tracef "col %s => %s" i (list '.getObject 'rset i))
;; (log/tracef "col %s => %s" i (list '.getObject 'rset i))
(.getObject rset i)))

(m/defmethod read-column-thunk :after :default
Expand Down Expand Up @@ -98,7 +98,7 @@
;; from Criterium: a no-op call takes about 20ns locally. So 10m rows => 200ms from this no-op call. That's a little
;; expensive, but probably not as bad as the overhead we get from other nonsense here in Toucan 2. We'll have to do
;; some general performance tuning in the future.
(log/tracef "col %s => %s" i (list '.getObject 'rset i klass))
;; (log/tracef "col %s => %s" i (list '.getObject 'rset i klass))
(.getObject rset i klass)))

;;;; Default column read methods
Expand Down
6 changes: 3 additions & 3 deletions src/toucan2/jdbc/result_set.clj
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
(defrecord ^:no-doc InstanceBuilder [model ^ResultSet rset ^ResultSetMetaData rsmeta cols]
next.jdbc.rs/RowBuilder
(->row [_this]
(log/tracef "Fetching row %s" (.getRow rset))
;; (log/tracef "Fetching row %s" (.getRow rset))
(transient (instance/instance model)))

(column-count [_this]
Expand All @@ -54,7 +54,7 @@
(assoc! row col v))

(row! [_this row]
(log/tracef "Converting transient row to persistent row")
;; (log/tracef "Converting transient row to persistent row")
(persistent! row))

next.jdbc.rs/ResultSetBuilder
Expand Down Expand Up @@ -151,7 +151,7 @@
(log/tracef "Result set has no more rows.")
acc)

:let [_ (log/tracef "Fetch row %s" (.getRow rset))
:let [;; _ (log/tracef "Fetch row %s" (.getRow rset))
row (jdbc.row/row model rset builder i->thunk col-name->index)
acc' (rf acc row)]

Expand Down
4 changes: 2 additions & 2 deletions src/toucan2/jdbc/row.clj
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@
transient-row)))

(defn- fetch-all-columns! [builder i->thunk transient-row]
(log/tracef "Fetching all columns")
;; (log/tracef "Fetching all columns")
(let [n (next.jdbc.rs/column-count builder)]
(loop [i 1
transient-row transient-row]
Expand All @@ -340,7 +340,7 @@

(defn- make-realized-row-delay [builder i->thunk ^clojure.lang.Volatile volatile-transient-row]
(delay
(log/tracef "Fully realizing row. *fetch-all-columns* = %s" *fetch-all-columns*)
;; (log/tracef "Fully realizing row. *fetch-all-columns* = %s" *fetch-all-columns*)
(let [row (cond->> @volatile-transient-row
*fetch-all-columns* (fetch-all-columns! builder i->thunk))]
(next.jdbc.rs/row! builder row))))
Expand Down
Loading