Skip to content

Commit 8041a86

Browse files
committed
Refactor activity triggers to include input parameters and comment out waiting logic in orchestrator
1 parent 958c193 commit 8041a86

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

samples-v2/orchestration_versioning/function_app.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,9 @@ def my_orchestrator(context: df.DurableOrchestrationContext):
3333
activity_result = yield context.call_activity('activity_b')
3434

3535
# Provide an opportunity to update and restart the app
36-
context.set_custom_status("Waiting for Continue event...")
37-
yield context.wait_for_external_event("Continue")
38-
context.set_custom_status("Continue event received")
36+
# context.set_custom_status("Waiting for Continue event...")
37+
# yield context.wait_for_external_event("Continue")
38+
# context.set_custom_status("Continue event received")
3939

4040
# New sub-orchestrations will use the current defaultVersion specified in host.json
4141
sub_result = yield context.call_sub_orchestrator('my_sub_orchestrator')
@@ -45,10 +45,10 @@ def my_orchestrator(context: df.DurableOrchestrationContext):
4545
def my_sub_orchestrator(context: df.DurableOrchestrationContext):
4646
return context.version
4747

48-
@myApp.activity_trigger()
49-
def activity_a() -> str:
48+
@myApp.activity_trigger(input_name="input")
49+
def activity_a(input: str) -> str:
5050
return f"Hello from A!"
5151

52-
@myApp.activity_trigger()
53-
def activity_b() -> str:
54-
return f"Hello from B!"
52+
@myApp.activity_trigger(input_name="input")
53+
def activity_b(input: str) -> str:
54+
return f"Hello from B!"

0 commit comments

Comments
 (0)