Skip to content

Commit 9265902

Browse files
committed
Added TODO comment for PostgreSQL lock timeout in SQLAlchemy recorder.
1 parent 6fde1fe commit 9265902

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

eventsourcing_sqlalchemy/recorders.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@ def _lock_table(self, session: Session) -> None:
9999
if self.schema_name is not None:
100100
events_table_name = f"{self.schema_name}.{events_table_name}"
101101
if self.datastore.engine.dialect.name == "postgresql":
102+
# Todo: "SET LOCAL lock_timeout = '{x}s'" like in eventsourcing.postgres?
102103
session.execute(text(f"LOCK TABLE {events_table_name} IN EXCLUSIVE MODE"))
103104
elif self.datastore.engine.dialect.name == "mssql":
104105
pass

0 commit comments

Comments
 (0)