I agree that not being able to use prepared statements in BMP is somewhat
troublesome. You do get a pooled connection from the server, so this is a
good thing, but lack of prepared statement probably costs you a 10%-15%
performance hit.

Note: I would hope that most servers use prepared statements when
implementing CMP. Inprise's application server does this, and perhaps the
others do as well.

jim

----- Original Message -----
From: "Thor Heinrichs-Wolpert" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Wednesday, August 02, 2000 4:20 AM
Subject: Re: EJB destroys the benefits of PreparedStatement?


> >1. Most of the EJB books show the Connection that is obtained from the
> >DataSource being closed at the end of the method. Why? If the EJB server
is
> >responsible for maintaining a pool of database connections, then surely
it
> >alone should be responsible for adding and removing Connections from this
> >pool.
> The connection can (and quite often is) a logical connection to a real
> physical connection managed by the datasource.  When you ask for, and
> subsequently close a connection in the EJB, it is actually getting a
logical
> connection to a physical connection and using it.  The close only closes
the
> logical conection, and not the real physical connection (unless the
> datasource's event listener decides there are too many open physical
> connections).  There are a number of implementations, but generally this
is
> it.
>
> This is one of the beauties of using the container in the first place.
Your
> EJB code worries about what it has to do, and the conatiners transaction
> manager worries about what the "wired" together components need to do as a
> single aggregated transaction.  If your EJB internal code where to really
> worry about the application transactional details, your component would no
> longer be portable.
>
> Thor HW
>
>
===========================================================================
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the
body
> of the message "signoff EJB-INTEREST".  For general help, send email to
> [EMAIL PROTECTED] and include in the body of the message "help".
>
>

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to