Hello,
I'm trying to insert in a database large number of records, however
it's not scaling correctly. For 100 records it takes 10 seconds, for
100 records it takes 2 min to save. But for 250 records it
throws Java Heap out of memory exception.
I've tried separting the records processing
header
(filter #(= (:item_id %) item-id) rows)
id))
(dorun (pmap #(filter-data rows %1 header %2)
items id ))
On Dec 16, 4:45 pm, Michael Ossareh wrote:
> On Thu, Dec 16, 2010 at 09:19, clj123 wrote:
> > Hello,
>
> > I'm trying to insert in
5:39 PM, clj123 wrote:
> > (defn persist-rows
> > [headers rows id]
> > (let [mrows (transform-rows rows id)]
> > (with-db *db* (try
> > (apply insert-into-table
> > :my-table
> > [:col1 :col2 :col3]
> >
Hello,
I'm looking for an on-going service that runs and processes files in a
certain location. This function should be contiously running.
The function that I've used, it always running and when files are
place it does something with it.
(defn run-always []
(while true (dosomething)))
How
I have been getting this exception:
java.lang.Exception: transaction rolled back:
java.lang.InterruptedException
at clojure.contrib.sql.internal$throw_rollback.invoke(internal.clj:
142)
at clojure.contrib.sql.internal$transaction_STAR_.invoke(internal.clj:
169)
at com.protot
I have been getting this exception:
java.lang.Exception: transaction rolled back:
java.lang.InterruptedException
at clojure.contrib.sql.internal$throw_rollback.invoke(internal.clj:
142)
at clojure.contrib.sql.internal$transaction_STAR_.invoke(internal.clj:
169)
at com.protot
I'm getting the following exception trying to insert large batch data
in the database. Any ideas?
java.lang.Exception: transaction rolled back:
java.lang.InterruptedException
at clojure.contrib.sql.internal$throw_rollback.invoke(internal.clj:
142)
at clojure.contrib.sql.internal$tr
at clojure.lang.LazySeq.seq(LazySeq.java:56)
at clojure.lang.Cons.next(Cons.java:39)
at clojure.lang.RT.next(RT.java:560)
at clojure.core$next.invoke(core.clj:61)
On Feb 23, 12:59 pm, Saul Hazledine wrote:
> On Feb 23, 9:54 pm, clj123 wrote:
>
> > I'm getting the fo
I've also noticed that I can cause this InterruptedException to be
thrown if I add
(. Thread (sleep 1000)) instead of saving to database.
It looks like when a thread is waiting for a long time this exception
is being thrown. By the way I'm running only one thread in my code.
Here's the rest of m
I've tried saving a much smaller number of rows and I'm still getting
this exception.
I also tried processing the rows (without saving to database) and put
a Thread sleep. That also generated this exception.
On Feb 23, 12:55 pm, Saul Hazledine wrote:
> On Feb 23, 9:42 pm, clj123 w
ml
>
> HTH
>
> Regards,
> Shantanu
>
> On Feb 25, 4:12 am, clj123 wrote:
>
>
>
> > I've also noticed that I can cause this InterruptedException to be
> > thrown if I add
>
> > (. Thread (sleep 1000)) instead of saving to database.
>
> >
11 matches
Mail list logo