Move Send Webmentions to ActiveJob
This PR does the next chunk of #1548, and the first which is an async enqueued job vs. a timed cron job. There were some larger changes in this one. I'll notate them in self-review.
I had a minute and wanted to toss in a couple notes.
BTW, your work moving Mastodon to a job is paying off; because those are properly wired into our exception tracking (where cron errors were yeeted into the outer darkness), I caught and fixed a lurking bug. Thanks again!
OK, after a few false starts I think we're now in a good spot. This works to the fullest extent I can test without a staging env, i.e., it can run the job without blowing up, targeting a real site with webmentions, and said job fires the POST that I would expect to the place I would expect. (I can't be 100% because actually confirming that the webmention sticks would require a public URL to the page that's hosting the mention)
This PR has had no activity for 21 days. Please leave a comment or commit to indicate you're still actively working on it.
I think the stalebot is catching my mistake, that I've let this slip through the cracks. @vivshaw is this ready to review for merge? From skimming the conversation it sure looks complete, and I'm sorry if I've accidentally left it to go stale.
This PR has had no activity for 21 days. Please leave a comment or commit to indicate you're still actively working on it.
@pushcx well hey, I also let it slip through the cracks. was outta town for a while, was Planning Season at work for a while, and completely forgot I had never followed up with this. such is life!
I just merged in master and tested it locally once again. far as I'm aware, this is indeed ready for review!
Just did another review, there's only two small changes before this is ready to go. Again, I'm sorry I let this hang out so long, thanks for continuing to work on it.
- Add the
enqueue_after_transaction_commit = truelinked in the 'testing' thread. Which... I think should go up inApplicationJob. It seems like it protects us from a footgun and we should be leaving a comment in each job that wants to opt out of it. - Add the
return if devcheck from the same thread.
This PR has had no activity for 30 days. Please leave a comment or commit to indicate you're still actively working on it.
I didn't want this to wait around, so I made those last couple tweaks in the merge commit.
Thanks for implementing this!