Fixing worker for temporal
@@ -17,13 +17,7 @@ import (
"context"
"time"
-<<<<<<< HEAD
-<<<<<<< HEAD
-=======
->>>>>>> Updates to workflows to be compatible with pluggable components changes
- "github.com/zouyx/agollo/v3/component/log"
-=======
->>>>>>> Initial creation of workflows building block
+ "fortio.org/fortio/log"
"go.temporal.io/sdk/activity"
"go.temporal.io/sdk/client"
"go.temporal.io/sdk/worker"
@@ -42,10 +36,7 @@ func main() {
// Create the workflow client
clientTwo, err := client.Dial(cOpt)
if err != nil {
-<<<<<<< HEAD
log.Error("Unable to create client.")
-=======
->>>>>>> Initial creation of workflows building block
return
}
wOpt := worker.Options{}
@@ -58,10 +49,7 @@ func main() {
err = w.Start()
if err != nil {
-<<<<<<< HEAD
log.Error("Unable to start worker.")
-=======
->>>>>>> Initial creation of workflows building block
return
}
w.Run(worker.InterruptCh())
@@ -78,15 +66,9 @@ func TestWorkflow(ctx workflow.Context, runtimeSeconds int) error {
}
ctx = workflow.WithActivityOptions(ctx, options)
-<<<<<<< HEAD
err := workflow.ExecuteActivity(ctx, ExampleActivity, runtimeSeconds).Get(ctx, nil)
if err != nil {
log.Error("Unable to execute activity.")
-=======
- newCtx, _ := workflow.NewDisconnectedContext(ctx)
- err := workflow.ExecuteActivity(newCtx, ExampleActivity, runtimeSeconds).Get(ctx, nil)
- if err != nil {
->>>>>>> Initial creation of workflows building block
return err
}
