Publisher: check out a connection for inserting publish_one jobs
authorrinpatch <rinpatch@sdf.org>
Fri, 13 Dec 2019 11:27:10 +0000 (14:27 +0300)
committerrinpatch <rinpatch@sdf.org>
Fri, 13 Dec 2019 11:27:10 +0000 (14:27 +0300)
commitbcd16676a78065a1b9549189ed3d594b4c62584c
tree2ea3691b7b18c53213e1c9f9b8ce6fd3818916d2
parent2f31cef71f377cf660f818e7e204436f2070bd78
Publisher: check out a connection for inserting publish_one jobs

Related to #1474, federation of one post on my istance creates in
best-case 360 jobs, so if they for some reason take a while to insert,
it will exhaust the connection pool. This fixes it by checking out one
dedicated connection for inserting them.
lib/pleroma/web/activity_pub/publisher.ex