Skip to content

Commit

Permalink
Agregamos Método liberarConexion()
Browse files Browse the repository at this point in the history
  • Loading branch information
antonellaarraez committed Jul 2, 2023
1 parent 3c02534 commit 24017cd
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,13 @@ def obtenerPool(cls):
sys.exit()
else:
return cls._pool
@classmethod
def liberarConexion(cls, conexion):
cls.obtenerPool().putconn(conexion)
log.debug(f'Regresamos la conexion del pool: {conexion}')



if __name__ == '__main__':
conexion1 = Conexion.obtenerConexion()
conexion2 = Conexion.obtenerConexion()
Expand Down

0 comments on commit 24017cd

Please sign in to comment.