You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: dev-packages/node-integration-tests/suites/tracing/postgresjs/test.ts
+42-42Lines changed: 42 additions & 42 deletions
Original file line number
Diff line number
Diff line change
@@ -12,13 +12,13 @@ function createDbSpanMatcher(operationName: string, descriptionMatcher: unknown
12
12
'db.system.name': 'postgres',
13
13
'db.operation.name': operationName,
14
14
'sentry.op': 'db',
15
-
'sentry.origin': 'auto.db.otel.postgres',
15
+
'sentry.origin': 'auto.db.postgresjs',
16
16
'server.address': 'localhost',
17
17
'server.port': 5444,
18
18
}),
19
19
description: descriptionMatcher,
20
20
op: 'db',
21
-
origin: 'auto.db.otel.postgres',
21
+
origin: 'auto.db.postgresjs',
22
22
});
23
23
}
24
24
@@ -39,15 +39,15 @@ describe('postgresjs auto instrumentation', () => {
39
39
'db.query.text':
40
40
'CREATE TABLE "User" ("id" SERIAL NOT NULL,"createdAt" TIMESTAMP(?) NOT NULL DEFAULT CURRENT_TIMESTAMP,"email" TEXT NOT NULL,"name" TEXT,CONSTRAINT "User_pkey" PRIMARY KEY ("id"))',
41
41
'sentry.op': 'db',
42
-
'sentry.origin': 'auto.db.otel.postgres',
42
+
'sentry.origin': 'auto.db.postgresjs',
43
43
'server.address': 'localhost',
44
44
'server.port': 5444,
45
45
}),
46
46
description:
47
47
'CREATE TABLE "User" ("id" SERIAL NOT NULL,"createdAt" TIMESTAMP(?) NOT NULL DEFAULT CURRENT_TIMESTAMP,"email" TEXT NOT NULL,"name" TEXT,CONSTRAINT "User_pkey" PRIMARY KEY ("id"))',
48
48
op: 'db',
49
49
status: 'ok',
50
-
origin: 'auto.db.otel.postgres',
50
+
origin: 'auto.db.postgresjs',
51
51
parent_span_id: expect.any(String),
52
52
span_id: expect.any(String),
53
53
start_timestamp: expect.any(Number),
@@ -60,15 +60,15 @@ describe('postgresjs auto instrumentation', () => {
60
60
'db.system.name': 'postgres',
61
61
'db.operation.name': 'INSERT',
62
62
'db.query.text': `INSERT INTO "User" ("email", "name") VALUES ('Foo', '${EXISTING_TEST_EMAIL}')`,
63
-
'sentry.origin': 'auto.db.otel.postgres',
63
+
'sentry.origin': 'auto.db.postgresjs',
64
64
'sentry.op': 'db',
65
65
'server.address': 'localhost',
66
66
'server.port': 5444,
67
67
}),
68
68
description: `INSERT INTO "User" ("email", "name") VALUES ('Foo', '${EXISTING_TEST_EMAIL}')`,
69
69
op: 'db',
70
70
status: 'ok',
71
-
origin: 'auto.db.otel.postgres',
71
+
origin: 'auto.db.postgresjs',
72
72
parent_span_id: expect.any(String),
73
73
span_id: expect.any(String),
74
74
start_timestamp: expect.any(Number),
@@ -82,14 +82,14 @@ describe('postgresjs auto instrumentation', () => {
82
82
'db.operation.name': 'UPDATE',
83
83
'db.query.text': `UPDATE "User" SET "name" = 'Foo' WHERE "email" = '${EXISTING_TEST_EMAIL}'`,
84
84
'sentry.op': 'db',
85
-
'sentry.origin': 'auto.db.otel.postgres',
85
+
'sentry.origin': 'auto.db.postgresjs',
86
86
'server.address': 'localhost',
87
87
'server.port': 5444,
88
88
}),
89
89
description: `UPDATE "User" SET "name" = 'Foo' WHERE "email" = '${EXISTING_TEST_EMAIL}'`,
90
90
op: 'db',
91
91
status: 'ok',
92
-
origin: 'auto.db.otel.postgres',
92
+
origin: 'auto.db.postgresjs',
93
93
parent_span_id: expect.any(String),
94
94
span_id: expect.any(String),
95
95
start_timestamp: expect.any(Number),
@@ -103,14 +103,14 @@ describe('postgresjs auto instrumentation', () => {
103
103
'db.operation.name': 'SELECT',
104
104
'db.query.text': `SELECT * FROM "User" WHERE "email" = '${EXISTING_TEST_EMAIL}'`,
105
105
'sentry.op': 'db',
106
-
'sentry.origin': 'auto.db.otel.postgres',
106
+
'sentry.origin': 'auto.db.postgresjs',
107
107
'server.address': 'localhost',
108
108
'server.port': 5444,
109
109
}),
110
110
description: `SELECT * FROM "User" WHERE "email" = '${EXISTING_TEST_EMAIL}'`,
111
111
op: 'db',
112
112
status: 'ok',
113
-
origin: 'auto.db.otel.postgres',
113
+
origin: 'auto.db.postgresjs',
114
114
parent_span_id: expect.any(String),
115
115
span_id: expect.any(String),
116
116
start_timestamp: expect.any(Number),
@@ -124,14 +124,14 @@ describe('postgresjs auto instrumentation', () => {
124
124
'db.operation.name': 'SELECT',
125
125
'db.query.text': 'SELECT * from generate_series(?,?) as x',
126
126
'sentry.op': 'db',
127
-
'sentry.origin': 'auto.db.otel.postgres',
127
+
'sentry.origin': 'auto.db.postgresjs',
128
128
'server.address': 'localhost',
129
129
'server.port': 5444,
130
130
}),
131
131
description: 'SELECT * from generate_series(?,?) as x',
132
132
op: 'db',
133
133
status: 'ok',
134
-
origin: 'auto.db.otel.postgres',
134
+
origin: 'auto.db.postgresjs',
135
135
parent_span_id: expect.any(String),
136
136
span_id: expect.any(String),
137
137
start_timestamp: expect.any(Number),
@@ -145,14 +145,14 @@ describe('postgresjs auto instrumentation', () => {
145
145
'db.operation.name': 'DROP TABLE',
146
146
'db.query.text': 'DROP TABLE "User"',
147
147
'sentry.op': 'db',
148
-
'sentry.origin': 'auto.db.otel.postgres',
148
+
'sentry.origin': 'auto.db.postgresjs',
149
149
'server.address': 'localhost',
150
150
'server.port': 5444,
151
151
}),
152
152
description: 'DROP TABLE "User"',
153
153
op: 'db',
154
154
status: 'ok',
155
-
origin: 'auto.db.otel.postgres',
155
+
origin: 'auto.db.postgresjs',
156
156
parent_span_id: expect.any(String),
157
157
span_id: expect.any(String),
158
158
start_timestamp: expect.any(Number),
@@ -168,14 +168,14 @@ describe('postgresjs auto instrumentation', () => {
168
168
'error.type': 'PostgresError',
169
169
'db.query.text': `SELECT * FROM "User" WHERE "email" = '${NON_EXISTING_TEST_EMAIL}'`,
170
170
'sentry.op': 'db',
171
-
'sentry.origin': 'auto.db.otel.postgres',
171
+
'sentry.origin': 'auto.db.postgresjs',
172
172
'server.address': 'localhost',
173
173
'server.port': 5444,
174
174
}),
175
175
description: `SELECT * FROM "User" WHERE "email" = '${NON_EXISTING_TEST_EMAIL}'`,
176
176
op: 'db',
177
177
status: 'internal_error',
178
-
origin: 'auto.db.otel.postgres',
178
+
origin: 'auto.db.postgresjs',
179
179
parent_span_id: expect.any(String),
180
180
span_id: expect.any(String),
181
181
start_timestamp: expect.any(Number),
@@ -234,15 +234,15 @@ describe('postgresjs auto instrumentation', () => {
234
234
'db.query.text':
235
235
'CREATE TABLE "User" ("id" SERIAL NOT NULL,"createdAt" TIMESTAMP(?) NOT NULL DEFAULT CURRENT_TIMESTAMP,"email" TEXT NOT NULL,"name" TEXT,CONSTRAINT "User_pkey" PRIMARY KEY ("id"))',
236
236
'sentry.op': 'db',
237
-
'sentry.origin': 'auto.db.otel.postgres',
237
+
'sentry.origin': 'auto.db.postgresjs',
238
238
'server.address': 'localhost',
239
239
'server.port': 5444,
240
240
}),
241
241
description:
242
242
'CREATE TABLE "User" ("id" SERIAL NOT NULL,"createdAt" TIMESTAMP(?) NOT NULL DEFAULT CURRENT_TIMESTAMP,"email" TEXT NOT NULL,"name" TEXT,CONSTRAINT "User_pkey" PRIMARY KEY ("id"))',
243
243
op: 'db',
244
244
status: 'ok',
245
-
origin: 'auto.db.otel.postgres',
245
+
origin: 'auto.db.postgresjs',
246
246
parent_span_id: expect.any(String),
247
247
span_id: expect.any(String),
248
248
start_timestamp: expect.any(Number),
@@ -255,15 +255,15 @@ describe('postgresjs auto instrumentation', () => {
255
255
'db.system.name': 'postgres',
256
256
'db.operation.name': 'INSERT',
257
257
'db.query.text': `INSERT INTO "User" ("email", "name") VALUES ('Foo', '${EXISTING_TEST_EMAIL}')`,
258
-
'sentry.origin': 'auto.db.otel.postgres',
258
+
'sentry.origin': 'auto.db.postgresjs',
259
259
'sentry.op': 'db',
260
260
'server.address': 'localhost',
261
261
'server.port': 5444,
262
262
}),
263
263
description: `INSERT INTO "User" ("email", "name") VALUES ('Foo', '${EXISTING_TEST_EMAIL}')`,
264
264
op: 'db',
265
265
status: 'ok',
266
-
origin: 'auto.db.otel.postgres',
266
+
origin: 'auto.db.postgresjs',
267
267
parent_span_id: expect.any(String),
268
268
span_id: expect.any(String),
269
269
start_timestamp: expect.any(Number),
@@ -277,14 +277,14 @@ describe('postgresjs auto instrumentation', () => {
277
277
'db.operation.name': 'UPDATE',
278
278
'db.query.text': `UPDATE "User" SET "name" = 'Foo' WHERE "email" = '${EXISTING_TEST_EMAIL}'`,
279
279
'sentry.op': 'db',
280
-
'sentry.origin': 'auto.db.otel.postgres',
280
+
'sentry.origin': 'auto.db.postgresjs',
281
281
'server.address': 'localhost',
282
282
'server.port': 5444,
283
283
}),
284
284
description: `UPDATE "User" SET "name" = 'Foo' WHERE "email" = '${EXISTING_TEST_EMAIL}'`,
285
285
op: 'db',
286
286
status: 'ok',
287
-
origin: 'auto.db.otel.postgres',
287
+
origin: 'auto.db.postgresjs',
288
288
parent_span_id: expect.any(String),
289
289
span_id: expect.any(String),
290
290
start_timestamp: expect.any(Number),
@@ -298,14 +298,14 @@ describe('postgresjs auto instrumentation', () => {
298
298
'db.operation.name': 'SELECT',
299
299
'db.query.text': `SELECT * FROM "User" WHERE "email" = '${EXISTING_TEST_EMAIL}'`,
300
300
'sentry.op': 'db',
301
-
'sentry.origin': 'auto.db.otel.postgres',
301
+
'sentry.origin': 'auto.db.postgresjs',
302
302
'server.address': 'localhost',
303
303
'server.port': 5444,
304
304
}),
305
305
description: `SELECT * FROM "User" WHERE "email" = '${EXISTING_TEST_EMAIL}'`,
306
306
op: 'db',
307
307
status: 'ok',
308
-
origin: 'auto.db.otel.postgres',
308
+
origin: 'auto.db.postgresjs',
309
309
parent_span_id: expect.any(String),
310
310
span_id: expect.any(String),
311
311
start_timestamp: expect.any(Number),
@@ -319,14 +319,14 @@ describe('postgresjs auto instrumentation', () => {
319
319
'db.operation.name': 'SELECT',
320
320
'db.query.text': 'SELECT * from generate_series(?,?) as x',
321
321
'sentry.op': 'db',
322
-
'sentry.origin': 'auto.db.otel.postgres',
322
+
'sentry.origin': 'auto.db.postgresjs',
323
323
'server.address': 'localhost',
324
324
'server.port': 5444,
325
325
}),
326
326
description: 'SELECT * from generate_series(?,?) as x',
327
327
op: 'db',
328
328
status: 'ok',
329
-
origin: 'auto.db.otel.postgres',
329
+
origin: 'auto.db.postgresjs',
330
330
parent_span_id: expect.any(String),
331
331
span_id: expect.any(String),
332
332
start_timestamp: expect.any(Number),
@@ -340,14 +340,14 @@ describe('postgresjs auto instrumentation', () => {
340
340
'db.operation.name': 'DROP TABLE',
341
341
'db.query.text': 'DROP TABLE "User"',
342
342
'sentry.op': 'db',
343
-
'sentry.origin': 'auto.db.otel.postgres',
343
+
'sentry.origin': 'auto.db.postgresjs',
344
344
'server.address': 'localhost',
345
345
'server.port': 5444,
346
346
}),
347
347
description: 'DROP TABLE "User"',
348
348
op: 'db',
349
349
status: 'ok',
350
-
origin: 'auto.db.otel.postgres',
350
+
origin: 'auto.db.postgresjs',
351
351
parent_span_id: expect.any(String),
352
352
span_id: expect.any(String),
353
353
start_timestamp: expect.any(Number),
@@ -363,14 +363,14 @@ describe('postgresjs auto instrumentation', () => {
363
363
'error.type': 'PostgresError',
364
364
'db.query.text': `SELECT * FROM "User" WHERE "email" = '${NON_EXISTING_TEST_EMAIL}'`,
365
365
'sentry.op': 'db',
366
-
'sentry.origin': 'auto.db.otel.postgres',
366
+
'sentry.origin': 'auto.db.postgresjs',
367
367
'server.address': 'localhost',
368
368
'server.port': 5444,
369
369
}),
370
370
description: `SELECT * FROM "User" WHERE "email" = '${NON_EXISTING_TEST_EMAIL}'`,
371
371
op: 'db',
372
372
status: 'internal_error',
373
-
origin: 'auto.db.otel.postgres',
373
+
origin: 'auto.db.postgresjs',
374
374
parent_span_id: expect.any(String),
375
375
span_id: expect.any(String),
376
376
start_timestamp: expect.any(Number),
@@ -431,15 +431,15 @@ describe('postgresjs auto instrumentation', () => {
431
431
'CREATE TABLE "User" ("id" SERIAL NOT NULL,"createdAt" TIMESTAMP(?) NOT NULL DEFAULT CURRENT_TIMESTAMP,"email" TEXT NOT NULL,"name" TEXT,CONSTRAINT "User_pkey" PRIMARY KEY ("id"))',
432
432
'custom.requestHook': 'called',
433
433
'sentry.op': 'db',
434
-
'sentry.origin': 'auto.db.otel.postgres',
434
+
'sentry.origin': 'auto.db.postgresjs',
435
435
'server.address': 'localhost',
436
436
'server.port': 5444,
437
437
}),
438
438
description:
439
439
'CREATE TABLE "User" ("id" SERIAL NOT NULL,"createdAt" TIMESTAMP(?) NOT NULL DEFAULT CURRENT_TIMESTAMP,"email" TEXT NOT NULL,"name" TEXT,CONSTRAINT "User_pkey" PRIMARY KEY ("id"))',
440
440
op: 'db',
441
441
status: 'ok',
442
-
origin: 'auto.db.otel.postgres',
442
+
origin: 'auto.db.postgresjs',
443
443
}),
444
444
expect.objectContaining({
445
445
data: expect.objectContaining({
@@ -449,14 +449,14 @@ describe('postgresjs auto instrumentation', () => {
449
449
'db.query.text': `INSERT INTO "User" ("email", "name") VALUES ('Foo', '${EXISTING_TEST_EMAIL}')`,
450
450
'custom.requestHook': 'called',
451
451
'sentry.op': 'db',
452
-
'sentry.origin': 'auto.db.otel.postgres',
452
+
'sentry.origin': 'auto.db.postgresjs',
453
453
'server.address': 'localhost',
454
454
'server.port': 5444,
455
455
}),
456
456
description: `INSERT INTO "User" ("email", "name") VALUES ('Foo', '${EXISTING_TEST_EMAIL}')`,
457
457
op: 'db',
458
458
status: 'ok',
459
-
origin: 'auto.db.otel.postgres',
459
+
origin: 'auto.db.postgresjs',
460
460
}),
461
461
expect.objectContaining({
462
462
data: expect.objectContaining({
@@ -466,14 +466,14 @@ describe('postgresjs auto instrumentation', () => {
466
466
'db.query.text': `SELECT * FROM "User" WHERE "email" = '${EXISTING_TEST_EMAIL}'`,
467
467
'custom.requestHook': 'called',
468
468
'sentry.op': 'db',
469
-
'sentry.origin': 'auto.db.otel.postgres',
469
+
'sentry.origin': 'auto.db.postgresjs',
470
470
'server.address': 'localhost',
471
471
'server.port': 5444,
472
472
}),
473
473
description: `SELECT * FROM "User" WHERE "email" = '${EXISTING_TEST_EMAIL}'`,
474
474
op: 'db',
475
475
status: 'ok',
476
-
origin: 'auto.db.otel.postgres',
476
+
origin: 'auto.db.postgresjs',
477
477
}),
478
478
]),
479
479
extra: expect.objectContaining({
@@ -507,15 +507,15 @@ describe('postgresjs auto instrumentation', () => {
507
507
'CREATE TABLE "User" ("id" SERIAL NOT NULL,"createdAt" TIMESTAMP(?) NOT NULL DEFAULT CURRENT_TIMESTAMP,"email" TEXT NOT NULL,"name" TEXT,CONSTRAINT "User_pkey" PRIMARY KEY ("id"))',
508
508
'custom.requestHook': 'called',
509
509
'sentry.op': 'db',
510
-
'sentry.origin': 'auto.db.otel.postgres',
510
+
'sentry.origin': 'auto.db.postgresjs',
511
511
'server.address': 'localhost',
512
512
'server.port': 5444,
513
513
}),
514
514
description:
515
515
'CREATE TABLE "User" ("id" SERIAL NOT NULL,"createdAt" TIMESTAMP(?) NOT NULL DEFAULT CURRENT_TIMESTAMP,"email" TEXT NOT NULL,"name" TEXT,CONSTRAINT "User_pkey" PRIMARY KEY ("id"))',
516
516
op: 'db',
517
517
status: 'ok',
518
-
origin: 'auto.db.otel.postgres',
518
+
origin: 'auto.db.postgresjs',
519
519
}),
520
520
expect.objectContaining({
521
521
data: expect.objectContaining({
@@ -525,14 +525,14 @@ describe('postgresjs auto instrumentation', () => {
525
525
'db.query.text': `INSERT INTO "User" ("email", "name") VALUES ('Foo', '${EXISTING_TEST_EMAIL}')`,
526
526
'custom.requestHook': 'called',
527
527
'sentry.op': 'db',
528
-
'sentry.origin': 'auto.db.otel.postgres',
528
+
'sentry.origin': 'auto.db.postgresjs',
529
529
'server.address': 'localhost',
530
530
'server.port': 5444,
531
531
}),
532
532
description: `INSERT INTO "User" ("email", "name") VALUES ('Foo', '${EXISTING_TEST_EMAIL}')`,
533
533
op: 'db',
534
534
status: 'ok',
535
-
origin: 'auto.db.otel.postgres',
535
+
origin: 'auto.db.postgresjs',
536
536
}),
537
537
expect.objectContaining({
538
538
data: expect.objectContaining({
@@ -542,14 +542,14 @@ describe('postgresjs auto instrumentation', () => {
542
542
'db.query.text': `SELECT * FROM "User" WHERE "email" = '${EXISTING_TEST_EMAIL}'`,
543
543
'custom.requestHook': 'called',
544
544
'sentry.op': 'db',
545
-
'sentry.origin': 'auto.db.otel.postgres',
545
+
'sentry.origin': 'auto.db.postgresjs',
546
546
'server.address': 'localhost',
547
547
'server.port': 5444,
548
548
}),
549
549
description: `SELECT * FROM "User" WHERE "email" = '${EXISTING_TEST_EMAIL}'`,
0 commit comments