![]() ![]() Azure functions are fast to execute because there is no large application, startup time, initialization, and other events fired before the code is executed.You don’t need a large team of developers to do that. Because of the nature of the Azure functions, they are easy to code, test, debug, and deploy. Azure functions are easier to write and deploy.You can deploy Azure functions in any kind of configurations including Linux, Windows, or containers but Azure functions are available and can be consumed from any applications as long as they have access to the function. Azure functions are platform agnostic and run in their own process and environment.Azure functions are serverless and do not require any Web servers or virtual machines to deploy and run. An Azure functions app is designed to a specific task and hence it is lightweight by design. Azure functions are lightweight and serverless.When demand of execution increases, more resources are allocated automatically to the service and when requests fall, all extra resources and application instances drop off automatically. Azure functions uses compute-on-demand, which is scalable by design. You can deploy and execute Azure functions on any platform that can run. You can write an Azure functions in one of the popular programming languages including C#, Java, JavaScript, TypeScript, and Python. Azure functions is platform and language agnostic. Azure functions is a piece of code that is written to do a specific tasks. Azure functions are language independent.Here is where I want to start watching the folder represented by rootDir. RootDir = share.GetRootDirectoryReference() Get a reference to the root directory for the share. Share = fileClient.GetShareReference(sharenameString) String sharenameString = CloudConfigurationManager.GetSetting("") Obtain the file share name from the config file Create a CloudFileClient object for credentialed access to File storage.įileClient = storageAccount.CreateCloudFileClient() What I have so far is basically this (a snippet of a larger code base): storageAccount = CloudStorageAccount.Parse(CloudConfigurationManager.GetSetting("StorageConnectionString")) It should be noted that I am using VS2015, and the latest Azure SDK stuff, so I'm not limited by anything legacy. So I intend to have a "Watcher" service which will (via events or polling) detect the presence of one or more files, and push a message onto the appropriate queue for the next step in my workflow to respond to. It is important to note that I have no control over the inputs - in other words the files are saved by an external device over which I have no control so I can't, for example, push a message onto a queue when the file is saved, and respond to that message.Īlthough, in the end, that's the goal. I am aware I could create a timer (or sleep) to pass some time (say 30 seconds), and poll the folder, but I'm just not sure that's the "best" way in a cloud environment. In the world of Azure, what is the equivalent way to do this? Or is there? In the current state of my system under Windows, I have a FileSystemWatcher set up to monitor a folder and raise an event when a file appears there. I have a number of (external, and outside of my control) sources that can all save files to a folder (or possibly a set of folders). I am an experienced windows C# developer, but new to the world of Azure, and so trying to figure out a "best practice" as I implement one or more Azure Cloud Services.
0 Comments
Leave a Reply. |