From dc6fb58b2671524c3a8db01af88c9ad1d50bc661 Mon Sep 17 00:00:00 2001 From: Mengling Ding Date: Tue, 10 Dec 2024 16:26:21 -0600 Subject: [PATCH] fix: remove the redundant code --- cmd/cfm-service/main.go | 8 -------- 1 file changed, 8 deletions(-) diff --git a/cmd/cfm-service/main.go b/cmd/cfm-service/main.go index a5d642c..2ef87d4 100644 --- a/cmd/cfm-service/main.go +++ b/cmd/cfm-service/main.go @@ -68,14 +68,6 @@ func main() { defaultRedfishController := redfishapi.NewDefaultAPIController(defaultRedfishService) api.AddRedfishRouter(ctx, router, defaultRedfishController) - // Discover devices before loading datastore - bladeDevices, errBlade := services.DiscoverDevices(ctx, defaultApiService, "blade") - hostDevices, errHost := services.DiscoverDevices(ctx, defaultApiService, "cxl-host") - // Add the discovered devices into datastore - if errBlade == nil && errHost == nil { - services.AddDiscoveredDevices(ctx, defaultApiService, bladeDevices, hostDevices) - } - // Load datastore datastore.DStore().Restore() data := datastore.DStore().GetDataStore()