Commit 6ba06f69 authored by Guillaume Mella's avatar Guillaume Mella

close db connection after work to avoid 'remaining connection slots are...

close db connection after work to avoid 'remaining connection slots are reserved for non-replication superuser connections'
parent e1b18b4c
Pipeline #34783 passed with stage
in 5 minutes and 5 seconds
IMAGE_TAG=0.23-beta
IMAGE_TAG=0.24-beta
......@@ -103,8 +103,10 @@ class ImportProcess(threading.Thread):
print("Header: '%s'"%(self.sub.headers))
print("Data : '%s'"%(entry.line_data))
print("------> inner session not saved")
i_session.rollback()
else:
print("INNER SESSION COMMITTED")
i_session.close()
print('end of processing')
self.sub.processed = True
session.commit()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment