log_connexion

This commit is contained in:
Emmanuel Garette 2021-04-24 14:15:54 +02:00
parent 9ebe79d533
commit 27031dbf0e
1 changed files with 53 additions and 44 deletions

View File

@ -260,6 +260,15 @@ class PublishDispatcher:
False,
False,
)
async with self.pool.acquire() as log_connection:
await log_connection.set_type_codec(
'json',
encoder=dumps,
decoder=loads,
schema='pg_catalog'
)
async with log_connection.transaction():
risotto_context.log_connection = log_connection
async with self.pool.acquire() as connection:
await connection.set_type_codec(
'json',