From 4009d62bebdf1049ba58fdad17f464b75023d195 Mon Sep 17 00:00:00 2001 From: Christopher Zell Date: Thu, 14 Mar 2019 13:34:50 +0100 Subject: [PATCH] chore(examples): update examples --- Client.Examples/Program.cs | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Client.Examples/Program.cs b/Client.Examples/Program.cs index 027d3873..00a26256 100644 --- a/Client.Examples/Program.cs +++ b/Client.Examples/Program.cs @@ -36,17 +36,23 @@ public static async Task Main(string[] args) // create zeebe client var client = ZeebeClient.NewZeebeClient(ZeebeUrl); + + await client.NewPublishMessageCommand().MessageName("csharp").CorrelationKey("wow").Variables("{\"realValue\":2}").Send(); + // deploy var deployResponse = await client.NewDeployCommand().AddResourceFile(DemoProcessPath).Send(); // create workflow instance var workflowKey = deployResponse.Workflows[0].WorkflowKey; - await client + var workflowInstance = await client .NewCreateWorkflowInstanceCommand() .WorkflowKey(workflowKey) .Variables(WorkflowInstanceVariables) .Send(); + + await client.NewSetVariablesCommand(workflowInstance.WorkflowInstanceKey).Variables("{\"wow\":\"this\"}").Local().Send(); + // open job worker using (var signal = new EventWaitHandle(false, EventResetMode.AutoReset)) {