Re: OutOfMemoryError with clojure.contrib.sql and large result sets

2009-05-19 Thread Ian Eure
On May 15, 2009, at 3:34 PM, Stephen C. Gilardi wrote: On May 15, 2009, at 6:14 PM, Ian Eure wrote: I'm not having any luck at all. I tried visualvm, but it seems that it doesn't support memory profiling unless you're running JDK 6. I switched my default version (I'm on OS X here), and

Re: OutOfMemoryError with clojure.contrib.sql and large result sets

2009-05-18 Thread Mark Addleman
The problem is likely in the MySQL's JDBC driver. Some retrieve the entire result set from the database on statement execute while others are more true to the notion of a remote database cursor. The JDBC API has a workaround for this problem: Use Statement.setFetchSize(int) to limit the number

Re: OutOfMemoryError with clojure.contrib.sql and large result sets

2009-05-18 Thread Stephen C. Gilardi
On May 18, 2009, at 4:10 AM, Mark Addleman wrote: The problem is likely in the MySQL's JDBC driver. Some retrieve the entire result set from the database on statement execute while others are more true to the notion of a remote database cursor. The JDBC API has a workaround for this problem:

Re: OutOfMemoryError with clojure.contrib.sql and large result sets

2009-05-15 Thread Ian Eure
On May 14, 2009, at 7:54 PM, Stephen C. Gilardi wrote: On May 14, 2009, at 7:13 PM, Ian Eure wrote: I'm trying to process mid/large result sets with Clojure, and not having any success. (ns foo (:require [clojure.contrib.sql :as sql])) (def *db* {:classname com.mysql.jdbc.Driver

Re: OutOfMemoryError with clojure.contrib.sql and large result sets

2009-05-15 Thread Stephen C. Gilardi
On May 15, 2009, at 6:14 PM, Ian Eure wrote: I'm not having any luck at all. I tried visualvm, but it seems that it doesn't support memory profiling unless you're running JDK 6. I switched my default version (I'm on OS X here), and visualvm refuses to start: 2009-05-15 14:03:15.495

Re: OutOfMemoryError with clojure.contrib.sql and large result sets

2009-05-14 Thread Stephen C. Gilardi
On May 14, 2009, at 7:13 PM, Ian Eure wrote: I'm trying to process mid/large result sets with Clojure, and not having any success. (ns foo (:require [clojure.contrib.sql :as sql])) (def *db* {:classname com.mysql.jdbc.Driver :subprotocol mysql :subname //DSN