@@ -121,8 +121,8 @@ init_result = oneagent.initialize()
121121print (' OneAgent SDK initialization result' + repr (init_result))
122122if init_result:
123123 print (' SDK should work (but agent might be inactive).' )
124- if not init_result :
125- print (' SDK will definitely not work (i.e. functions will be no-ops). ' )
124+ else :
125+ print (' SDK will definitely not work (i.e. functions will be no-ops): ' , init_result )
126126```
127127
128128See the API documentation for the [ ` initialize ` function] ( https://dynatrace.github.io/OneAgent-SDK-for-Python/docs/sdkref.html#oneagent.initialize )
@@ -453,7 +453,7 @@ to the respective messaging tracer, which is an outgoing message tracer in the e
453453``` python
454454msi_handle = sdk.create_messaging_system_info(
455455 ' myMessagingSystem' , ' requestQueue' , MessagingDestinationType.QUEUE ,
456- ChannelType.TCP_IP , ' 10.11.12.13' )
456+ oneagent.sdk.Channel(oneagent.sdk. ChannelType.TCP_IP , ' 10.11.12.13' ) )
457457
458458with msi_handle:
459459 with sdk.trace_outgoing_message(msi_handle) as tracer:
@@ -481,7 +481,7 @@ the received message. Therefore two different tracers are being used:
481481``` python
482482msi_handle = sdk.create_messaging_system_info(
483483 ' myMessagingSystem' , ' requestQueue' , MessagingDestinationType.QUEUE ,
484- ChannelType.TCP_IP , ' 10.11.12.13' )
484+ oneagent.sdk.Channel(oneagent.sdk. ChannelType.TCP_IP , ' 10.11.12.13' ) )
485485
486486with msi_handle:
487487 # Create the receive tracer for incoming messages.
@@ -508,7 +508,7 @@ IncomingMessageReceiveTracer - just trace processing of the message by using the
508508``` python
509509msi_handle = sdk.create_messaging_system_info(
510510 ' myMessagingSystem' , ' requestQueue' , MessagingDestinationType.QUEUE ,
511- ChannelType.TCP_IP , ' 10.11.12.13' )
511+ oneagent.sdk.Channel(oneagent.sdk. ChannelType.TCP_IP , ' 10.11.12.13' ) )
512512
513513def on_message_received (message ):
514514 # Get the Dynatrace tag from the message.
0 commit comments