![]() ![]() ![]() In your readme file, you can tell your customers when they need to call nfigure(). In this case, a hash map is initialized for recording the invocation start time for each function. You can do initialization actions here for the extension. The init method is a class method that's called by the worker when the extension class is imported. You could have also implemented the extension on a function-level scope by inheriting from FuncExtensionBase. This code inherits from AppExtensionBase so that the extension applies to every function in the app. ![]() (f'Recording start time of sec)'.encode() To make sure that your extension is distributed and integrated into your customer's function apps properly, confirm that 'azure-functions >= 1.7.0, = 1.7.0, None: This content is displayed as the description in the home page in your PyPI project.įirst you create setup.py, which provides essential information about your package. (Optional) Contains the instruction and usage of your extension. This folder contains the main Python module to be published into PyPI.Ĭontains the metadata of the Python worker extension package. (Optional) Contains a Python virtual environment used for local development.Ĭontains the source code of the Python worker extension. The folder for your extension project should be like the following structure: / The extension you create reports the elapsed time of an HTTP trigger invocation in the console logs and in the HTTP response body. Visual Studio Code installed on one of the supported platforms. The Azure Functions Core Tools, version or later. To check the full list of supported Python versions in Azure Functions, see the Python developer guide. Package and publish an extension for consumption.īefore you start, you must meet these requirements:.Consume your extension in an app the way your customers do.Create an application-level Python worker extension for Azure Functions. ![]()
0 Comments
Leave a Reply. |