diff --git a/pkg/gateway/client.go b/pkg/gateway/client.go index 25de0ab..099565b 100644 --- a/pkg/gateway/client.go +++ b/pkg/gateway/client.go @@ -268,7 +268,7 @@ func newKongAPI( endpoints []apic.EndpointDefinition, ) KongAPI { return KongAPI{ - id: *route.ID, + id: *service.Name, name: *service.Name, description: oasSpec.Description(), version: oasSpec.Version(), @@ -333,15 +333,3 @@ func isPublished(api *KongAPI, c cache.Cache) (bool, string) { } return true, checksum } - -func isValidAuthTypeAndEnabled(p *klib.Plugin) bool { - if !*p.Enabled { - return false - } - for _, availableAuthName := range []string{"basic-auth", "oauth2", "key-auth"} { - if *p.Name == availableAuthName { - return true - } - } - return false -} diff --git a/pkg/traceability/processor/metrics.go b/pkg/traceability/processor/metrics.go index c0f8652..ba6b2ee 100644 --- a/pkg/traceability/processor/metrics.go +++ b/pkg/traceability/processor/metrics.go @@ -54,7 +54,7 @@ func (m *MetricsProcessor) process(entry TrafficLogEntry) (bool, error) { func (m *MetricsProcessor) updateMetric(entry TrafficLogEntry) { apiDetails := models.APIDetails{ - ID: entry.Route.ID, + ID: entry.Service.Name, Name: entry.Service.Name, Stage: entry.Route.Name, } diff --git a/pkg/traceability/processor/transaction.go b/pkg/traceability/processor/transaction.go index 7ec8fcc..024c1c8 100644 --- a/pkg/traceability/processor/transaction.go +++ b/pkg/traceability/processor/transaction.go @@ -132,7 +132,7 @@ func createSummaryEvent(ktle TrafficLogEntry, teamID string, txnid string) (*tra SetTeam(teamID). SetEntryPoint(ktle.Service.Protocol, ktle.Request.Method, ktle.Request.URI, ktle.Request.URL). SetDuration(ktle.Latencies.Request). - SetProxyWithStage(sdkUtil.FormatProxyID(ktle.Route.ID), ktle.Service.Name, ktle.Route.Name, 1) + SetProxyWithStage(sdkUtil.FormatProxyID(ktle.Service.Name), ktle.Service.Name, ktle.Route.Name, 1) if ktle.Consumer != nil { builder.SetApplication(sdkUtil.FormatApplicationID(ktle.Consumer.ID), ktle.Consumer.Username)