Hacker News new | ask | show | jobs
by roflyear 1258 days ago
> I'm not fond of having my web server running things in the background it ruins my mental model of the web.

Well yes, and you run into other problems as well (now if your process dies or you deploy or something you have to be careful to not kill running jobs).

How much of your logic is in the azure function?

1 comments

Only things that needed to be done behind the scenes that could take a long time, like we would take JTIFFs that could be gigs of data, and analyze them and create variations of the same image. You don't want someone who just uploaded a 1GB file waiting for you to also analyze it as well.
Eh, yeah, I just don't like any real logic being in those types of systems. Just too hard to test and chase down issues.

I guess "convert this image" is ok, since it is kind of a "pure function" sorta.

Correct, I only use them for very specific needs where it would slow down my website, or be weird to spin off a new thread in the background. I do know Azure supports WebJobs which is probably the closest you can get to something like Celery, which funnily enough, is what Azure Functions (at least originally) are built on top of.