Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 31 additions & 0 deletions entity-types/infra-ocinatgateway/definition.stg.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
domain: INFRA
type: OCINATGATEWAY
goldenTags:
- oci.compartmentId
- oci.displayName
- oci.lifecycleState
- oci.region
configuration:
entityExpirationTime: DAILY
alertable: true
synthesis:
tags:
newrelic.cloudIntegrations.providerAccountName:
entityTagNames: [newrelic.cloudIntegrations.providerAccountName, providerAccountName]
multiValue: false
rules:
- ruleName: infra_ocinatgateway_oci_resourceId
identifier: oci.resourceId
name: oci.resourceName
legacyFeatures:
overrideGuidType: true
encodeIdentifierInGUID: true
conditions:
- attribute: oci.resourceId
prefix: "ocid1.natgateway"
- attribute: oci.namespace
value: "oci_nat_gateway"

ownership:
primaryOwner:
teamName: "Cloud Monitoring Platform"
36 changes: 36 additions & 0 deletions entity-types/infra-ocinatgateway/golden_metrics.stg.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
bytesFromNatGateway:
title: Bytes From NAT Gateway
unit: BYTES
queries:
oci:
select: sum(`oci.nat.gateway.bytes.from.natgw`)
from: Metric
eventId: entity.guid
eventName: entity.name
bytesToNatGateway:
title: Bytes To NAT Gateway
unit: BYTES
queries:
oci:
select: sum(`oci.nat.gateway.bytes.to.natgw`)
from: Metric
eventId: entity.guid
eventName: entity.name
connectionsEstablished:
title: Connections Established
unit: COUNT
queries:
oci:
select: sum(`oci.nat.gateway.connections.established`)
from: Metric
eventId: entity.guid
eventName: entity.name
dropsToNatGateway:
title: Drops To NAT Gateway
unit: COUNT
queries:
oci:
select: sum(`oci.nat.gateway.drops.to.natgw`)
from: Metric
eventId: entity.guid
eventName: entity.name
21 changes: 21 additions & 0 deletions entity-types/infra-ocinatgateway/summary_metrics.stg.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
providerAccountName:
tag:
key: providerAccountName
title: OCI account
unit: STRING
bytesFromNatGateway:
goldenMetric: bytesFromNatGateway
unit: BYTES
title: Bytes From NAT Gateway
bytesToNatGateway:
goldenMetric: bytesToNatGateway
unit: BYTES
title: Bytes To NAT Gateway
connectionsEstablished:
goldenMetric: connectionsEstablished
unit: COUNT
title: Connections Established
dropsToNatGateway:
goldenMetric: dropsToNatGateway
unit: COUNT
title: Drops To NAT Gateway
25 changes: 25 additions & 0 deletions entity-types/infra-ocinatgateway/tests/Metric.stg.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
[
{
"oci.compartmentId": "ocid1.compartment.oc1..aaaaaaaabbbbbbccccccccdddddddeeeeeeefffffffgggggggghhhhhhhhiiiiiiiiijjjjjjjj",
"oci.namespace": "oci_nat_gateway",
"oci.region": "us-ashburn-1",
"oci.resourceId": "ocid1.natgateway.oc1.us-ashburn-1.aaaaaaaabbbbbbccccccccdddddddeeeeeeefffffffgggggggghhhhhhhhiiiiiiiiijjjjjjjj",
"oci.resourceName": "test-nat-gateway",
"oci.lifecycleState": "AVAILABLE",
"collector.name": "oci-monitor",
"collector.version": "release-007",
"displayName": "test-nat-gateway",
"endTimestamp": 1746680903,
"instrumentation.provider": "oci",
"metricName": "oci.nat.gateway.bytes.from.natgw",
"newrelic.cloudIntegrations.integrationId": "1",
"newrelic.cloudIntegrations.integrationName": "OCI Monitor metrics",
"newrelic.cloudIntegrations.providerAccountId": "1",
"newrelic.cloudIntegrations.providerAccountName": "oci-dev-all-metrics",
"newrelic.cloudIntegrations.providerExternalId": "9bcb5134-f0a6-11ed-a05b-0242ac120003",
"newrelic.source": "metricAPI",
"nr.entity.id": "-2281987194047346712",
"tags.owner": "test",
"timestamp": 1746680903
}
]
Loading