An abstract class defines the global life-cycle hooks to be implemented by customer's extension, will be applied to all functions.
An AppExtension should be treated as a static class. Must not contain init method since it is not instantiable.
Please place your initialization code in init() classmethod, consider accepting extension settings in configure() classmethod from customers.
AsgiFunctionAppConstructor of AsgiFunctionApp object.
present on the request in order to invoke the function. :param function_name: function name
AsgiMiddlewareThis middleware is to adapt an ASGI supported Python server framework into Azure Functions. It can be used by either calling the .handle() function or exposing the .main property in a HttpTrigger.
Instantiate an ASGI middleware to convert Azure Functions HTTP request into ASGI Python object. Example on handling ASGI app in a HTTP trigger by overwriting the .main() method:
import azure.functions as func
from FastapiApp import app
main = func.AsgiMiddleware(app).main
BindingApiInterface to extend for using existing binding decorator functions.
BlueprintFunctions container class where all the functions loaded in it can be registered in FunctionRegister subclasses but itself can not be indexed directly. The class contains all existing supported trigger and binding decorator functions.
ContextFunction invocation context.
DecoratorApiInterface which contains essential decorator function building blocks to extend for creating new function app or blueprint classes.
DocumentAn Azure Document.
Document objects are UserDict
subclasses and behave like dicts.
A UserList
subclass containing a list of Document objects
A durable function entity context.
EventGridEventAn EventGrid event message.
EventGridOutputEventAn EventGrid event message.
EventHubEventA concrete implementation of Event Hub message type.
ExtensionMetaThe metaclass handles extension registration.
AppExtension is registered in init, it is applied to all triggers. FuncExtension is registered in call, as users need to instantiate it inside hook script.
After registration, the extension class will be flatten into the following structure to speed up worker lookup:
_func_exts[<trigger_name>].<hook_name>.(ext_name, ext_impl) (e.g. _func_exts['HttpTrigger'].pre_invocation.ext_impl)
_app_exts.<hook_name>.(ext_name, ext_impl) (e.g. _app_exts.pre_invocation_app_level.ext_impl)
The extension tree information is stored in _info for diagnostic purpose. The dictionary is serializable to json:
_info['FuncExtension']['<Trigger>'] = list(<Extension>) _info['AppExtension'] = list(<Extension>)
Executes on 'import extension', once the AppExtension class is loaded, call the setup() method and add the life-cycle hooks into _app_exts.
ExternalHttpFunctionAppInterface to extend for building third party http function apps.
Interface for declaring top level function app class which will be directly indexed by Python Function runtime.
on the request in order to invoke the function. :param args: Variable length argument list. :param kwargs: Arbitrary keyword arguments.
FuncExtensionBaseAn abstract class defines the life-cycle hooks which to be implemented by customer's extension.
Everytime when a new extension is initialized in customer function scripts, the ExtensionManager._func_exts field records the extension to this specific function name.
Constructor for extension. This needs to be implemented and ensure super().init(file_path) is called.
The initializer serializes the extension to a tree. This speeds up the worker lookup and reduce the overhead on each invocation. _func_exts[<trigger_name>].<hook_name>.(ext_name, ext_impl) (e.g. _func_exts['HttpTrigger'].pre_invocation.ext_impl)
FunctionThe function object represents a function in Function App. It encapsulates function metadata and callable and used in the worker function indexing model. Ref: https://aka.ms/azure-function-ref
Constructor of <xref:azure.functions.FunctionBuilder> object.
FunctionAppFunctionApp object used by worker function indexing model captures user defined functions and metadata.
Ref: https://aka.ms/azure-function-ref
Constructor of FunctionApp object.
present on the request in order to invoke the function.
FunctionExtensionExceptionException emitted from Azure Functions Python Worker extension
FunctionRegisterInterface for declaring top level function app class which will be directly indexed by Python Function runtime.
on the request in order to invoke the function. :param args: Variable length argument list. :param kwargs: Arbitrary keyword arguments.
HttpRequestAn HTTP request object.
HttpResponseAn HTTP response object.
InputStreamFile-like object representing an input blob.
KafkaConverter KafkaEventA concrete implementation of Kafka event message type.
KafkaTriggerConverter OrchestrationContextA durable function orchestration context.
OutAn interface to set function output parameters.
QueueMessageA Queue message object.
ServiceBusMessageA ServiceBuss message object.
SettingsApiInterface to extend for using existing settings decorator in functions.
SqlRowA SQL Row.
SqlRow objects are ''UserDict'' subclasses and behave like dicts.
SqlRowListA ''UserList'' subclass containing a list of :class:'~SqlRow' objects
TimerRequestTimer request object.
TriggerApiInterface to extend for using existing trigger decorator functions.
WsgiFunctionAppConstructor of WsgiFunctionApp object.
WsgiMiddlewareThis middleware is to adapt a WSGI supported Python server framework into Azure Functions. It can be used by either calling the .handle() function or exposing the .main property in a HttpTrigger.
Instantiate a WSGI middleware to convert Azure Functions HTTP request into WSGI Python object. Example on handling WSGI app in a HTTP trigger by overwriting the .main() method:
import azure.functions as func
from FlaskApp import app
main = func.WsgiMiddleware(app.wsgi_app).main
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4