启动arthas

java -jar arthas-boot.jar

记录RequestMappingHandlerAdapter#invokeHandlerMethod的请求,获取index

tt -t org.springframework.web.servlet.mvc.method.annotation.RequestMappingHandlerAdapter invokeHandlerMethod

获取SpringContext

tt -i 第二步的index -w '
#ac=target.getApplicationContext()
'

此处’'中的语法为OGNL,详细指南:http://commons.apache.org/proper/commons-ognl/language-guide.html

通过SpringContext获取Spring容器中任意一个Component

tt -i 第二步的index -w '
#ac=target.getApplicationContext(),
#orderDomainService=#ac.getBean("orderDomainServiceImpl"),
#subOrderEntityRepository=#ac.getBean("subOrderEntityRepository"),
#order=#orderDomainService.doMethod("指定子订单号"),
#subOrderEntity=#order.getSubOrderEntityList().get(0),
#requestJson=@com.poizon.fusion.utils.JsonUtils@serialize(#subOrderEntity)'

运行结果:

{"id":410,"orderNo":"510100016560346748","subOrderNo":"110100016560356748","bizType":"CONSIGN","bizCode":"duapp.general","bizChannel":"","bizId":"","status":"TRADE_SUCCESS","buyerInfo":{"userId":45816748,"userName":"慈祥喷泡zFJ"},"sellerInfo":{"userId":10029,"userName":"我手机三脚架"},"productPrice":13900,"freightPrice":1400,"payAmount":15300,"discountAmount":0,"depositAmount":2800,"poundageAmount":3648,"count":1,"freightInfo":{"freight":1400,"freightGray":false},"buyerLogisticEntity":{"id":431,"logisticNo":"EX1010007132106748","logisticStage":3,"orderNo":"510100016560346748","subOrderNo":"110100016560356748","buyerId":45816748,"expressType":"SF","expressNo":"SF773278234517","expressStatus":20,"senderAddress":"上海上海市虹口区互联宝地","receiverAddress":"江苏省南京市玄武区互联宝地","senderMobile":"1231232435435","receiverMobile":"17612160914","feature":"{"receiptStatus":true,"signTime":"2021-03-07 10:50:59","sendTime":"2021-02-28 10:50:59"}","logisticFeature":{"receiptStatus":true,"signTime":"2021-03-07 10:50:59","sendTime":"2021-02-28 10:50:59"},"createTime":"2021-02-28 10:50:52.000","modifyTime":"2021-03-07 10:50:59.225"},"inventoryNo":"SN109615732","skuId":324537,"buyerNote":"","sellerNote":"","buyerDel":0,"subOrderCloseTime":"2021-02-28 10:50:52.611","paidTime":"2021-02-28 10:50:54.485","createTime":"2021-02-28 10:50:52.000","modifyTime":"2021-03-07 10:50:59.212","roundId":0,"buyerAddressId":0,"discountInfos":[],"useRedPacket":false,"useAllowance":false,"productId":55,"productInfo":{"skuId":324537,"skuPic":"[https://cdn.poizon.com/source-img/origin-img/20201210/105c1de1fec844038f07f42e7eeea50c.jpg](https://cdn.poizon.com/source-img/origin-img/20201210/105c1de1fec844038f07f42e7eeea50c.jpg)","skuCategory":38,"skuTitle":"打折Nike Dunk Low Premiun SB QS 北京","spuId":55,"spuTitle":"打折Nike Dunk Low Premiun SB QS 北京","skuProp":{"6":"35.5"},"skuTagType":5,"signupPrice":0,"authPrice":5800,"articleNumber":"504750-077","otherNumbers":"","preSellDeliverTime":0,"isSelf":0,"sellLimitPurchase":0,"preSellLimitPurchase":1,"level1CategoryId":29,"level2CategoryId":35,"categoryTag":"{"PAYMENT":["PAYMENT_HUABEI","PAYMENT_HUABEI_STAGING"]}","goodsType":0,"brandId":144,"relationBrandIds":"","fitId":1,"receiveMinTime":2,"receiveMaxTime":2,"saleAfterFlag":0,"unconditionalReturn":0,"size":"35.5","self":false},"sellerAddressInfo":{"userId":10029,"zipCode":""},"repositoryAddress":{"userAddressId":3,"province":"上海","city":"上海市","district":"虹口区","address":"互联宝地","addressDetail":"上海上海市虹口区互联宝地","mobile":"1231232435435","name":"得物白冰冰","warehouseAddressType":"VIRTUAL","zipCode":"","warehouseCode":"SH12","warehouseZoneCode":"YQSH01"},"buyerAddressInfo":{"userAddressId":1010004160,"userId":45816748,"province":"江苏省","city":"南京市","district":"玄武区","address":"互联宝地","addressDetail":"江苏省南京市玄武区互联宝地","mobile":"17612160914","name":"红包吧v","countryCode":"","modifyTimes":0,"zipCode":"","optionalAddress":"","userMobile":"11122221604","hasSelfBuy":false,"hasCheck":true,"realReceiveSmsMobile":"17612160914"},"sellerBackAddressInfo":{"userAddressId":1010004113,"userId":10029,"province":"浙江省","city":"杭州市","district":"西湖区","address":"尴尬vv","addressDetail":"浙江省杭州市西湖区尴尬vv","mobile":"15618153285","name":"沟沟壑壑","countryCode":"","modifyTimes":0,"zipCode":"","optionalAddress":""},"poundageInfo":{"poundageInfoList":[{"expenseType":1,"expenseName":"技术服务费","originalExpense":209,"currentExpense":209,"originalPercent":150,"currentPercent":150,"extendJson":"{"currentPercent":150,"currentexpense":209,"expenseLimit":{"max":24900,"min":0},"originalTechnicalFeeLimit":{"expenseLimit":{"max":24900,"min":0},"originalExpense":209,"originalPercent":150}}"},{"expenseType":3,"expenseName":"转账手续费","originalExpense":139,"currentExpense":139,"originalPercent":100,"currentPercent":100,"extendJson":"{"currentExpense":139,"currentPercent":100,"originalExpense":139,"originalPercent":100}"},{"expenseType":5,"expenseName":"查验费","originalExpense":800,"currentExpense":800,"extendJson":"{"currentExpense":800,"originalExpense":800}"},{"expenseType":2,"expenseName":"鉴别费","originalExpense":1500,"currentExpense":1500,"extendJson":"{"currentExpense":1500,"originalExpense":1500}"},{"expenseType":4,"expenseName":"包装服务费","originalExpense":1000,"currentExpense":1000,"extendJson":"{"currentExpense":1000,"originalExpense":1000}"},{"expenseType":7,"expenseName":"预计收入","originalExpense":10252,"currentExpense":10252},{"expenseType":6,"expenseName":"总费用","originalExpense":3648,"currentExpense":3648}],"version":"1.0.0","totalAmount":3648,"poundageAmount":209},"inventoryInfo":{"saleInventoryNo":"SN109615732","skuId":324537,"uid":10029,"price":13900,"biddingType":5,"deposit":2800,"prepaidFee":1390,"currency":"CNY","countryCode":"CN","deliveryCountryCode":"CN","childSubBiddingType":0,"sellerBiddingNo":"102020031000861366","createTime":1614480650,"modifyTime":1614480651,"deliveryTime":3600,"receiveMinTime":2,"receiveMaxTime":2,"orginInvenNo":"SN109615732","sourceType":"poizon","sourceId":"","warehouseZoneCode":"YQSH01"},"depositInfo":{"prepaidFee":1390,"childSubBiddingType":0,"applyNo":"AP1010009479911","applyItemNo":"JS002916000007166469","jsType":3},"preferentialInfo":{"buyerShowDiscountList":[],"discountList":[],"needRecommend":false,"freightNeedRecommend":false,"oldPreferentialList":[]},"merchantInfo":{"merchantId":318741,"typeId":0,"userId":10029,"username":"翟天凡","realName":"翟天凡","idCardNo":"320*************18","mobile":"11166668888","balanceType":0,"isUnconditionalReturn":1,"isUnconditionalReturnByMerchant":1,"status":1,"adminUserId":0,"merchantIdCard":"PBDR20081180645956","isInvoice":0,"skipCheck":false,"poundageDiscount":-2},"downPaymentInfo":{"promotionNo":"-1","skipCheck":false},"qualityEntity":{"id":287,"orderNo":"510100016560346748","subOrderNo":"110100016560356748","buyerId":45816748,"spuId":324537,"skuId":324537,"qcId":0,"qcResultType":0,"qcResultDesc":"质检通过","qcResultPics":"","confirmStatus":0,"createTime":"2021-02-28 10:50:52.000","modifyTime":"2021-02-28 10:50:52.000","qualityPassedTime":"2021-02-28 10:50:59.000","qualityBeginTime":"2021-02-28 10:50:52.621","feature":"{}","qualityFeature":{}},"identifyEntity":{"id":287,"orderNo":"510100016560346748","subOrderNo":"110100016560356748","spuId":324537,"skuId":324537,"buyerId":45816748,"identifyId":0,"identifyResultType":1,"identifyResultDesc":"鉴别为真","createTime":"2021-02-28 10:50:52.000","modifyTime":"2021-02-28 10:50:52.000","feature":""},"evaluationFlag":"NO","isSelf":0,"deliveryStartTime":"2021-02-28 10:51:54.675","deliveryDeadline":"2021-02-28 11:50:55.000","tabTag":0,"appType":0,"agreeSevenDayWithoutReason":false,"orderFlag":0,"relationSubOrderList":[],"commentList":[],"agreedAutoExchange":false,"sevenDayNoReasonStatus":false,"warehousing":false,"liveFlag":"NO","skipCheckFlag":"NO","autoExchangeSwitch":false,"freightInsuranceChecked":false,"subsidyMap":{"-1":0},"crossBorderPostType":0,"tradeSuccessTime":"2021-03-07 10:50:59.194","biddingAfterSaleInfo":{"sellerBiddingNo":"102020031000861366","afterSalesType":0},"additionBiddingAfterSaleInfo":[],"bizInstanceId":{"bizCode":"duapp.general","bizInstanceId":"510100016560346748"},"unconditionalReturnInBuyerVersion":false,"unconditionalReturnInSellerVersion":false
}

Arthas结合Spring容器 线上排查Tips相关推荐

  1. java线上排查利器arthas

    当你遇到以下类似问题而束手无策时,Arthas可以帮助你解决: 这个类从哪个 jar 包加载的?为什么会报各种类相关的 Exception? 我改的代码为什么没有执行到?难道是我没 commit?分支 ...

  2. 面试常问集锦——线上排查部分

    实操 线上故障如何快速排查?来看这套技巧大全 https://mp.weixin.qq.com/s/PWNnq07cPYB4o421VFEFHw JAVA线上故障排查全家桶 https://mp.we ...

  3. 【线上排查实战】AOP切面执行顺序你真的了解吗

    前言 忙,是我这个月的主旋律,也是我频繁鸽文章的接口----蛮三刀把刀 公司这两个月启动了全新的项目,项目排期满满当当,不过该学习还是要学习.这不,给公司搭项目的时候,踩到了一个Spring AOP的 ...

  4. 线上排查 | 线上Redis负载暴涨100%,业务中断,这样排查很赞!

    HI! 我是小小,今天是本周的第六篇,本篇将会着重讲解关于Redis负载的问题. 网页监控 通过阿里的Grafana监控,发现服务器的CPU负载,内存,网络输入输出相当正常,所以Redis出现问题.使 ...

  5. liunx 线上排查 常用命令

    内存瓶颈 free free 是查看内存使用情况,包括物理内存.交换内存(swap)和内核缓冲区内存. free -h -s 3 表示每隔三秒输出一次内存情况,命令如下 [root@hadoop001 ...

  6. 阿里线上排查工具阿尔萨司

    https://arthas.aliyun.com/doc/install-detail.html

  7. curl命令java_让 Bug 无处藏身,Java 线上问题排查思路、常用工具

    本文总结了一些常见的线上应急现象和对应排查步骤和工具.分享的主要目的是想让对线上问题接触少的同学有个预先认知,免得在遇到实际问题时手忙脚乱. 只不过这里先提示一下.在线上应急过程中要记住,只有一个总体 ...

  8. 线上诊断之arthas

    上篇文章中我们说到java自带的JVM调优工具,但是自带的工具用户体验不是很好,而且工具间来回切换比较繁琐.这篇我们来说一个阿里提供的体验更好,功能更强大的Java 诊断工具Arthas. artha ...

  9. 让bug无处藏身,Java 线上问题排查神器,你学废了吗?

    点击关注公众号,利用碎片时间学习 本文总结了一些常见的线上应急现象和对应排查步骤和工具.分享的主要目的是想让对线上问题接触少的同学有个预先认知,免得在遇到实际问题时手忙脚乱. 只不过这里先提示一下.在 ...

  10. 让bug无处藏身,Java 线上问题排查神器分享

    导语 本文总结了一些常见的线上应急现象和对应排查步骤和工具.分享的主要目的是想让对线上问题接触少的同学有个预先认知,免得在遇到实际问题时手忙脚乱. 正文 这里先提示一下.在线上应急过程中要记住,只有一 ...

最新文章

  1. 让ubuntu下的eclipse支持GBK编码
  2. vue项目刷新当前页面的三种方法
  3. 纯PB9开发短文本加密
  4. xcode 自带的git工具创建项目流程
  5. discuz论坛 java,如何添加Discuz论坛的应用
  6. Qt消息机制和事件概述(一)
  7. struts2 Eclipse 中集成strust2开发框架实例
  8. 数据结构——树的理解路线(总)
  9. fcm脑图像分割matlab,MATLAB程序:用FCM分割脑图像
  10. [转载] 七龙珠第一部——第086话 打进前八强
  11. 在Objective-C中,如何测试对象类型?
  12. libGDX-5:文本显示 BitmapFont 和 工具 hiero
  13. C++ atuo关键字的应用 -- 尾置返回类型(trailing return type)
  14. java自定义异常必须继承什么类_49.Java-自定义异常类
  15. 我的世界服务器银行系统,我的世界多功能银行系统制作教程
  16. 使用HTML5 select标签来实现更改网页背景颜色
  17. php删除双引号,php如何去除引号
  18. 《自己动手写CPU》--第九章--学习笔记
  19. VMware15Pro进入MacOS10.14恢复模式(Recovery)
  20. docmd怎么读_欧路词典|英汉-汉英词典 access是什么意思_access的中文解释和发音_access的翻译_access怎么读...

热门文章

  1. 物联网技术-RFID
  2. linux查看cpu架构命令,linux查看cpu型号命令
  3. Windows conda ImportError: DLL load failed while importing shell
  4. C语言中计算字符串长度的函数
  5. DAU是啥,数据指标是啥?必知必会的数据分析常识
  6. iOS微信分享提示“未验证应用”的解决,配置 Universal Link
  7. html关联程序怎么设置,Win10预览版10102系统中如何设置IE浏览器的关联程序【图文】...
  8. 公司不是家——联想员工亲历2004年联想大裁员【转载】
  9. html毕业答辩ppt模板范文,答辩ppt模板|答辩总结范文
  10. 电子凸轮基本概念学习