We have started working with Temporal with spring
our flow goes like this :
controller → service → temporal WorkflowImpl ->ActivityImpl → service
so if we set some value in ThreadLocal at controller layer , still we could get the same at ActivityImpl
how is it possible?
Could you please help us understanding how threads work ? whether at workflowImpl level new threads are created ? As while logging we could see that thread names are different at service layer and workflow layers.
One more question :
How can I invoke this workflow synchronously?
WorkflowStub stub = workflowClient.newUntypedWorkflowStub("createUser", options); stub.start(user , null, null);
below code works as expected , but I need to invoke untyped workflow synchronously
HelloWorldWorkflow workflow = client.newWorkflowStub(HelloWorldWorkflow.class, options); // Synchronously execute the Workflow and wait for the response. String greeting = workflow.getGreeting("World");