适用于OpenTelemetry的阿里云ons http api仪器
项目描述
此库提供阿里云Ons mq_http_sdk 的自动和手动仪器化
还支持使用opentelemetry-instrumentation包进行自动仪器化。
安装
pip install opentelemetry-instrumentation-aliyun-ons-http
使用
from opentelemetry.instrumentation.aliyun_ons_http import AliyunOnsHttpInstrumentor
AliyunOnsHttpInstrumentor.instrument()
注意
消费者是批量处理的,因此无法自动将跟踪信息添加到每条消息中。
在处理消息时,请手动调用它。
from opentelemetry.instrumentation.aliyun_ons_http import process_record
...
messages = consumer.consume_message():
for message in messages:
with process_record(message):
# do your business
参考文献
项目详情
关闭
哈希值 for opentelemetry_instrumentation_aliyun_ons_http-0.47b1.tar.gz
算法 | 哈希摘要 | |
---|---|---|
SHA256 | 2f954b5aec3dcb170474f2172e27c0e65e669650235951b5b6e91a7b4f37bf5d |
|
MD5 | d13025d53200aa7dba1b2ba65241ce28 |
|
BLAKE2b-256 | 0a9c403b5264b06e7d9b02db95eb9d54bdd99a403abcf086db95e07103949640 |
关闭
哈希值 for opentelemetry_instrumentation_aliyun_ons_http-0.47b1-py3-none-any.whl
算法 | 哈希摘要 | |
---|---|---|
SHA256 | 02f913a6b8a86251f3ff5e8df6c3d8035462e1cc4fcd997e194be9318eca4ef7 |
|
MD5 | a8a661462f0cbccfc5e86e08a35a9aef |
|
BLAKE2b-256 | ccbbf9871820e8cebb5cf63132ffdb6ead449e0dfdddd04bc536fa4147d5785c |