From: pginfo <pginfo@t1.unisoftbg.com>
To: Rafal Kedziorski <rafcio@polonium.de>
Cc: pgsql-performance@postgresql.org
Cc: darryl.staflund@shaw.ca
Subject: Re: JBoss CMP Performance Problems with PostgreSQL 7.2.3
Date: Thu, 13 Feb 2003 11:01:31 +0100
Message-ID: <3E4B6CFA.725CA585@t1.unisoftbg.com> (raw)
References: <000201c2d33a$7aecd320$ac584618@ltd924607.ca>
<3E4B63CC.5070201@polonium.de>
Rafal Kedziorski wrote:
> Darryl A. J. Staflund wrote:
>
> >Hi Everyone,
> >
> >I am developing a JBoss 3.0.x application using PostgreSQL 7.2.3 as a
> >back-end database and Solaris 2.8 (SPARC) as my deployment OS. In this
> >application, I am using an EJB technology called Container Managed
> >Persistence (CMP 2.0) to manage data persistence for me. Instead of
> >writing and submitting my own queries to the PostgreSQL database, JBoss is
> >doing this for me.
> >
> >Although this works well for the most part, the insertion of many records
> >within the context of a single transaction can take a very long time to
> >complete. Inserting 800 records, for instance, can take upward of a
> >minute to finish - even though the database is fully indexed and records
> >consist of no more than a string field and several foreign key integer
> >values.
> >
> >I think I've tracked the problem down to the way in which PostgreSQL
> >manages transactions. Although on the Java side of things I perform all
> >my insertions and updates within the context of a single transaction,
> >PostgreSQL seems to treat each individual query as a separate transaction
> >and this is slowing down performance immensely. Here is a sample of my
> >PostgreSQL logging output:
> >
> >
> [...]
>
> I think the problem isn't PostgreSQL. This is the JBoss-CMP. Take a look
> on EJB Benchmark from urbancode
> (http://www.urbancode.com/projects/ejbbenchmark/default.jsp).
>
> Best Regards,
> Rafal
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
I think the problem is not in the jboss.
I am using pg + jboss from a long time and if you know how to wirk with it the
combination is excelent.
The main problem in this case is CMP and also EntityBeans.
By CMP jboss will try to insert this 800 records separate.
In this case pg will be slow.
I never got good results by using EB and CMP.
If you will to have working produkt use BMP.
regards,
ivan.
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-performance@postgresql.org
Cc: pginfo@t1.unisoftbg.com, rafcio@polonium.de, darryl.staflund@shaw.ca
Subject: Re: JBoss CMP Performance Problems with PostgreSQL 7.2.3
In-Reply-To: <3E4B6CFA.725CA585@t1.unisoftbg.com>
References: <000201c2d33a$7aecd320$ac584618@ltd924607.ca> <3E4B63CC.5070201@polonium.de> <3E4B6CFA.725CA585@t1.unisoftbg.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox