mardi 30 janvier 2018

Multiple Inputs To Azure Function

TLDR:

Is it possible to have multiple inputs to an Azure Function?

Longer Explanation:

I'm new to Azure Functions and still don't have a good understanding of it.

I have an application which downloads HTML data through a proxy web request and I was considering moving it to Azure Functions.

However, the function would require two inputs: a string URL and a proxy object (which contains IP address, username and password properties).

I was thinking of having two queues, one for URLs and one for proxies.

URLs would be added to the queue by a client application, which would trigger the function.

The proxy queue would have a limited pool of proxy objects which would be added back into the queue by the consuming function after they had been used for the web request.

So, if there are no proxies in the proxy queue, the function will not be able to create a web request until one is added back into the queue.

This is all assuming that Azure Functions are parallel and every trigger from the URL queue runs a function on another thread.

So, is what I'm considering possible? If not, is there an alternative way that I could go about it?




Aucun commentaire:

Enregistrer un commentaire