You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@apisix.apache.org by GitBox <gi...@apache.org> on 2020/09/03 01:47:52 UTC
[GitHub] [apisix] gy09535 opened a new issue #2151: feature: best practice for jaeger
gy09535 opened a new issue #2151:
URL: https://github.com/apache/apisix/issues/2151
### Issue description
Apisix also has trace report for zipkin and skywalking, but can not has report for jaeger。
I can use zipkin plugin report span for jaeger ,but it is not the best practice. I think we should report span to jaeger agent ,which use thrift as protocol,acording to the architecture of jaeger https://www.jaegertracing.io/docs/1.19/architecture.
### Environment
* apisix version (cmd: `apisix version`):
* OS:
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] gy09535 commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
gy09535 commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-698753324
I think we can use thrift to report zipkin v2 span to jaeger
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] moonming commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
moonming commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-695766574
Thank you for your feedback, yes, it is really not suitable for apisix to
use the c module
Changwei Hu <no...@github.com>于2020年9月20日 周日下午4:30写道:
>
>
> Today I tried nginx-opentracing which build in openresy, really
> complicated. Indeed, not suitable for integration into apisix.
>
>
> *Depend lib:*
>
>
> https://github.com/opentracing/opentracing-cpp
>
>
> https://github.com/jaegertracing/jaeger-client-cpp
>
>
> detail in: CMakeLists.txt
> <https://github.com/jaegertracing/jaeger-client-cpp/blob/master/CMakeLists.txt>
>
>
> *build option:*
>
>
> ./configure \
>
> --with-http_stub_status_module \
>
> --with-ipv6 \
>
> --with-http_v2_module \
>
> --with-http_realip_module \
>
> --without-luajit-gc64 \
>
> --with-compat \
>
> --add-dynamic-module=/path/nginx-opentracing/opentracing
>
>
>
> *Example:*
>
>
> load_module /usr/local/openresty/nginx/modules/ngx_http_opentracing_module.so;
>
>
>
> events {}
>
>
>
> http {
>
> opentracing on;
>
>
>
> opentracing_load_tracer /usr/local/lib/libjaegertracing.so ./jaeger-config.json;
>
> upstream backend {
>
> server 127.0.0.1:8090;
>
> }
>
>
>
> server {
>
> error_log ./logs/debug.log debug;
>
> listen 8080;
>
> server_name localhost;
>
>
>
> location = / {
>
> opentracing_trace_locations off;
>
> proxy_pass http://backend;
>
> opentracing_propagate_context;
>
> }
>
> }
>
> }
>
>
>
> jaeger-config.json:
>
>
> {
>
> "service_name": "openresty",
>
> "diabled": false,
>
> "reporter": {
>
> "logSpans": true,
>
> "endpoint":"http://192.168.0.14:14268/api/traces"
>
> },
>
> "sampler": {
>
> "type": "const",
>
> "param": "1"
>
> }
>
> }
>
>
>
> *Test:*
>
>
> curl -iv http://127.0.0.1:8080
>
>
> *UI:*
>
>
> [image: image]
> <https://user-images.githubusercontent.com/14133490/93707017-0b1a6c00-fb5e-11ea-8a84-57cb427630b9.png>
>
>
>
>
> —
> You are receiving this because you commented.
> Reply to this email directly, view it on GitHub
> <https://github.com/apache/apisix/issues/2151#issuecomment-695760402>, or
> unsubscribe
> <https://github.com/notifications/unsubscribe-auth/AGJZBK3EHSXQIMIE4HMVXU3SGW4QRANCNFSM4QUDIIKQ>
> .
>
>
> --
Thanks,
Ming Wen
Twitter: _WenMing
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] moonming commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
moonming commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-688872687
I think you can add a plugin for jaeger, and welcome PR for this
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] codjust commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
codjust commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-706106226
> After retry I think use zipkin plugin to send v2 span can work, ref: https://www.jaegertracing.io/docs/1.19/getting-started/
good! it can work with jaeger tracing?
eg: client -> apisix(zipkin plugin) -> go-process(jaeger-client)
then go-process can extract tracing id from apisix http request?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] codjust commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
codjust commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-693349312
May be we can use [nginx-opentracing](https://github.com/opentracing-contrib/nginx-opentracing/blob/master/example/lua/jaeger/nginx.conf) ? a nginx dynamic-module, What do you think?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] codjust commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
codjust commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-706106226
> After retry I think use zipkin plugin to send v2 span can work, ref: https://www.jaegertracing.io/docs/1.19/getting-started/
good! it can work with jaeger tracing?
eg: client -> apisix(zipkin plugin) -> go-process(jaeger-client)
then go-process can extract tracing id from apisix http request?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] gy09535 commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
gy09535 commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-694702383
> May be we can use [nginx-opentracing](https://github.com/opentracing-contrib/nginx-opentracing/blob/master/example/lua/jaeger/nginx.conf) ? a nginx dynamic-module, What do you think?
I think use opentracing lua lib is better https://github.com/iresty/opentracing-openresty ?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] gy09535 commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
gy09535 commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-706060672
After retry I think use zipkin plugin to send v2 span can work, ref: https://www.jaegertracing.io/docs/1.19/getting-started/
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] gy09535 commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
gy09535 commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-692414315
> I think you can add a plugin for jaeger, and welcome PR for this
got it
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] gy09535 closed issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
gy09535 closed issue #2151:
URL: https://github.com/apache/apisix/issues/2151
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] gy09535 commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
gy09535 commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-698753324
I think we can use thrift to report zipkin v2 span to jaeger
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] codjust commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
codjust commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-695760402
Today I tried nginx-opentracing which build in openresy, really complicated. Indeed, not suitable for integration into apisix.
**Depend lib:**
https://github.com/opentracing/opentracing-cpp
https://github.com/jaegertracing/jaeger-client-cpp
detail in: [CMakeLists.txt]( https://github.com/jaegertracing/jaeger-client-cpp/blob/master/CMakeLists.txt)
**build option:**
```shell
./configure \
--with-http_stub_status_module \
--with-ipv6 \
--with-http_v2_module \
--with-http_realip_module \
--without-luajit-gc64 \
--with-compat \
--add-dynamic-module=/path/nginx-opentracing/opentracing
```
**Example:**
```
load_module /usr/local/openresty/nginx/modules/ngx_http_opentracing_module.so;
events {}
http {
opentracing on;
opentracing_load_tracer /usr/local/lib/libjaegertracing.so ./jaeger-config.json;
upstream backend {
server 127.0.0.1:8090;
}
server {
error_log ./logs/debug.log debug;
listen 8080;
server_name localhost;
location = / {
opentracing_trace_locations off;
proxy_pass http://backend;
opentracing_propagate_context;
}
}
}
```
jaeger-config.json:
```json
{
"service_name": "openresty",
"diabled": false,
"reporter": {
"logSpans": true,
"endpoint":"http://192.168.0.14:14268/api/traces"
},
"sampler": {
"type": "const",
"param": "1"
}
}
```
**Test:**
`curl -iv http://127.0.0.1:8080`
**UI:**
![image](https://user-images.githubusercontent.com/14133490/93707017-0b1a6c00-fb5e-11ea-8a84-57cb427630b9.png)
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] codjust commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
codjust commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-695150951
> > May be we can use [nginx-opentracing](https://github.com/opentracing-contrib/nginx-opentracing/blob/master/example/lua/jaeger/nginx.conf) ? a nginx dynamic-module, What do you think?
>
> I think use opentracing lua lib is better https://github.com/iresty/opentracing-openresty ?
yeah, but you need to implement the Jaeger API start over, which is more complicated. see: [jaeger-client-cpp](https://github.com/jaegertracing/jaeger-client-cpp).
Have you started this work? Maybe we can take a look together
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] gy09535 commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
gy09535 commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-706468244
> > After retry I think use zipkin plugin to send v2 span can work, ref: https://www.jaegertracing.io/docs/1.19/getting-started/
>
> good! it can work with jaeger tracing?
> eg: client -> apisix(zipkin plugin) -> go-process(jaeger-client)
> then go-process can extract tracing id from apisix http request?
yeah, jaeger support b3-propagation. ref: https://github.com/openzipkin/b3-propagation
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] gy09535 commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
gy09535 commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-703063548
> > I retry use this lua bridge to send data https://github.com/opentracing/lua-bridge-tracer/tree/master/src
>
> please confirm it can work with `cosocket`, for the C library, it can not call any socket if we use it in nginx Lua land.
It is a problem
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] codjust commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
codjust commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-706474223
> > > After retry I think use zipkin plugin to send v2 span can work, ref: https://www.jaegertracing.io/docs/1.19/getting-started/
> >
> >
> > good! it can work with jaeger tracing?
> > eg: client -> apisix(zipkin plugin) -> go-process(jaeger-client)
> > then go-process can extract tracing id from apisix http request?
>
> yeah, jaeger support b3-propagation. ref: https://github.com/openzipkin/b3-propagation
got it!
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] gy09535 commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
gy09535 commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-701219754
> Today I tried nginx-opentracing which build in openresy, really complicated. Indeed, not suitable for integration into apisix.
>
> **Depend lib:**
> https://github.com/opentracing/opentracing-cpp
> https://github.com/jaegertracing/jaeger-client-cpp
> detail in: [CMakeLists.txt](https://github.com/jaegertracing/jaeger-client-cpp/blob/master/CMakeLists.txt)
>
> **build option:**
>
> ```shell
> ./configure \
> --with-http_stub_status_module \
> --with-ipv6 \
> --with-http_v2_module \
> --with-http_realip_module \
> --without-luajit-gc64 \
> --with-compat \
> --add-dynamic-module=/path/nginx-opentracing/opentracing
> ```
>
> **Example:**
>
> ```
> load_module /usr/local/openresty/nginx/modules/ngx_http_opentracing_module.so;
>
> events {}
>
> http {
> opentracing on;
>
> opentracing_load_tracer /usr/local/lib/libjaegertracing.so ./jaeger-config.json;
> upstream backend {
> server 127.0.0.1:8090;
> }
>
> server {
> error_log ./logs/debug.log debug;
> listen 8080;
> server_name localhost;
>
> location = / {
> opentracing_trace_locations off;
> proxy_pass http://backend;
> opentracing_propagate_context;
> }
> }
> }
> ```
>
> jaeger-config.json:
>
> ```json
> {
> "service_name": "openresty",
> "diabled": false,
> "reporter": {
> "logSpans": true,
> "endpoint":"http://192.168.0.14:14268/api/traces"
> },
> "sampler": {
> "type": "const",
> "param": "1"
> }
> }
> ```
>
> **Test:**
> `curl -iv http://127.0.0.1:8080`
>
> **UI:**
> ![image](https://user-images.githubusercontent.com/14133490/93707017-0b1a6c00-fb5e-11ea-8a84-57cb427630b9.png)
I retry use this lua bridge to send data https://github.com/opentracing/lua-bridge-tracer/tree/master/src
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] gy09535 commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
gy09535 commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-706060672
After retry I think use zipkin plugin to send v2 span can work, ref: https://www.jaegertracing.io/docs/1.19/getting-started/
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [apisix] membphis commented on issue #2151: feature: Best practice for jaeger
Posted by GitBox <gi...@apache.org>.
membphis commented on issue #2151:
URL: https://github.com/apache/apisix/issues/2151#issuecomment-701254391
> I retry use this lua bridge to send data https://github.com/opentracing/lua-bridge-tracer/tree/master/src
please confirm it can work with `cosocket`, for the C library, it can not call any socket if we use it in nginx Lua land.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org