diff --git a/internal/convertor/device/device.go b/internal/convertor/device/device.go index 7f7af72..55a4752 100644 --- a/internal/convertor/device/device.go +++ b/internal/convertor/device/device.go @@ -14,6 +14,7 @@ import ( "github.com/criteo/data-aggregation-api/internal/model/dcim" "github.com/criteo/data-aggregation-api/internal/model/openconfig" "github.com/openconfig/ygot/ygot" + "github.com/rs/zerolog/log" ) const AFKEnabledTag = "afk-enabled" @@ -73,7 +74,7 @@ func NewDevice(dcimInfo *dcim.NetworkDevice, devicesData *repository.AssetsPerDe device.PeerGroups, ok = devicesData.PeerGroups[dcimInfo.Hostname] if !ok { - return nil, fmt.Errorf("no peer-groups found for %s", dcimInfo.Hostname) + log.Warn().Msgf("no peer-groups found for %s", dcimInfo.Hostname) } device.PrefixLists, ok = devicesData.PrefixLists[dcimInfo.Hostname] diff --git a/internal/model/cmdb/bgp/global.go b/internal/model/cmdb/bgp/global.go index 3775409..238ef12 100644 --- a/internal/model/cmdb/bgp/global.go +++ b/internal/model/cmdb/bgp/global.go @@ -14,5 +14,5 @@ type BGPGlobal struct { GracefulRestartTime *uint16 `json:"graceful_restart_time" validate:"omitempty"` EcmpEnabled *bool `json:"ecmp" validate:"required"` EcmpMaximumPaths *uint32 `json:"ecmp_maximum_paths" validate:"omitempty"` - RouterID string `json:"router_id" validate:"required"` + RouterID string `json:"router_id" validate:"omitempty"` }