From 3926db94c91c0ad0beda97cb728425eac39c5531 Mon Sep 17 00:00:00 2001 From: ygg-drop <108284637+ygg-drop@users.noreply.github.com> Date: Fri, 22 Dec 2023 17:06:05 +0100 Subject: [PATCH] Initialize Ceph connection during provider config Fix a race condition when multiple resources call GetCephConnection() in parallel which can result in a misleading "rados: ret=-110, Connection timed out" error. --- ceph/provider.go | 1 + 1 file changed, 1 insertion(+) diff --git a/ceph/provider.go b/ceph/provider.go index 0631af3..4f37b59 100644 --- a/ceph/provider.go +++ b/ceph/provider.go @@ -60,5 +60,6 @@ func providerConfigure(d *schema.ResourceData) (interface{}, error) { MonHost: d.Get("mon_host").(string), } + config.GetCephConnection() return config, nil }