Re: [PERFORM] Improving PostgreSQL insert performance - Mailing list pgsql-performance

From Vladimir Sitnikov
Subject Re: [PERFORM] Improving PostgreSQL insert performance
Date
Msg-id CAB=Je-EfJ3um4BnXxL-xHEYL9BOc4dA5=ux0-h=S64Zxxnc9_A@mail.gmail.com
Whole thread Raw
In response to Re: [PERFORM] Improving PostgreSQL insert performance  (Frits Jalvingh <jal@etc.to>)
Responses Re: [PERFORM] Improving PostgreSQL insert performance  (Alvaro Herrera <alvherre@2ndquadrant.com>)
List pgsql-performance
Alvaro>Something like
INSERT INTO .. VALUES ('col1', 'col2'), ('col1', 'col2'), ('col1', 'col2')>I did not 
Frits>try that, to be honest.

pgjdbc does automatically rewrite insert values(); into insert ... values(),(),(),() when reWriteBatchedInserts=true. I don't expect manual multivalues to be noticeably faster there.


Frits>https://etc.to/confluence/display/~admjal/PostgreSQL+performance+tests

Do you really intend to measure just a single insert operation?
It looks odd, as typical applications would execute inserts for quite a while before they terminate.

You are including lots of warmup overheads (e.g. JIT-compilation), so your approach does not measure peak performance.
On the other hand, you are not measuring enough time to catch things like "DB log switch".

Would you please use JMH as a load driver?

Vladimir

pgsql-performance by date:

Previous
From: Frits Jalvingh
Date:
Subject: Re: [PERFORM] Improving PostgreSQL insert performance
Next
From: Alvaro Herrera
Date:
Subject: Re: [PERFORM] Improving PostgreSQL insert performance