20559: Test concurrent writes using same token.
[arvados.git] / services / ws / service.go
index 761e22e16c2cd4fd5025341e9ad284eb74b6f8c7..d6501e0771d59dab816d2d31fdf000770bad18fe 100644 (file)
@@ -7,6 +7,7 @@ package ws
 import (
        "context"
        "fmt"
+       "time"
 
        "git.arvados.org/arvados.git/lib/cmd"
        "git.arvados.org/arvados.git/lib/service"
@@ -24,6 +25,7 @@ func newHandler(ctx context.Context, cluster *arvados.Cluster, token string, reg
        if err != nil {
                return service.ErrorHandler(ctx, cluster, fmt.Errorf("error initializing client from cluster config: %s", err))
        }
+       client.Timeout = time.Minute
        eventSource := &pgEventSource{
                DataSource:   cluster.PostgreSQL.Connection.String(),
                MaxOpenConns: cluster.PostgreSQL.ConnectionPool,