Yves-Eric Martin wrote:
> 
> Shane Hathaway <[EMAIL PROTECTED]> wrote:
> > You *must* remember to close the connection:
> >
> > app._p_jar.close()
> 
>     This is not mentionned in the above document, so I was doing without
> so far, and did not run into any problem. Now that I see it, I believe
> this is the Right Thing to Do and will include it in the release. But
> since you put an emphasis on its being required, can you tell us what
> evil things may happen if you don't close the connection? (Consuming
> ressources?)

That's correct.  Only a certain number of connections are allowed at a
time.  Currently, as the "app" object falls out of scope it should
close the connection automatically, but that may not always be the case
IMHO.

BTW if you're using this technique, be sure you're not opening two
connections in one thread.  It can prove hazardous.

Shane

_______________________________________________
Zope-Dev maillist  -  [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope-dev
**  No cross posts or HTML encoding!  **
(Related lists - 
 http://lists.zope.org/mailman/listinfo/zope-announce
 http://lists.zope.org/mailman/listinfo/zope )

Reply via email to