Comments (9)
@heyanlong 大佬有时间指教下吗?
from skyapm-php-sdk.
通过日志打印发现tars的函数入口函数应该是App\Core\{closure},对应的类应该是App\Core\Tars
但是在php_skywalking.h头文件中,定义的函数是onRequest,定义的类是Tars\core\Server,会导致请求不能开启一个trace。
在修改了php_skywalking.h的函数为App\Core\{closure},类App\Core\Tars后,却发现虽然请求进入了sky_request_init函数,但是数据依然没有上报,manager.cc文件的Manager::consumer消费并没有执行,而且接口无响应(无限等待中)
然后在应用程序日志显示:
[2022-08-22 17:03:24 $32586.0] WARNING swManager_check_exit_status: worker#2[pid=27167] abnormal exit, status=0, signal=11
A bug occurred in Swoole-v4.4.6, please report it.
The Swoole developers probably don't know about it,
and unless you report it, chances are it won't be fixed.
You can read How to report a bug doc before submitting any bug reports:swoole/swoole-src#2000
Please do not send bug reports in the mailing list or personal letters.
The issue page is also suitable to submit feature requests.
from skyapm-php-sdk.
请求的这个worker进程直接退出,信号为11,意思是读取了非法的内存。不知道为啥会这样。
from skyapm-php-sdk.
定位到了SKYWALKING_G(is_swoole) = true;这一行,只要注释掉这一行,就不会报signal=11进程异常退出
from skyapm-php-sdk.
需要看一下tars的入口函数是什么。可以发一个最小代码吗?目前e2e没有包含tars测试。
from skyapm-php-sdk.
需要看一下tars的入口函数是什么。可以发一个最小代码吗?目前e2e没有包含tars测试。
tars的入口应该是没错的,我最开始出现问题的地方应该是我们这边的项目覆盖了onRequest回调,是在App\Core\Tars里。
现在的问题是进程会异常退出,报signal 11,我调试了一下,发现是在PHP里http request对象的指针地址读取错误,我目前发现了两处疑似导致问题的地方:
1 调用SKYWALKING_G(is_swoole) = true;赋值,因此我改用其他全局变量的方式实现这个逻辑,就能够恢复正常。
2 调用sky_find_swoole_fd函数就会出现,此处没有找到好的解法,我尝试注释此行,用常量1返回就可以,这里不知道怎么替换
from skyapm-php-sdk.
重写onRequest没关系,还是会继续处理swoole的onRequest
from skyapm-php-sdk.
重写onRequest没关系,还是会继续处理swoole的onRequest
现在的问题是
1 调用SKYWALKING_G(is_swoole) = true;赋值,因此我改用其他全局变量的方式实现这个逻辑,就能够恢复正常。
2 调用sky_find_swoole_fd函数就会出现,此处没有找到好的解法,我尝试注释此行,用常量1返回就可以
这两处会导致php服务读取http request header时,指针地址错误,这个问题我怎么看源码都看不出问题来,怀疑是swoole的bug。
from skyapm-php-sdk.
发一下你怎么改的,再发一下demo代码,我本地测试一下。
from skyapm-php-sdk.
Related Issues (20)
- centos安装成功之后前端没有数据展示 HOT 10
- hyperf(swoole) 上报数据异常,报FRAME_SIZE_ERROR HOT 4
- 关于skywalking时间的问题 HOT 5
- receive content is empty HOT 5
- sw extension compile failed at the 200th rust pkg. HOT 2
- sky-php-agent不能注册 HOT 1
- skywalking 9.1.0版本前端页面显示数据有延时 HOT 1
- docker部署8.9.1仪表盘显示异常 HOT 1
- 执行 php -v , php -m Segmentation fault (core dumped) HOT 3
- 数据无法上报:sky_core_report_ipc_send err message queue is fulled HOT 18
- skywalking.oap_authentication 支持这个参数吗? HOT 2
- skywakling导致php命令行终止执行 HOT 1
- 引入skywalking后,当访问增加时,进程被杀掉了
- 安装skywalking扩展后,执行php脚本报错
- sky_request_flush message_queue exNo such file or directory
- Error relocating skywalking.so: rc_dtor_func: symbol not found HOT 1
- 5.0.1 不配置 service_instance 不上报数据,配置 service_instance 上报为空
- 数据没有显现
- php skywalking 5.0.1 没有mysql和redis 等链路监控数据 HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from skyapm-php-sdk.