You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I need help setting up a project structure for my scenario - 3 different functions deployed in a single Azure Functions App. As far as I know, the only way to do so is to put all code logic of 3 functions as well as triggers in a single function_app.py, which is impractical from code maintainability and scalability perspectives. Something like the one below will work, but I don't think I'd go with it.
app=func.FunctionApp()
@app.schedule(schedule="0 0 2 * * *", arg_name="myTimer", run_on_startup=True,use_monitor=False)defFunctionA(myTimer: func.TimerRequest) ->None:
do_something_for_functionA()
ifmyTimer.past_due:
logging.info('The timer is past due!')
logging.info('Python timer trigger function executed.')
@app.schedule(schedule="0 0 2 * * *", arg_name="myTimer", run_on_startup=True,use_monitor=False)defFunctionB(myTimer: func.TimerRequest) ->None:
do_something_for_functionB()
ifmyTimer.past_due:
logging.info('The timer is past due!')
logging.info('Python timer trigger function executed.')
@app.schedule(schedule="0 0 2 * * *", arg_name="myTimer", run_on_startup=True,use_monitor=False)defFunctionC(myTimer: func.TimerRequest) ->None:
do_something_for_functionC()
ifmyTimer.past_due:
logging.info('The timer is past due!')
logging.info('Python timer trigger function executed.')
I need something more management and organized like below one (if possible):
Hi all,
I need help setting up a project structure for my scenario - 3 different functions deployed in a single Azure Functions App. As far as I know, the only way to do so is to put all code logic of 3 functions as well as triggers in a single
function_app.py
, which is impractical from code maintainability and scalability perspectives. Something like the one below will work, but I don't think I'd go with it.I need something more management and organized like below one (if possible):
The text was updated successfully, but these errors were encountered: