@opentelemetry/resources
Advanced tools
Comparing version 0.23.1-alpha.23 to 0.23.1-alpha.24
@@ -54,3 +54,3 @@ /* | ||
import { getEnv } from '@opentelemetry/core'; | ||
import { ResourceAttributes as SemanticResourceAttributes } from '@opentelemetry/semantic-conventions'; | ||
import { SemanticResourceAttributes } from '@opentelemetry/semantic-conventions'; | ||
import { Resource, } from '../../../'; | ||
@@ -57,0 +57,0 @@ /** |
@@ -64,3 +64,3 @@ /* | ||
import { diag } from '@opentelemetry/api'; | ||
import { ResourceAttributes as SemanticResourceAttributes } from '@opentelemetry/semantic-conventions'; | ||
import { SemanticResourceAttributes } from '@opentelemetry/semantic-conventions'; | ||
import { Resource } from '../../../'; | ||
@@ -67,0 +67,0 @@ /** |
@@ -16,3 +16,3 @@ /* | ||
*/ | ||
import { ResourceAttributes as SemanticResourceAttributes } from '@opentelemetry/semantic-conventions'; | ||
import { SemanticResourceAttributes } from '@opentelemetry/semantic-conventions'; | ||
import { SDK_INFO } from '@opentelemetry/core'; | ||
@@ -19,0 +19,0 @@ import { defaultServiceName } from './platform'; |
@@ -64,3 +64,3 @@ "use strict"; | ||
if (serviceName) { | ||
attributes[semantic_conventions_1.ResourceAttributes.SERVICE_NAME] = serviceName; | ||
attributes[semantic_conventions_1.SemanticResourceAttributes.SERVICE_NAME] = serviceName; | ||
} | ||
@@ -67,0 +67,0 @@ return new __1.Resource(attributes); |
@@ -29,6 +29,6 @@ "use strict"; | ||
const processResource = { | ||
[semantic_conventions_1.ResourceAttributes.PROCESS_PID]: process.pid, | ||
[semantic_conventions_1.ResourceAttributes.PROCESS_EXECUTABLE_NAME]: process.title || '', | ||
[semantic_conventions_1.ResourceAttributes.PROCESS_COMMAND]: process.argv[1] || '', | ||
[semantic_conventions_1.ResourceAttributes.PROCESS_COMMAND_LINE]: process.argv.join(' ') || '', | ||
[semantic_conventions_1.SemanticResourceAttributes.PROCESS_PID]: process.pid, | ||
[semantic_conventions_1.SemanticResourceAttributes.PROCESS_EXECUTABLE_NAME]: process.title || '', | ||
[semantic_conventions_1.SemanticResourceAttributes.PROCESS_COMMAND]: process.argv[1] || '', | ||
[semantic_conventions_1.SemanticResourceAttributes.PROCESS_COMMAND_LINE]: process.argv.join(' ') || '', | ||
}; | ||
@@ -45,8 +45,8 @@ return this._getResourceAttributes(processResource, config); | ||
_getResourceAttributes(processResource, _config) { | ||
if (processResource[semantic_conventions_1.ResourceAttributes.PROCESS_EXECUTABLE_NAME] === | ||
if (processResource[semantic_conventions_1.SemanticResourceAttributes.PROCESS_EXECUTABLE_NAME] === | ||
'' || | ||
processResource[semantic_conventions_1.ResourceAttributes.PROCESS_EXECUTABLE_PATH] === | ||
processResource[semantic_conventions_1.SemanticResourceAttributes.PROCESS_EXECUTABLE_PATH] === | ||
'' || | ||
processResource[semantic_conventions_1.ResourceAttributes.PROCESS_COMMAND] === '' || | ||
processResource[semantic_conventions_1.ResourceAttributes.PROCESS_COMMAND_LINE] === '') { | ||
processResource[semantic_conventions_1.SemanticResourceAttributes.PROCESS_COMMAND] === '' || | ||
processResource[semantic_conventions_1.SemanticResourceAttributes.PROCESS_COMMAND_LINE] === '') { | ||
api_1.diag.debug('ProcessDetector failed: Unable to find required process resources. '); | ||
@@ -53,0 +53,0 @@ return __1.Resource.empty(); |
@@ -47,6 +47,6 @@ "use strict"; | ||
return new Resource({ | ||
[semantic_conventions_1.ResourceAttributes.SERVICE_NAME]: platform_1.defaultServiceName(), | ||
[semantic_conventions_1.ResourceAttributes.TELEMETRY_SDK_LANGUAGE]: core_1.SDK_INFO[semantic_conventions_1.ResourceAttributes.TELEMETRY_SDK_LANGUAGE], | ||
[semantic_conventions_1.ResourceAttributes.TELEMETRY_SDK_NAME]: core_1.SDK_INFO[semantic_conventions_1.ResourceAttributes.TELEMETRY_SDK_NAME], | ||
[semantic_conventions_1.ResourceAttributes.TELEMETRY_SDK_VERSION]: core_1.SDK_INFO[semantic_conventions_1.ResourceAttributes.TELEMETRY_SDK_VERSION], | ||
[semantic_conventions_1.SemanticResourceAttributes.SERVICE_NAME]: platform_1.defaultServiceName(), | ||
[semantic_conventions_1.SemanticResourceAttributes.TELEMETRY_SDK_LANGUAGE]: core_1.SDK_INFO[semantic_conventions_1.SemanticResourceAttributes.TELEMETRY_SDK_LANGUAGE], | ||
[semantic_conventions_1.SemanticResourceAttributes.TELEMETRY_SDK_NAME]: core_1.SDK_INFO[semantic_conventions_1.SemanticResourceAttributes.TELEMETRY_SDK_NAME], | ||
[semantic_conventions_1.SemanticResourceAttributes.TELEMETRY_SDK_VERSION]: core_1.SDK_INFO[semantic_conventions_1.SemanticResourceAttributes.TELEMETRY_SDK_VERSION], | ||
}); | ||
@@ -53,0 +53,0 @@ } |
{ | ||
"name": "@opentelemetry/resources", | ||
"version": "0.23.1-alpha.23+884d20ab", | ||
"version": "0.23.1-alpha.24+3bc34528", | ||
"description": "OpenTelemetry SDK resources", | ||
@@ -68,6 +68,6 @@ "main": "build/src/index.js", | ||
"dependencies": { | ||
"@opentelemetry/core": "^0.23.1-alpha.23+884d20ab", | ||
"@opentelemetry/semantic-conventions": "^0.23.1-alpha.23+884d20ab" | ||
"@opentelemetry/core": "^0.23.1-alpha.24+3bc34528", | ||
"@opentelemetry/semantic-conventions": "^0.23.1-alpha.24+3bc34528" | ||
}, | ||
"gitHead": "884d20ab417bf0283ec84a72b9a0fae8ebcb82a1" | ||
"gitHead": "3bc3452814e30274d7eea1f3c9da968b88b1a197" | ||
} |
@@ -21,7 +21,7 @@ # OpenTelemetry Resources Util | ||
```typescript | ||
import { ResourceAttributes } from '@opentelemetry/semantic-conventions'; | ||
import { SemanticResourceAttributes } from '@opentelemetry/semantic-conventions'; | ||
import { Resource } from '@opentelemetry/resources'; | ||
const resource = new Resource({ | ||
[ResourceAttributes.SERVICE_NAME]: 'api-service', | ||
[SemanticResourceAttributes.SERVICE_NAME]: 'api-service', | ||
}); | ||
@@ -28,0 +28,0 @@ |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
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
106409