Re: [h2] Strange long INSER : One INSERT out of 18889 is very long

2017-02-23 Thread Thomas Mueller Graf
Hi,

Well I can't reproduce the problem. I understand creating a unit test might
be complicated.

Could you provide the following info?

* File size
* Run the MVStore tool with "-info " (java -jar
... org.h2.mvstore.MVStoreTool -info <...>) and provide the output
(possibly attached if it's large)

Regards,
Thomas



On Thursday, February 23, 2017, Nicolas Humeau 
wrote:

> Hi,
>
> I'm using version 1.4.193.
>
> What do you mean by create a test case? I'm not sure I understand.
>
> By the way I ran several test on linux rather than windows but on the same
> computer and it went better.
>
> Thx,
> Nicolas
>
> Le dimanche 12 février 2017 14:00:51 UTC+1, Thomas Mueller Graf a écrit :
>>
>> Hi,
>>
>> collectReferencedChunks used to be a problem in the past, but recent
>> version of H2 should be better. Which version do you use? If the latest
>> version, could you create a simple test case?
>>
>> Regards,
>> Thomas
>>
>>
>> On Fri, Jan 27, 2017 at 12:48 PM, Noel Grandin 
>> wrote:
>>
>>> yeah, that would be the MVStore compacting process.
>>>
>>> Not much that you can do about that, short of running in MULTITHREADED
>>> mode, which is still a little experimental, even I won't deploy that in
>>> production yet.
>>>
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "H2 Database" group.
>>> To unsubscribe from this group and stop receiving emails from it, send
>>> an email to h2-database...@googlegroups.com.
>>> To post to this group, send email to h2-da...@googlegroups.com.
>>> Visit this group at https://groups.google.com/group/h2-database.
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>>
>> --
> You received this message because you are subscribed to the Google Groups
> "H2 Database" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to h2-database+unsubscr...@googlegroups.com
> 
> .
> To post to this group, send email to h2-database@googlegroups.com
> .
> Visit this group at https://groups.google.com/group/h2-database.
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at https://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


Re: [h2] Strange long INSER : One INSERT out of 18889 is very long

2017-01-21 Thread Noel Grandin
can you try running the built in profiler during that insert, and lets see
what it's doing:

http://h2database.com/html/performance.html#built_in_profiler
​

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at https://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.


[h2] Strange long INSER : One INSERT out of 18889 is very long

2017-01-21 Thread Nicolas Humeau
Here is what's happening :

I'm using a table like this :
CREATE TABLE IF NOT EXISTS TMPACKETS(id int primary key auto_increment, 
type varchar(64), reception_time TIMESTAMP, onboard_time TIMESTAMP, data 
varbinary(50))

I'm inserting with prepared statement like this :
this.preparedStatement = this.conn.prepareStatement("INSERT INTO TMPACKETS 
(TYPE, RECEPTION_TIME, ONBOARD_TIME, DATA) VALUES (?,?,?,?)");

My DB size is now 2GO. I'm doing a lots a of inserts in a row. I've noticed 
that when I do precisely 18689 inserts in a row then the 18688 firsts are 
as fast as usual, but the number18689, the last one, is really slow (around 
3 sec for 1 insert). I can repeat the same operation every time and for 
this precise insert number 18689 it takes 3 seconds and blocks the h2 
database (impossible to perform a read at the same moment).

I've noticed that is was not coming from the speed I'm doing the inserts, 
it blocks every time at the insert number 18689, no matter at what speed I 
do it.

What it even more strange it is that if I just do 18688 inserts in a row 
and close my app (close the java vm) and re-run 18688 inserts in a row it 
goes well every time and I can do it as much as I want. But if I do one 
more insert then I have to wait 3 seconds more on the last insert, which is 
quite a long time.

Did anyone already faced this issue? Is 2GByte to much to handle for H2?

Thanks for your help,

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to h2-database+unsubscr...@googlegroups.com.
To post to this group, send email to h2-database@googlegroups.com.
Visit this group at https://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.