ÿØÿàJFIFÿþ ÿÛC       ÿÛC ÿÀÿÄÿÄ"#QrÿÄÿÄ&1!A"2qQaáÿÚ ?Øy,æ/3JæÝ¹È߲؋5êXw²±ÉyˆR”¾I0ó2—PI¾IÌÚiMö¯–þrìN&"KgX:Šíµ•nTJnLK„…@!‰-ý ùúmë;ºgµŒ&ó±hw’¯Õ@”Ü— 9ñ-ë.²1<yà‚¹ïQÐU„ہ?.’¦èûbß±©Ö«Âw*VŒ) `$‰bØÔŸ’ëXÖ-ËTÜíGÚ3ð«g Ÿ§¯—Jx„–’U/ÂÅv_s(Hÿ@TñJÑãõçn­‚!ÈgfbÓc­:él[ðQe 9ÀPLbÃãCµm[5¿ç'ªjglå‡Ûí_§Úõl-;"PkÞÞÁQâ¼_Ñ^¢SŸx?"¸¦ùY騐ÒOÈ q’`~~ÚtËU¹CڒêV  I1Áß_ÿÙ 4]c@s/dZddlmZddlZddlZddlmZddlmZddlmZddlm Z dd lm Z dd l m Z e j d Z e j d Ze j d ZdefdYZde jfdYZdefdYZedZeZdefdYZdS(s'Base constructs for connection pools. i(tdequeNi(tevent(texc(t interfaces(tlog(tutil(t threadingtreset_rollbackt reset_committ reset_nonet _ConnDialectcBs2eZdZdZdZdZdZRS(spartial implementation of :class:`.Dialect` which provides DBAPI connection methods. When a :class:`.Pool` is combined with an :class:`.Engine`, the :class:`.Engine` replaces this with its own :class:`.Dialect`. cCs|jdS(N(trollback(tselftdbapi_connection((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt do_rollback)scCs|jdS(N(tcommit(R R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt do_commit,scCs|jdS(N(tclose(R R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pytdo_close/scCstddS(NsJThe ping feature requires that a dialect is passed to the connection pool.(tNotImplementedError(R R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pytdo_ping2s(t__name__t __module__t__doc__RRRR(((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR s     tPoolc BseZdZeZejddddddede dddedd Z e d Z e j d Z d Zd Zejdd dZdZdZde dZdZdZdZdZdZdZdZRS(s)Abstract base class for connection pools.tuse_threadlocals1.3sfThe :paramref:`.Pool.use_threadlocal` parameter is deprecated and will be removed in a future release.t listenerss0.7s:class:`.PoolListener` is deprecated in favor of the :class:`.PoolEvents` listener interface. The :paramref:`.Pool.listeners` parameter will be removed in a future release.ic Cs|r||_|_n d|_tj|d|tj|_||_||_ d|_ ||_ | |_ |dt tfkrt|_nU|ddttfkrt|_n1|dtfkrt|_ntjd|||_| r|jj| dtn| r!| |_n|rTx*|D]\} } tj|| | q.Wn|r{x|D]}|j|qaWndS( s Construct a Pool. :param creator: a callable function that returns a DB-API connection object. The function will be called with parameters. :param recycle: If set to a value other than -1, number of seconds between connection recycling, which means upon checkout, if this timeout is surpassed the connection will be closed and replaced with a newly opened connection. Defaults to -1. :param logging_name: String identifier which will be used within the "name" field of logging records generated within the "sqlalchemy.pool" logger. Defaults to a hexstring of the object's id. :param echo: if True, the connection pool will log informational output such as when connections are invalidated as well as when connections are recycled to the default log handler, which defaults to ``sys.stdout`` for output.. If set to the string ``"debug"``, the logging will include pool checkouts and checkins. The :paramref:`.Pool.echo` parameter can also be set from the :func:`.create_engine` call by using the :paramref:`.create_engine.echo_pool` parameter. .. seealso:: :ref:`dbengine_logging` - further detail on how to configure logging. :param use_threadlocal: If set to True, repeated calls to :meth:`connect` within the same application thread will be guaranteed to return the same connection object that is already checked out. This is a legacy use case and the flag has no effect when using the pool with a :class:`.Engine` object. :param reset_on_return: Determine steps to take on connections as they are returned to the pool. reset_on_return can have any of these values: * ``"rollback"`` - call rollback() on the connection, to release locks and transaction resources. This is the default value. The vast majority of use cases should leave this value set. * ``True`` - same as 'rollback', this is here for backwards compatibility. * ``"commit"`` - call commit() on the connection, to release locks and transaction resources. A commit here may be desirable for databases that cache query plans if a commit is emitted, such as Microsoft SQL Server. However, this value is more dangerous than 'rollback' because any data changes present on the transaction are committed unconditionally. * ``None`` - don't do anything on the connection. This setting should generally only be made on a database that has no transaction support at all, namely MySQL MyISAM; when used on this backend, performance can be improved as the "rollback" call is still expensive on MySQL. It is **strongly recommended** that this setting not be used for transaction-supporting databases in conjunction with a persistent pool such as :class:`.QueuePool`, as it opens the possibility for connections still in a transaction to be idle in the pool. The setting may be appropriate in the case of :class:`.NullPool` or special circumstances where the connection pool in use is not being used to maintain connection lifecycle. * ``False`` - same as None, this is here for backwards compatibility. :param events: a list of 2-tuples, each of the form ``(callable, target)`` which will be passed to :func:`.event.listen` upon construction. Provided here so that event listeners can be assigned via :func:`.create_engine` before dialect-level listeners are applied. :param listeners: A list of :class:`.PoolListener`-like objects or dictionaries of callables that receive events when DB-API connections are created, checked out and checked in to the pool. :param dialect: a :class:`.Dialect` that will handle the job of calling rollback(), close(), or commit() on DBAPI connections. If omitted, a built-in "stub" dialect is used. Applications that make use of :func:`~.create_engine` should not use this parameter as it is handled by the engine creation strategy. .. versionadded:: 1.1 - ``dialect`` is now a public parameter to the :class:`.Pool`. :param pre_ping: if True, the pool will emit a "ping" (typically "SELECT 1", but is dialect-specific) on the connection upon checkout, to test if the connection is alive or not. If not, the connection is transparently re-connected and upon success, all other pooled connections established prior to that timestamp are invalidated. Requires that a dialect is passed as well to interpret the disconnection error. .. versionadded:: 1.2 techoflagiR tnoneRs'Invalid value for 'reset_on_return': %rtonly_propagateN(t logging_namet_orig_logging_nametNoneRtinstance_loggerRtlocalt _threadconnst_creatort_recyclet_invalidate_timet_use_threadlocalt _pre_pingtTrueRt_reset_on_returntFalseR RRt ArgumentErrortechotdispatcht_updatet_dialectRtlistent add_listener(R tcreatortrecycleR-RRtreset_on_returnRteventstdialecttpre_pingt _dispatchtfnttargettl((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt__init__?s:             cCs |jdS(NR$(t__dict__(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR$scCs#||jd<|j||_dS(NR$(R>t_should_wrap_creatort_invoke_creator(R R3((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR$s csytj|jdt}Wntk r9fdSX|ddk rZt|dp]d}t|d|}|d|dfdgd fkrS|dkrSfdSdS( slDetect if creator accepts a single argument, or is sent as a legacy style no-arg function. tno_selfcsS(N((tcrec(R3(sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyttiitconnection_recordicsS(N((RB(R3(sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRCRDN(N(Rtget_callable_argspecR$R)t TypeErrorR tlen(R R3targspect defaultedt positionals((R3sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR?s &# cCsX|jjd|y|jj|Wn*tk rS|jjd|dtnXdS(NsClosing connection %rsException closing connection %rtexc_info(tloggertdebugR0Rt ExceptionterrorR)(R t connection((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt_close_connection s   sThe :meth:`.Pool.add_listener` method is deprecated and will be removed in a future release. Please use the :class:`.PoolEvents` listener interface.cCstjj||dS(sAdd a :class:`.PoolListener`-like object to this pool. ``listener`` may be an object that implements some or all of PoolListener, or a dictionary of callables containing implementations of some or all of the named methods in PoolListener. N(Rt PoolListenert_adapt_listener(R tlistener((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR2scCs tj|S(sProduce a DBAPI connection that is not referenced by any thread-local context. This method is equivalent to :meth:`.Pool.connect` when the :paramref:`.Pool.use_threadlocal` flag is not set to True. When :paramref:`.Pool.use_threadlocal` is True, the :meth:`.Pool.unique_connection` method provides a means of bypassing the threadlocal context. (t_ConnectionFairyt _checkout(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pytunique_connection$s cCs t|S(s6Called by subclasses to create a new ConnectionRecord.(t_ConnectionRecord(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt_create_connection1scCsit|dd}| s+|j|jkr=tj|_n|ret|dtre|j|ndS(sMark all connections established within the generation of the given connection as invalidated. If this pool's last invalidate time is before when the given connection was created, update the timestamp til now. Otherwise, no action is performed. Connections with a start time prior to this pool's invalidation time will be recycled upon next checkout. t_connection_recordtis_validN(tgetattrR R&t starttimettimeR+t invalidate(R RQt exceptiont_checkintrec((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt _invalidate6s cCs tdS(sReturn a new :class:`.Pool`, of the same class as this one and configured with identical creation arguments. This method is used in conjunction with :meth:`dispose` to close out an entire :class:`.Pool` and create a new one in its place. N(R(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pytrecreateGs cCs tdS(sDispose of this pool. This method leaves the possibility of checked-out connections remaining open, as it only affects connections that are idle in the pool. .. seealso:: :meth:`Pool.recreate` N(R(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pytdisposeSs cCsf|jstj|Sy|jj}Wntk r<nX|dk rS|jStj||jS(sReturn a DBAPI connection from the pool. The connection is instrumented such that when its ``close()`` method is called, the connection will be returned to the pool. N(R'RVRWR#tcurrenttAttributeErrorR t_checkout_existing(R Rc((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pytconnectbs     cCs>|jr-y |j`Wq-tk r)q-Xn|j|dS(sGiven a _ConnectionRecord, return it to the :class:`.Pool`. This method is called when an instrumented DBAPI connection has its ``close()`` method called. N(R'R#RgRht_do_return_conn(R trecord((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt _return_connws    cCs tdS(s7Implementation for :meth:`get`, supplied by subclasses.N(R(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt_do_getscCs tdS(s?Implementation for :meth:`return_conn`, supplied by subclasses.N(R(R tconn((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRkscCs tdS(N(R(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pytstatuss(s1.3sfThe :paramref:`.Pool.use_threadlocal` parameter is deprecated and will be removed in a future release.(s0.7s:class:`.PoolListener` is deprecated in favor of the :class:`.PoolEvents` listener interface. The :paramref:`.Pool.listeners` parameter will be removed in a future release.N(RRRR R0Rtdeprecated_paramsR R+R)R=tpropertyR$tsetterR?RRt deprecatedR2RXRZRdReRfRjRmRnRkRp(((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR9sD           RYcBseZdZedZdZdZdZdZ e j dZ e j dZ edZdZedZedZed Zd Zded Zd Zd ZedZRS(sInternal object which maintains an individual DBAPI connection referenced by a :class:`.Pool`. The :class:`._ConnectionRecord` object always exists for any particular DBAPI connection whether or not that DBAPI connection has been "checked out". This is in contrast to the :class:`._ConnectionFairy` which is only a public facade to the DBAPI connection while it is checked out. A :class:`._ConnectionRecord` may exist for a span longer than that of a single DBAPI connection. For example, if the :meth:`._ConnectionRecord.invalidate` method is called, the DBAPI connection associated with this :class:`._ConnectionRecord` will be discarded, but the :class:`._ConnectionRecord` may be used again, in which case a new DBAPI connection is produced when the :class:`.Pool` next uses this record. The :class:`._ConnectionRecord` is delivered along with connection pool events, including :meth:`.PoolEvents.connect` and :meth:`.PoolEvents.checkout`, however :class:`._ConnectionRecord` still remains an internal object whose API and internals may change. .. seealso:: :class:`._ConnectionFairy` cCs2||_|r"|jdtnt|_dS(Ntfirst_connect_check(t_ConnectionRecord__poolt_ConnectionRecord__connectR)Rtfinalize_callback(R tpoolRj((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR=s icCsiS(sYThe ``.info`` dictionary associated with the DBAPI connection. This dictionary is shared among the :attr:`._ConnectionFairy.info` and :attr:`.Connection.info` accessors. .. note:: The lifespan of this dictionary is linked to the DBAPI connection itself, meaning that it is **discarded** each time the DBAPI connection is closed and/or invalidated. The :attr:`._ConnectionRecord.record_info` dictionary remains persistent throughout the lifespan of the :class:`._ConnectionRecord` container. ((R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pytinfoscCsiS(sAn "info' dictionary associated with the connection record itself. Unlike the :attr:`._ConnectionRecord.info` dictionary, which is linked to the lifespan of the DBAPI connection, this dictionary is linked to the lifespan of the :class:`._ConnectionRecord` container itself and will remain persistent throughout the life of the :class:`._ConnectionRecord`. .. versionadded:: 1.1 ((R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt record_infoscsjyj}Wn3tk rQ}tjj|WdQXnXjt|}tj |fd_ t j rj jd|n|S(Ncstotd|S(N(t_finalize_fairyR (tref(R-RyRc(sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRCss#Connection %r checked out from pool(Rntget_connectionRORt safe_reraiset_checkin_failedt_should_log_debugRVtweakrefR}t fairy_reft_refstaddRMRN(tclsRyR terrtfairy((R-RyRcsG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pytcheckouts       cCs$|jd||jdtdS(Ntet _no_fairy_ref(R`tcheckinR)(R R((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRscCs|jdkr+| r+tjd|dSd|_|j}|j}x&|jrn|jj}||qIW|jj r|jj ||n|j |dS(NsDouble checkin attempted on %s( RR RtwarnRQRvRxtpopR.RRm(R RRQRyt finalizer((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRs     cCs |jdk S(N(RR (R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pytin_usescCs|jS(N(R^(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pytlast_connect_timescCs |jdk r|jndS(N(RQR t_ConnectionRecord__close(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRscCs|jdkrdS|r8|jjj|j||n|jjj|j|||dk r|jjjd|r{dnd|j|jj |n(|jjjd|rdnd|j|rt j |_ n|j d|_dS(sInvalidate the DBAPI connection held by this :class:`._ConnectionRecord`. This method is called for all connection invalidations, including when the :meth:`._ConnectionFairy.invalidate` or :meth:`.Connection.invalidate` methods are called, as well as when any so-called "automatic invalidation" condition occurs. :param e: an exception object indicating a reason for the invalidation. :param soft: if True, the connection isn't closed; instead, this connection will be recycled on next checkout. .. versionadded:: 1.0.3 .. seealso:: :ref:`pool_connection_invalidation` Ns*%sInvalidate connection %r (reason: %s:%s)sSoft RDs%sInvalidate connection %r( RQR RvR.tsoft_invalidateR`RMRzt __class__RR_t_soft_invalidate_timeR(R Rtsoft((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR`s(       cCs&t}|jdkr/|jj|jn|jjdkrtj|j |jjkr|jj jd|jt }ns|jj |j kr|jj jdd|jt }n8|j |j kr|jj jdd|jt }n|r|j|jj|jn|jS(Nis)Connection %r exceeded timeout; recyclings4Connection %r invalidated due to pool invalidation; t recyclings:Connection %r invalidated due to local soft invalidation; (R+RQR RztclearRwRvR%R_R^RMR)R&RR(R R4((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR~Ms4              cCsX|jj|jjjr8|jjj|j|n|jj|jd|_dS(N(RxRRvR.RRQRRR (R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt__closeps  cCs|j}d|_y>tj|_|j|}|jjd|||_Wn)tk r{}|jjd|nTX|r|j j j |j j |j|n|j j r|j j |j|ndS(NsCreated new connection %rsError on connect(): %s(RvR RQR_R^R@RMRNROR.t first_connectt for_modifyt exec_onceRj(R RuRyRQR((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt __connectws       N(RRRR)R=R RR^RQRRtmemoized_propertyRzR{t classmethodRRR+RRrRRRR`R~RRw(((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRYs$     / # cCsntj||dk rJ|j|k r,dS|dks>t|j}n|dk rH|rx|rx|jjd|nys|pt|||}|j|kst|j ||s|j j r|j j |n|j |nWqHt k rD}|jjddt|r,|jd|nt|tsEqEqHXn|rj|jdk rj|jndS(sfCleanup for a :class:`._ConnectionFairy` whether or not it's already been garbage collected. Ns$Connection %r being returned to pools!Exception during reset or similarRLR(RtdiscardR RtAssertionErrorRQRMRNRVt_resetR.tclose_detachedRRt BaseExceptionRPR)R`t isinstanceROR(RQRERyR}R-RR((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR|s8             RVcBseZdZdZdZdZdZedddZ dZ dZ e Z dZ edZedZejdZed Zded Zd Zd Zd ZdZRS(sXProxies a DBAPI connection and provides return-on-dereference support. This is an internal object used by the :class:`.Pool` implementation to provide context management to a DBAPI connection delivered by that :class:`.Pool`. The name "fairy" is inspired by the fact that the :class:`._ConnectionFairy` object's lifespan is transitory, as it lasts only for the length of a specific DBAPI connection being checked out from the pool, and additionally that as a transparent proxy, it is mostly invisible. .. seealso:: :class:`._ConnectionRecord` cCs||_||_||_dS(N(RQR[t_echo(R R RER-((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR=s  cCsi|sKtj|}||_d|_|dk rKtj||_qKn|jdkrlt j dn|jd7_|j j r|j s|jdkr|Sd}x|dkr;y|j r7|j r|jjd|jn|jj|j}|s7|j r%|jjd|jnt jq7n|j j|j|j||SWqt jk r7}|jr|jjd||jj||j||dtn)|jjd |j||jj|y|jj|_Wn6tk r)}tj|jj|WdQXnX|d8}qXqW|jjd |jt j ddS( NisThis connection is closediisPool pre-ping on connection %ss;Pool pre-ping on connection %s failed, will invalidate poolsoDisconnection detected on checkout, invalidating all pooled connections prior to current timestamp (reason: %r)RbsVDisconnection detected on checkout, invalidating individual connection %s (reason: %r)s+Reconnection attempts exhausted on checkout(RYRt_poolt_counterR RR}RgRQRtInvalidRequestErrorR.R(RRMRNR0RtInvalidatePoolErrorR[tDisconnectionErrortinvalidate_poolRzR`RdR+R~RORRR(RRyt threadconnsRtattemptstresultRR((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRWsd               cCstj|jd|S(NR(RVRWR(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRiEscCs>t|j|j|jd|jd|d|_d|_dS(NR(R|RQR[RR R(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRbHs  cCs|jjr%|jj||jn|jtkr|jrh|jjd|j|j r^dndn|j r|j j q|j j |no|jt kr|jr|jjd|j|j rdndn|j r|j jq|j j|ndS(Ns"Connection %s rollback-on-return%ss , via agentRDs Connection %s commit-on-return%s(R.tresetR[R*RRRMRNRQt _reset_agentR R0RRRR(R Ry((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRVs(       cCs |jjS(N(RRM(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt_loggerpscCs |jdk S(sbReturn True if this :class:`._ConnectionFairy` still refers to an active DBAPI connection.N(RQR (R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR\tscCs |jjS(sInfo dictionary associated with the underlying DBAPI connection referred to by this :class:`.ConnectionFairy`, allowing user-defined data to be associated with the connection. The data here will follow along with the DBAPI connection including after it is returned to the connection pool and used again in subsequent instances of :class:`._ConnectionFairy`. It is shared with the :attr:`._ConnectionRecord.info` and :attr:`.Connection.info` accessors. The dictionary associated with a particular DBAPI connection is discarded when the connection itself is discarded. (R[Rz(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRz{scCs|jr|jjSdSdS(sInfo dictionary associated with the :class:`._ConnectionRecord container referred to by this :class:`.ConnectionFairy`. Unlike the :attr:`._ConnectionFairy.info` dictionary, the lifespan of this dictionary is persistent across connections that are disconnected and/or invalidated within the lifespan of a :class:`._ConnectionRecord`. .. versionadded:: 1.1 N(R[R{R (R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR{s  cCse|jdkr tjddS|jrE|jjd|d|n|sad|_|jndS(sMark this connection as invalidated. This method can be called directly, and is also called as a result of the :meth:`.Connection.invalidate` method. When invoked, the DBAPI connection is immediately closed and discarded from further use by the pool. The invalidation mechanism proceeds via the :meth:`._ConnectionRecord.invalidate` internal method. :param e: an exception object indicating a reason for the invalidation. :param soft: if True, the connection isn't closed; instead, this connection will be recycled on next checkout. .. versionadded:: 1.0.3 .. seealso:: :ref:`pool_connection_invalidation` s.Can't invalidate an already-closed connection.NRR(RQR RRR[R`Rb(R RR((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyR`s   cOs|jj||S(sReturn a new DBAPI cursor for the underlying connection. This method is a proxy for the ``connection.cursor()`` DBAPI method. (RQtcursor(R targstkwargs((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRscCst|j|S(N(R]RQ(R tkey((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt __getattr__scCs|jdk r|j}tj|d|_d|_|jj|j|jj |_d|_|jj j r|jj j |j|qndS(s"Separate this connection from its Pool. This means that the connection will no longer be returned to the pool when closed, and will instead be literally closed. The containing ConnectionRecord is separated from the DB-API connection, and will create a new connection when next used. Note that any overall connection limiting constraints imposed by a Pool implementation may be violated after a detach, as the detached connection is removed from the pool's knowledge and control. N( R[R RtremoveRRQRRkRztcopyR.tdetach(R Rc((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRs      cCs/|jd8_|jdkr+|jndS(Nii(RRb(R ((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRsN(RRRR=R RQR[RRRWRiRbt_closeRRrRR\RRRzR{R+R`RRRR(((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyRVs( O     (Rt collectionsRR_RRDRRRRRRtsymbolRRR tobjectR t IdentifiedRRYR R|tsetRRV(((sG/opt/alt/python27/lib64/python2.7/site-packages/sqlalchemy/pool/base.pyt s&  [ -