File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
plugins/node/opentelemetry-instrumentation-aws-lambda Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -45,8 +45,8 @@ import {
4545 AWSXRayPropagator ,
4646} from '@opentelemetry/propagator-aws-xray' ;
4747import {
48+ ATTR_URL_FULL ,
4849 SEMATTRS_FAAS_EXECUTION ,
49- SEMATTRS_HTTP_URL ,
5050 SEMRESATTRS_CLOUD_ACCOUNT_ID ,
5151 SEMRESATTRS_FAAS_ID ,
5252} from '@opentelemetry/semantic-conventions' ;
@@ -436,7 +436,7 @@ export class AwsLambdaInstrumentation extends InstrumentationBase<AwsLambdaInstr
436436 const answer : Attributes = { } ;
437437 const fullUrl = this . _extractFullUrl ( event ) ;
438438 if ( fullUrl ) {
439- answer [ SEMATTRS_HTTP_URL ] = fullUrl ;
439+ answer [ ATTR_URL_FULL ] = fullUrl ;
440440 }
441441 return answer ;
442442 }
Original file line number Diff line number Diff line change @@ -34,10 +34,10 @@ import { NodeTracerProvider } from '@opentelemetry/sdk-trace-node';
3434import { Context } from 'aws-lambda' ;
3535import * as assert from 'assert' ;
3636import {
37+ ATTR_URL_FULL ,
3738 SEMATTRS_EXCEPTION_MESSAGE ,
3839 SEMATTRS_FAAS_COLDSTART ,
3940 SEMATTRS_FAAS_EXECUTION ,
40- SEMATTRS_HTTP_URL ,
4141 SEMRESATTRS_FAAS_NAME ,
4242} from '@opentelemetry/semantic-conventions' ;
4343import {
@@ -1098,7 +1098,7 @@ describe('lambda handler', () => {
10981098 await lambdaRequire ( 'lambda-test/sync' ) . handler ( event , ctx , ( ) => { } ) ;
10991099 const [ span ] = memoryExporter . getFinishedSpans ( ) ;
11001100 assert . strictEqual (
1101- span . attributes [ SEMATTRS_HTTP_URL ] ,
1101+ span . attributes [ ATTR_URL_FULL ] ,
11021102 'http://www.example.com/lambda/test/path?key=value'
11031103 ) ;
11041104 console . log ( span ) ;
You can’t perform that action at this time.
0 commit comments