Skip to content

Commit

Permalink
SKADE-645 [FEATURE] added logger for execute with transaction
Browse files Browse the repository at this point in the history
  • Loading branch information
RoAduran committed Aug 12, 2024
1 parent be06111 commit d7d8ff5
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions infpostgresql/client.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import psycopg
from retrying import retry

from infpostgresql.debugger import debug_sql_call
from infpostgresql.debugger import debug_sql_call, debug_sql_transaction_calls


class PostgresClient:
Expand Down Expand Up @@ -37,7 +37,8 @@ def execute_with_lock(self, query, table, params=None):
cur.execute("COMMIT TRANSACTION;")

return result


@debug_sql_transaction_calls
def execute_with_transactions(self, list_of_queries_with_params):
with self._cursor(autocommit=False) as cur:
try:
Expand Down

0 comments on commit d7d8ff5

Please sign in to comment.