-
Notifications
You must be signed in to change notification settings - Fork 172
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
【enhancement】优化输出被增强类字节码文件的开关和路径配置 #1163
Conversation
Codecov ReportPatch coverage has no change and project coverage change:
Additional details and impacted files@@ Coverage Diff @@
## develop #1163 +/- ##
==============================================
+ Coverage 0 41.57% +41.57%
- Complexity 0 3184 +3184
==============================================
Files 0 810 +810
Lines 0 17826 +17826
Branches 0 1938 +1938
==============================================
+ Hits 0 7411 +7411
- Misses 0 9475 +9475
- Partials 0 940 +940
Flags with carried forward coverage won't be shown. Click here to find out more.
... and 806 files with indirect coverage changes Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report in Codecov by Sentry. |
a73e6b6
to
993b6e5
Compare
...sermant-agentcore-core/src/main/java/com/huaweicloud/sermant/core/common/CommonConstant.java
Outdated
Show resolved
Hide resolved
sermant-agentcore/sermant-agentcore-config/config/config.properties
Outdated
Show resolved
Hide resolved
sermant-agentcore/sermant-agentcore-config/config/config.properties
Outdated
Show resolved
Hide resolved
efeead7
to
78f86f6
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
【修复issue】#1162
【修改内容】
1、在config.properties增加被增强类的字节码文件输出开关agent.config.isOutputEnhancedClasses,默认为false。
2、默认输出路径为sermant-agent/agent/enhancedClasses/20230401160102123, 最后一层文件夹为输出时间
3、自定义输出路径agent.config.enhancedClassesOutputPath默认为空,如果不配置,将使用2中的默认输出路径。
【用例描述】
测试用例1:
步骤:
(1)agent.config.isOutputEnhancedClasses=false,其余配置不修改,挂载sermant启动宿主应用
(2)查看sermant-agent/agent是否有文件输出
结果:
(1)无输出
测试用例2:
(1)agent.config.isOutputEnhancedClasses=true,其余配置不修改,挂载sermant启动宿主应用
(2)查看sermant-agent/agent是否有文件输出
结果:
(1)sermant-agent/agent/enhancedClasses/20230401160102123, 文件夹中输出被增强类的字节码文件
测试用例3:
(1)agent.config.isOutputEnhancedClasses=true,agent.config.enhancedClassesOutputPath=自定义路径,其余配置不修改,挂载sermant启动宿主应用
(2)查看自定义路径是否有文件输出
结果:
(1)自定义路径/enhancedClasses/20230401160102123, 文件夹中输出被增强类的字节码文件
【自测情况】1、本地静态检查通过;2、测试用例通过
【影响范围】用户需输出查看被增强类的字节码文件时可修改上述配置