@opentelemetry/resource-detector-gcp
Advanced tools
Comparing version 0.16.1-alpha.18 to 0.16.1-alpha.20
@@ -1,2 +0,2 @@ | ||
import { Detector, ResourceDetectionConfigWithLogger, Resource } from '@opentelemetry/resources'; | ||
import { Detector, ResourceDetectionConfig, Resource } from '@opentelemetry/resources'; | ||
/** | ||
@@ -14,5 +14,5 @@ * The GcpDetector can be used to detect if a process is running in the Google | ||
* | ||
* @param config The resource detection config with a required logger | ||
* @param config The resource detection config | ||
*/ | ||
detect(config: ResourceDetectionConfigWithLogger): Promise<Resource>; | ||
detect(_config?: ResourceDetectionConfig): Promise<Resource>; | ||
/** Add resource attributes for K8s */ | ||
@@ -19,0 +19,0 @@ private _addK8sAttributes; |
@@ -21,2 +21,3 @@ "use strict"; | ||
const gcpMetadata = require("gcp-metadata"); | ||
const api_1 = require("@opentelemetry/api"); | ||
const resources_1 = require("@opentelemetry/resources"); | ||
@@ -36,8 +37,8 @@ const core_1 = require("@opentelemetry/core"); | ||
* | ||
* @param config The resource detection config with a required logger | ||
* @param config The resource detection config | ||
*/ | ||
async detect(config) { | ||
async detect(_config) { | ||
if (!semver.satisfies(process.version, '>=10') || | ||
!(await gcpMetadata.isAvailable())) { | ||
config.logger.debug('GcpDetector failed: GCP Metadata unavailable.'); | ||
api_1.diag.debug('GcpDetector failed: GCP Metadata unavailable.'); | ||
return resources_1.Resource.empty(); | ||
@@ -44,0 +45,0 @@ } |
{ | ||
"name": "@opentelemetry/resource-detector-gcp", | ||
"version": "0.16.1-alpha.18+9f965b0c", | ||
"version": "0.16.1-alpha.20+62f8695d", | ||
"description": "OpenTelemetry SDK resource detector for GCP", | ||
@@ -42,3 +42,3 @@ "main": "build/src/index.js", | ||
"devDependencies": { | ||
"@opentelemetry/core": "^0.16.1-alpha.18+9f965b0c", | ||
"@opentelemetry/core": "^0.16.1-alpha.20+62f8695d", | ||
"@types/mocha": "8.2.0", | ||
@@ -58,8 +58,8 @@ "@types/node": "14.14.20", | ||
"dependencies": { | ||
"@opentelemetry/api": "^0.16.0", | ||
"@opentelemetry/resources": "^0.16.1-alpha.18+9f965b0c", | ||
"@opentelemetry/api": "^0.16.1-alpha.20+62f8695d", | ||
"@opentelemetry/resources": "^0.16.1-alpha.20+62f8695d", | ||
"gcp-metadata": "^4.1.4", | ||
"semver": "7.3.4" | ||
}, | ||
"gitHead": "9f965b0c749108df00bbe44eeab84d79b04bb0a4" | ||
"gitHead": "62f8695d3fe5309c62418a1043bc6e8a176bc11f" | ||
} |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Manifest confusion
Supply chain riskThis package has inconsistent metadata. This could be malicious or caused by an error when publishing the package.
Found 1 instance in 1 package
222
- Removed@opentelemetry/api@0.16.0(transitive)