Setting up a standalone server as a go application with Postgres

Hi,

I’d like to set up a standalone server as a go application like described in https://docs.temporal.io/docs/server-options

My goal is to have one temporal server (extending it to two instances later). I have a postgres instance running on localhost and ran install-schema-postgresql successfuly. When I run the application I get the following error log:

2021/02/15 16:30:39 Loading config; env=development,zone=,configDir=config
2021/02/15 16:30:39 Loading config files=[config/development.yaml]
{"level":"info","ts":"2021-02-15T16:30:39.462+0100","msg":"Starting server for services","value":"[frontend history matching worker]","logging-call-at":"server.go:110"}
{"level":"info","ts":"2021-02-15T16:30:39.512+0100","msg":"Error creating file based dynamic config client, use no-op config client instead.","error":"error checking dynamic config file at path , error: stat : no such file or directory","logging-call-at":"server.go:130"}
{"level":"info","ts":"2021-02-15T16:30:39.512+0100","msg":"PProf listen on ","port":7936,"logging-call-at":"pprof.go:74"}
{"level":"info","ts":"2021-02-15T16:30:39.513+0100","msg":"Get dynamic config","name":"history.persistenceMaxQPS","value":"3000","default-value":"3000","logging-call-at":"config.go:79"}
{"level":"warn","ts":"2021-02-15T16:30:39.526+0100","msg":"Failed to save cluster metadata: SaveClusterMetadata operation failed. Error: pq: current transaction is aborted, commands ignored until end of transaction block","component":"metadata-initializer","logging-call-at":"server.go:411"}
2021/02/15 16:30:39 unable to initialize cluster metadata: error while fetching cluster metadata: GetClusterMetadata failed. Error: sql: no rows in result set 

Indeed, the cluster_metadata table is empty. Is there a step that I’m missing? Is there a step by step tutorial for such a usecase?

Thanks in advance

git checkout v1.6.4
make install-schema-postgresql

do not ever use the master branch

1 Like