Install django-rq and use it to ping WebSub, rather than blocking the micropub request during pings

This commit is contained in:
Danielle McLean 2017-11-06 11:04:22 +11:00
parent 382b7ee4a9
commit e853e22362
Signed by untrusted user: 00dani
GPG key ID: 5A5D2D1AFF12EEC5
6 changed files with 81 additions and 47 deletions

8
entries/jobs.py Normal file
View file

@ -0,0 +1,8 @@
from django_push import publisher
from django_rq import job
@job
def ping_hub(*urls):
for url in urls:
publisher.ping_hub(url)