augushong
|
a43a9a48b9
|
feat(tools): XHProf 日志导入三层服务与函数监控物化
- XhprofProfileParserService(Base/App):纯数组解析 jsonl 行,
meta 字段以真实 fixture 为准;simple_url 缺失兜底与采集端回调同算法;
watch 正则按 callee 物化(ct/wt_sum/wt_max),非法正则编译计 fail 跳过
- XhprofLogReaderService(Base/App):增量读取,半行缓冲超限整行丢弃
(不照抄 nginx 8MB 强制切行);EOF 无换行半行不 yield 不推进 offset;
进度不自动落盘,由导入侧在同一事务内显式 savePosition
- XhprofLogImport 定时任务(Base/App):不受 XHPROF_ENABLE 门控,
runs-*.jsonl 按文件名序增量导入;run 逐条 insert + detail chunk 20
insertAll + run_watch insertAll 与 position 同事务落盘;导至 EOF 后
只删已导完文件
- 修复 T1 缺陷:request_time decimal(12,3) 装不下 10 位时间戳,
Scheme 与 migration 同步改 decimal(13,3)
- 新增 parser 单元测试(真实 fixture 断言,9 用例 42 断言)
与 jsonl fixture;phpunit 注册 unit 测试套件
|
2026-08-15 06:11:01 +08:00 |
|
augushong
|
073172473b
|
chore: gitignore 忽略 phpunit 测试缓存目录
tests/.phpunit.cache/ 是 phpunit 运行产生的测试结果缓存(phpunit.xml.dist cacheDirectory 指向),不应纳入版本控制。
|
2026-07-18 23:57:55 +08:00 |
|
augushong
|
37cb8291f8
|
feat(test): 引入测试规则文档与参数化测试库初始化脚本
对齐 wkbox 衍生项目的测试规则体系,剥离业务特定内容后移植到框架:
- 规则 .agents/rules/ulthon-testing.md(设计哲学/决策树/4层模型/安全规范/fixture原则)
- 技能 .agents/skills/ulthon-testing(运行/编写/模板/决策/回归验证)
- 参数化建库脚本 tests/setup_test_db.{php,ps1,sh} + README
- AGENTS.md 索引补充
与 wkbox 差异:测试库参数化(复用 .env 连接,database=env+'_test'),不硬编码 Docker;删去 canBind Oracle 业务约束与具体 fixture 工厂,业务工厂由衍生项目自行实现。
|
2026-07-18 23:56:32 +08:00 |
|
augushong
|
ce8a0c795b
|
docs: 更新 agent 规则并新增项目约束文档
|
2026-07-18 23:35:04 +08:00 |
|
augushong
|
3f7050bf65
|
feat(test): 框架测试基建基类TestCaseBase+app层入口+冒烟测试
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-07-18 00:12:41 +08:00 |
|
augushong
|
44621b1e9d
|
chore(test): 引入 PHPUnit 测试基建(依赖+配置+bootstrap)
Ultraworked with [Sisyphus](https://github.com/code-yeongyu/oh-my-openagent)
Co-authored-by: Sisyphus <clio-agent@sisyphuslabs.ai>
|
2026-07-18 00:12:30 +08:00 |
|