@@ -158,10 +158,10 @@ async def test_getone(self) -> None:
158
158
expected_spans = [
159
159
{
160
160
"name" : "topic_1 receive" ,
161
- "kind" : SpanKind .CLIENT ,
161
+ "kind" : SpanKind .CONSUMER ,
162
162
"attributes" : {
163
163
messaging_attributes .MESSAGING_SYSTEM : messaging_attributes .MessagingSystemValues .KAFKA .value ,
164
- server_attributes .SERVER_ADDRESS : "localhost" ,
164
+ server_attributes .SERVER_ADDRESS : ' "localhost"' ,
165
165
messaging_attributes .MESSAGING_CLIENT_ID : client_id ,
166
166
messaging_attributes .MESSAGING_DESTINATION_NAME : "topic_1" ,
167
167
messaging_attributes .MESSAGING_DESTINATION_PARTITION_ID : "1" ,
@@ -175,10 +175,10 @@ async def test_getone(self) -> None:
175
175
},
176
176
{
177
177
"name" : "topic_2 receive" ,
178
- "kind" : SpanKind .CLIENT ,
178
+ "kind" : SpanKind .CONSUMER ,
179
179
"attributes" : {
180
180
messaging_attributes .MESSAGING_SYSTEM : messaging_attributes .MessagingSystemValues .KAFKA .value ,
181
- server_attributes .SERVER_ADDRESS : "localhost" ,
181
+ server_attributes .SERVER_ADDRESS : ' "localhost"' ,
182
182
messaging_attributes .MESSAGING_CLIENT_ID : client_id ,
183
183
messaging_attributes .MESSAGING_DESTINATION_NAME : "topic_2" ,
184
184
messaging_attributes .MESSAGING_DESTINATION_PARTITION_ID : "2" ,
@@ -293,10 +293,10 @@ async def test_getmany(self) -> None:
293
293
expected_spans = [
294
294
{
295
295
"name" : "topic_1 receive" ,
296
- "kind" : SpanKind .CLIENT ,
296
+ "kind" : SpanKind .CONSUMER ,
297
297
"attributes" : {
298
298
messaging_attributes .MESSAGING_SYSTEM : messaging_attributes .MessagingSystemValues .KAFKA .value ,
299
- server_attributes .SERVER_ADDRESS : "localhost" ,
299
+ server_attributes .SERVER_ADDRESS : ' "localhost"' ,
300
300
messaging_attributes .MESSAGING_CLIENT_ID : client_id ,
301
301
messaging_attributes .MESSAGING_DESTINATION_NAME : "topic_1" ,
302
302
messaging_attributes .MESSAGING_DESTINATION_PARTITION_ID : "1" ,
@@ -309,26 +309,26 @@ async def test_getmany(self) -> None:
309
309
},
310
310
},
311
311
{
312
- "name" : "topic_1 poll " ,
313
- "kind" : SpanKind .CLIENT ,
312
+ "name" : "topic_1 receive " ,
313
+ "kind" : SpanKind .CONSUMER ,
314
314
"attributes" : {
315
315
messaging_attributes .MESSAGING_SYSTEM : messaging_attributes .MessagingSystemValues .KAFKA .value ,
316
- server_attributes .SERVER_ADDRESS : "localhost" ,
316
+ server_attributes .SERVER_ADDRESS : ' "localhost"' ,
317
317
messaging_attributes .MESSAGING_CLIENT_ID : client_id ,
318
318
messaging_attributes .MESSAGING_DESTINATION_NAME : "topic_1" ,
319
319
messaging_attributes .MESSAGING_DESTINATION_PARTITION_ID : "1" ,
320
320
messaging_attributes .MESSAGING_CONSUMER_GROUP_NAME : group_id ,
321
- messaging_attributes .MESSAGING_OPERATION_NAME : "poll " ,
321
+ messaging_attributes .MESSAGING_OPERATION_NAME : "receive " ,
322
322
messaging_attributes .MESSAGING_OPERATION_TYPE : messaging_attributes .MessagingOperationTypeValues .RECEIVE .value ,
323
323
messaging_attributes .MESSAGING_BATCH_MESSAGE_COUNT : 1 ,
324
324
},
325
325
},
326
326
{
327
327
"name" : "topic_2 receive" ,
328
- "kind" : SpanKind .CLIENT ,
328
+ "kind" : SpanKind .CONSUMER ,
329
329
"attributes" : {
330
330
messaging_attributes .MESSAGING_SYSTEM : messaging_attributes .MessagingSystemValues .KAFKA .value ,
331
- server_attributes .SERVER_ADDRESS : "localhost" ,
331
+ server_attributes .SERVER_ADDRESS : ' "localhost"' ,
332
332
messaging_attributes .MESSAGING_CLIENT_ID : client_id ,
333
333
messaging_attributes .MESSAGING_DESTINATION_NAME : "topic_2" ,
334
334
messaging_attributes .MESSAGING_DESTINATION_PARTITION_ID : "2" ,
@@ -341,29 +341,29 @@ async def test_getmany(self) -> None:
341
341
},
342
342
},
343
343
{
344
- "name" : "topic_2 poll " ,
345
- "kind" : SpanKind .CLIENT ,
344
+ "name" : "topic_2 receive " ,
345
+ "kind" : SpanKind .CONSUMER ,
346
346
"attributes" : {
347
347
messaging_attributes .MESSAGING_SYSTEM : messaging_attributes .MessagingSystemValues .KAFKA .value ,
348
- server_attributes .SERVER_ADDRESS : "localhost" ,
348
+ server_attributes .SERVER_ADDRESS : ' "localhost"' ,
349
349
messaging_attributes .MESSAGING_CLIENT_ID : client_id ,
350
350
messaging_attributes .MESSAGING_DESTINATION_NAME : "topic_2" ,
351
351
messaging_attributes .MESSAGING_DESTINATION_PARTITION_ID : "2" ,
352
352
messaging_attributes .MESSAGING_CONSUMER_GROUP_NAME : group_id ,
353
- messaging_attributes .MESSAGING_OPERATION_NAME : "poll " ,
353
+ messaging_attributes .MESSAGING_OPERATION_NAME : "receive " ,
354
354
messaging_attributes .MESSAGING_OPERATION_TYPE : messaging_attributes .MessagingOperationTypeValues .RECEIVE .value ,
355
355
messaging_attributes .MESSAGING_BATCH_MESSAGE_COUNT : 1 ,
356
356
},
357
357
},
358
358
{
359
- "name" : "topic_1, topic_2 poll " ,
360
- "kind" : SpanKind .CLIENT ,
359
+ "name" : "topic_1, topic_2 receive " ,
360
+ "kind" : SpanKind .CONSUMER ,
361
361
"attributes" : {
362
362
messaging_attributes .MESSAGING_SYSTEM : messaging_attributes .MessagingSystemValues .KAFKA .value ,
363
- server_attributes .SERVER_ADDRESS : "localhost" ,
363
+ server_attributes .SERVER_ADDRESS : ' "localhost"' ,
364
364
messaging_attributes .MESSAGING_CLIENT_ID : client_id ,
365
365
messaging_attributes .MESSAGING_CONSUMER_GROUP_NAME : group_id ,
366
- messaging_attributes .MESSAGING_OPERATION_NAME : "poll " ,
366
+ messaging_attributes .MESSAGING_OPERATION_NAME : "receive " ,
367
367
messaging_attributes .MESSAGING_OPERATION_TYPE : messaging_attributes .MessagingOperationTypeValues .RECEIVE .value ,
368
368
messaging_attributes .MESSAGING_BATCH_MESSAGE_COUNT : 2 ,
369
369
},
0 commit comments