Skip to content

Commit

Permalink
chore(aws): cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
adityathebe authored and moshloop committed Jun 27, 2024
1 parent eb5124e commit bd0c990
Show file tree
Hide file tree
Showing 5 changed files with 143 additions and 56 deletions.
6 changes: 3 additions & 3 deletions api/v1/aws.go
Original file line number Diff line number Diff line change
Expand Up @@ -44,9 +44,9 @@ type CostReporting struct {

const (
AWSECSCluster = "AWS::ECS::Cluster"
AWSECSService = "AWS::EC2::Service"
AWSECSTask = "AWS::ECS:Task"
AWSEKSFargateProfile = "AWS::ECS::FargateProfile"
AWSECSService = "AWS::ECS::Service"
AWSECSTaskDefinition = "AWS::ECS::TaskDefinition"
AWSEKSFargateProfile = "AWS::EKS::FargateProfile"
AWSElastiCacheCluster = "AWS::ElastiCache::CacheCluster"
AWSLambdaFunction = "AWS::Lambda::Function"
AWSSNSTopic = "AWS::SNS::Topic"
Expand Down
5 changes: 3 additions & 2 deletions db/update.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ import (
"github.com/dominikbraun/graph"
jsonpatch "github.com/evanphx/json-patch"
"github.com/flanksource/commons/logger"
cUtils "github.com/flanksource/commons/utils"
"github.com/flanksource/config-db/api"
v1 "github.com/flanksource/config-db/api/v1"
"github.com/flanksource/config-db/db/models"
Expand Down Expand Up @@ -569,7 +570,7 @@ func relationshipResultHandler(ctx api.ScrapeContext, relationships v1.Relations
continue
}
if configID == "" {
ctx.Logger.V(1).Infof("unable to form relationship. failed to find the parent config %s", relationship.ConfigExternalID)
ctx.Logger.V(2).Infof("unable to form relationship. failed to find the parent config %s for config %s", relationship.ConfigExternalID, cUtils.Coalesce(relationship.RelatedConfigID, relationship.RelatedExternalID.String()))
continue
}
}
Expand All @@ -584,7 +585,7 @@ func relationshipResultHandler(ctx api.ScrapeContext, relationships v1.Relations
continue
}
if relatedID == "" {
logger.V(6).Infof("related external config item(id=%s) not found.", relationship.RelatedExternalID)
ctx.Logger.V(2).Infof("unable to form relationship. failed to find related config %s for config %s", relationship.RelatedExternalID, configID)
continue
}
}
Expand Down
Loading

0 comments on commit bd0c990

Please sign in to comment.