On Fri, 29 Oct 1999, you wrote:
> William Worth wrote:
>
> > How would you suggest using your servlet to access a database then ?
> > TCP/IP sockets (interprocess comms) are not serializeable either...
> >
>
> The most common solution is to store a connection pool in the ServletContext
> attributes, or in a static variable. Besides the serializability issue,
> connection pools let you share a given number of JDBC connections between a
> much larger pool of actual users, instead of having a connection per user
> needed when you store connections in the session.
>
> By the way, the reason for the "Serializable only" restriction is so you can
> run your servlets in a servlet container that supports distributed
> operations. The 2.2 API specification (released after Jason's book) clarified
> this requirement to only apply when you set the <distributable/> flag in your
> web application deployment descriptor. Otherwise, it doesn't matter.
>
> Craig McClanahan
Thanks. Would I be correct in thinking that connection pools create potential
security problems if not all users are accessing the same db, and / or some
have more privileges than others ? - or can this all be handled relatively
simply be 'grading connecitons' ?
William.> >
___________________________________________________________________________ >
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body >
of the message "signoff SERVLET-INTEREST". >
> Archives: http://archives.java.sun.com/archives/servlet-interest.html
> Resources: http://java.sun.com/products/servlet/external-resources.html
> LISTSERV Help: http://www.lsoft.com/manuals/user/user.html
--
The primary cause of failure in electrical appliances is an expired
warranty. Often, you can get an appliance running again simply by
changing the warranty expiration date with a 15/64-inch felt-tipped
marker.
-- Dave Barry, "The Taming of the Screw"
william:~#
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html