Closed donchev7 closed 3 months ago
On Mac with the same Go Version I am not able to reproduce this at least with
temporal --version
temporal version 0.13.2 (server 1.24.1) (ui 2.28.0)
My only idea would be something interfering with resolving localhost
. Could try using the IP of your server or try passthrough:///localhost:7233
?
do you mind trying with:
temporal --version
temporal version 0.13.1 (server 1.24.1) (ui 2.27.3)
No issue with temporal version 0.13.1
You were right. Now at my hotel I can't reproduce the issue. It must have been a networking issue at the client. Closing for now.
Thank you.
Expected Behavior
Be able to connect to temporal server
Actual Behavior
2024/07/17 14:00:20 Unable to create client failed reaching server: context deadline exceeded
Steps to Reproduce the Problem
import ( "context" "fmt" "log" "time"
)
type Activities struct { Name string Greeting string }
// GetGreeting Activity. func (a *Activities) GetGreeting() (string, error) { return a.Greeting, nil }
// @@@SNIPEND
// GetName Activity. func (a *Activities) GetName() (string, error) { return a.Name, nil }
func GreetingSample(ctx workflow.Context) (string, error) { logger := workflow.GetLogger(ctx)
}
// SayGreeting Activity. func (a *Activities) SayGreeting(greeting string, name string) (string, error) { result := fmt.Sprintf("Greeting: %s %s!\n", greeting, name) return result, nil }
func main() { // The client is a heavyweight object that should be created once per process. c, err := client.Dial(client.Options{ HostPort: client.DefaultHostPort, }) if err != nil { log.Fatalln("Unable to create client", err) } defer c.Close()
}
➜ go run main.go 2024/07/17 14:04:16 INFO No logger configured for temporal client. Created default one. 2024/07/17 14:04:16 Started workflow WorkflowID greetings_dcf4cf08-cb31-4460-ac0d-cddb7e2f164d RunID 2f4a0e00-7fa9-4bb2-bd64-5f12473cc5c8