当前位置: 首页 > news >正文

arthas监控工具笔记(二)monior等

文章目录

    • monitor/watch/trace 相关
      • monitor
        • monitor例子
          • monitor -c <value>
          • monitor -m <vaule>
          • monitor 条件表达式
          • monitor -b
        • monitor文档(界面描述)
        • monitor文档(help)
      • stack - 输出当前方法被调用的调用路径
      • trace - 方法内部调用路径,并输出方法路径上的每个节点上耗时
      • tt - 方法执行数据的时空隧道,记录下指定方法每次调用的入参和返回信息,并能对这些不同的时间下调用进行观测
        • tt使用
          • tt 删除
        • tt文档(命令行)
      • watch - 方法执行数据观测
        • watch例子
          • watch target例子
        • watch例子2
        • watch文档(界面)
        • watch文档(命令行)

这是第二章,第一章见博客。

monitor/watch/trace 相关

monitor

monitor是方法监控工具,例如一定时间的次数,成功率,失败率,响应时间等。
还可以根据条件进行过滤。

monitor例子

不加任何参数:
monitor org.apache.commons.lang.StringUtils isBlank

monitor -c

monitor -c 5 org.apache.commons.lang.StringUtils isBlank
-c --cycle 表示统计周期,默认60s。设置为-c 5我们发现命令行每5s打印一次,如果设置为-c 10,每10s打印一次。

monitor -m

monitor -m 1 -c 5 org.apache.commons.lang3.StringUtils isBlank
-m, --maxMatch 表示匹配类的最大限制数,感觉是为了避免相同类内容太多,加上这个参数如果实际类数量>-m的值,会报错。

例如:

[arthas@23052]$ monitor -m 1 -c 5 org.apache.commons.lang3.StringUtils 
isBlank
输出:
Affect(class count: 0 , method count: 0) cost in 9 ms, listenerId: 14
The number of matched classes is 2, greater than the limit value 1. Try to change the limit with option '-m <arg>'.
monitor 条件表达式

monitor -c 5 com.example.controller.api.InvoiceApiContorller invoiceQueryFast “params[0] >1”
“params[0] >1” 在方法执行完之后,根据条件表达式进行过滤。
这里有个疑问啊?
如果是spring的@RequestBody报文,怎么写表达式呢?这个表达式是否只能做一些简单的计算。

monitor -b

monitor -c 5 -b com.example.controller.api.InvoiceApiContorller invoiceQueryFast “params[0] >1”
-b 表示在方法执行完之前,根据条件表达式进行过滤。

monitor文档(界面描述)

参数说明
方法拥有一个命名参数 [c:],意思是统计周期(cycle of output),拥有一个整型的参数值

参数名称 参数说明
class-pattern 类名表达式匹配
method-pattern 方法名表达式匹配
condition-express 条件表达式
[E] 开启正则表达式匹配,默认为通配符匹配
[c:] 统计周期,默认值为 120 秒
[b] 在方法调用之前计算 condition-express
[m ] 指定 Class 最大匹配数量,默认值为 50。长格式为[maxMatch ]。

monitor文档(help)

输入 help monitor,返回的内容就是文档:

help monitor
USAGE:monitor [-b] [-c <value>] [--exclude-class-pattern <value>] [-h] [-n <value>] [--listenerId <value>] [-m <value>] [
-E] [-v] class-pattern method-pattern [condition-express]SUMMARY:Monitor method execution statistics, e.g. total/success/failure count, average rt, fail rate, etc.Examples:monitor org.apache.commons.lang.StringUtils isBlankmonitor org.apache.commons.lang.StringUtils isBlank -c 5monitor org.apache.commons.lang.StringUtils isBlank params[0]!=nullmonitor -b org.apache.commons.lang.StringUtils isBlank params[0]!=nullmonitor -E org\.apache\.commons\.lang\.StringUtils isBlankWIKI:https://arthas.aliyun.com/doc/monitorOPTIONS:
-b, --before                            Evaluate the condition-express before method invoke
-c, --cycle <value>                     The monitor interval (in seconds), 60 seconds by default--exclude-class-pattern <value>     exclude class name pattern, use either '.' or '/' as separator
-h, --help                              this help
-n, --limits <value>                    Threshold of execution times--listenerId <value>                The special listenerId
-m, --maxMatch <value>                  The maximum of matched class.
-E, --regex                             Enable regular expression to match (wildcard matching by default)
-v, --verbose                           Enables print verbose information, default value false.
<class-pattern>                         Path and classname of Pattern Matching
<method-pattern>                        Method of Pattern Matching
<condition-express>                     Conditional expression in ognl style, for example:TRUE  : 1==1TRUE  : trueFALSE : falseTRUE  : 'params.length>=0'FALSE : 1==2'#cost>100'

stack - 输出当前方法被调用的调用路径

trace - 方法内部调用路径,并输出方法路径上的每个节点上耗时

tt - 方法执行数据的时空隧道,记录下指定方法每次调用的入参和返回信息,并能对这些不同的时间下调用进行观测

tt命令是最有用的命令之一。
如何理解tt呢,相当于将请求快照保存了一份,可以随时调阅。

tt使用

tt -t com.example.controller.RedisController keys
-t, --time-tunnel 时空隧道(相当于快照),这个参数必传

tt -t -n -m com.example.controller.RedisController keys
-n --limits 限制记录条数,如果请求足够多,瞬间可能撑爆内存。
-m --maxMatch 限制匹配类的数量,例如String类,那么匹配的类太多。

-t
tt 命令有很多个主参数,-t 就是其中之一。这个参数的表明希望记录下类 *Test 的 print 方法的每次执行情况。

-n 3
当你执行一个调用量不高的方法时可能你还能有足够的时间用 CTRL+C 中断 tt 命令记录的过程,但如果遇到调用量非常大的方法,瞬间就能将你的 JVM 内存撑爆。

此时你可以通过 -n 参数指定你需要记录的次数,当达到记录次数时 Arthas 会主动中断 tt 命令的记录过程,避免人工操作无法停止的情况。

-m 1
通过 -m 参数指定 Class 匹配的最大数量,防止匹配到的 Class 数量太多导致 JVM 挂起,默认值是 50。

tt 删除

删除单条:

tt -d -i 1001 # 注:删除时-i必填,否则报错(因为不指定索引谁知道该删除哪条呢?)-i, --index <value>
tt -d 1001 # 错误的命令

报错:
Error during processing the command:
java.lang.IllegalArgumentException, message:Time fragment index is expected,
please type -i to specify
, please check $HOME/logs/arthas/arthas.log for more details.

这句说的很明显了,需要指定索引。 至于最后一句是通用的语句,让看日志呢。

删除全部:
tt --delete-all # 这个没报错,全都删除了

tt文档(命令行)
[arthas@22560]$ help ttUSAGE:tt [-d] [--delete-all] [--exclude-class-pattern <value>] [-x <value>] [-h] [-i <value>] [-n <value>] [-l] [--listenerId <value>][-m <value>] [-p] [-E] [--replay-interval <value>] [--replay-times <value>] [-s <value>] [-M <value>] [-t] [-v] [-w <value>] [class-pattern] [method-pattern] [condition-express]SUMMARY:Time TunnelThe express may be one of the following expression (evaluated dynamically):target : the objectclazz : the object's classmethod : the constructor or methodparams : the parameters array of methodparams[0..n] : the element of parameters arrayreturnObj : the returned object of methodthrowExp : the throw exception of methodisReturn : the method ended by returnisThrow : the method ended by throwing exception#cost : the execution time in ms of method invocationEXAMPLES:tt -t *StringUtils isEmptytt -t *StringUtils isEmpty params[0].length==1tt -ltt -i 1000tt -i 1000 -w params[0]tt -i 1000 -ptt -i 1000 -p --replay-times 3 --replay-interval 3000tt -s '{params[0] > 1}' -w '{params}'tt --delete-allWIKI:https://arthas.aliyun.com/doc/ttOPTIONS:-d, --delete                                Delete time fragment specified by index--delete-all                            Delete all the time fragments--exclude-class-pattern <value>         exclude class name pattern, use either '.' or '/' as separator-x, --expand <value>                        Expand level of object (1 by default)-h, --help                                  this help-i, --index <value>                         Display the detailed information from specified time fragment-n, --limits <value>                        Threshold of execution times, default value 100-l, --list                                  List all the time fragments--listenerId <value>                    The special listenerId-m, --maxMatch <value>                      The maximum of matched class.-p, --play                                  Replay the time fragment specified by index-E, --regex                                 Enable regular expression to match (wildcard matching by default)--replay-interval <value>               replay interval  for  play tt with option r greater than 1--replay-times <value>                  execution times when play tt-s, --search-express <value>                Search-expression, to search the time fragments by ognl express.The structure of 'advice' like conditional expression-M, --sizeLimit <value>                     Upper size limit in bytes for the result (10 * 1024 * 1024 by default)-t, --time-tunnel                           Record the method invocation within time fragments-v, --verbose                               Enables print verbose information, default value false.-w, --watch-express <value>                 watch the time fragment by ognl express.Examples:paramsparams[0]'params[0]+params[1]''{params[0], target, returnObj}'returnObjthrowExptargetclazzmethod<class-pattern>                             Path and classname of Pattern Matching<method-pattern>                            Method of Pattern Matching<condition-express>                         Conditional expression in ognl style, for example:TRUE  : 1==1TRUE  : trueFALSE : falseTRUE  : 'params.length>=0'FALSE : 1==2'#cost>100'

watch - 方法执行数据观测

watch主要用于监控查看方法的参数等。
测试需要这么测。
1、先执行命令监控。
2、再调用该方法,上面的监控就会打印指定的输出。

怎么感觉这个功能日志就可以做到呢?

watch例子

监控所有参数:

watch com.example.controller.RedisController keys "params"
Press Q or Ctrl+C to abort.
Affect(class count: 1 , method count: 1) cost in 85 ms, listenerId: 8当方法到达后,输出内容:
method=com.example.controller.RedisController.keys location=AtExit
ts=2024-06-27 14:28:39; [cost=34.9303ms] result=@Object[][@RedisMapRequest[RedisMapRequest(key=set1, sonKey=null, sonValue=null, map=null)],
]

监控第一个参数:

watch com.example.controller.RedisController keys "params[0]"  # 第一个参数

监控参数的size:
watch com.taobao.container.Test test "params[0].size()"

那么问题来了,如何监控返回结果?
这3个分别表示入参,目标,返回结果。

{params, target, returnObj}

3个参数一起写,只会输出第三个参数,所以就写一个吧:
watch com.example.controller.RedisController keys "params, target, returnObj" # 3个都写

watch com.example.controller.RedisController keys "returnObj" # 只写一个

watch target例子

watch com.example.controller.RedisController keys "target" # target

[arthas@22560]$ watch com.example.controller.RedisController keys "target"
Press Q or Ctrl+C to abort.
Affect(class count: 1 , method count: 1) cost in 88 ms, listenerId: 15返回结果:
method=com.example.controller.RedisController.keys location=AtExit
ts=2024-06-27 15:04:31; [cost=25.5637ms] result=@RedisController[age=@Integer[2],logger=@Logger[Logger[com.example.controller.RedisController]],redisTemplate=@RedisTemplate[org.springframework.data.redis.core.RedisTemplate@5b4f914],
]

target会返回方法及所属磊信息。

watch例子2
watch文档(界面)

watch 的参数比较多,主要是因为它能在 4 个不同的场景观察对象。

参数名称参数说明
class-pattern类名表达式匹配
method-pattern函数名表达式匹配
express观察表达式,默认值:{params, target, returnObj}
condition-express条件表达式
[b]函数调用之前观察
[e]函数异常之后观察
[s]函数返回之后观察
[f]函数结束之后(正常返回和异常返回)观察
[E]开启正则表达式匹配,默认为通配符匹配
[x:]指定输出结果的属性遍历深度,默认为 1,最大值是 4
[m <arg>]指定 Class 最大匹配数量,默认值为 50。长格式为[maxMatch <arg>]

这里重点要说明的是观察表达式,观察表达式的构成主要由 ognl 表达式组成,所以你可以这样写"{params,returnObj}",只要是一个合法的 ognl 表达式,都能被正常支持。

观察的维度也比较多,主要体现在参数 advice 的数据结构上。Advice 参数最主要是封装了通知节点的所有信息。请参考表达式核心变量中关于该节点的描述。

特殊用法请参考:https://github.com/alibaba/arthas/issues/71
OGNL 表达式官网:https://commons.apache.org/proper/commons-ognl/language-guide.html

watch文档(命令行)

help watch。

[arthas@22560]$ help watchUSAGE:watch [-b] [-e] [--exclude-class-pattern <value>] [-x <value>] [-f] [-h] [-n <value>] [--listenerId <value>] [-m <value>] [-E] [-M <value>] [-s] [-v] class-pattern method-pattern [express] [condition-express]SUMMARY:Display the input/output parameter, return object, and thrown exception of specified method invocationThe express may be one of the following expression (evaluated dynamically):target : the objectclazz : the object's classmethod : the constructor or methodparams : the parameters array of methodparams[0..n] : the element of parameters arrayreturnObj : the returned object of methodthrowExp : the throw exception of methodisReturn : the method ended by returnisThrow : the method ended by throwing exception#cost : the execution time in ms of method invocationExamples:watch org.apache.commons.lang.StringUtils isBlankwatch org.apache.commons.lang.StringUtils isBlank '{params, target, returnObj, throwExp}' -x 2watch *StringUtils isBlank params[0] params[0].length==1watch *StringUtils isBlank params '#cost>100'watch -f *StringUtils isBlank paramswatch *StringUtils isBlank params[0]watch -E -b org\.apache\.commons\.lang\.StringUtils isBlank params[0]watch javax.servlet.Filter * --exclude-class-pattern com.demo.TestFilterwatch OuterClass$InnerClassWIKI:https://arthas.aliyun.com/doc/watchOPTIONS:-b, --before                                Watch before invocation-e, --exception                             Watch after throw exception--exclude-class-pattern <value>         exclude class name pattern, use either '.' or '/' as separator-x, --expand <value>                        Expand level of object (1 by default), the max value is 4-f, --finish                                Watch after invocation, enable by default-h, --help                                  this help-n, --limits <value>                        Threshold of execution times--listenerId <value>                    The special listenerId-m, --maxMatch <value>                      The maximum of matched class.-E, --regex                                 Enable regular expression to match (wildcard matching by default)-M, --sizeLimit <value>                     Upper size limit in bytes for the result (10 * 1024 * 1024 by default)-s, --success                               Watch after successful invocation-v, --verbose                               Enables print verbose information, default value false.<class-pattern>                             The full qualified class name you want to watch<method-pattern>                            The method name you want to watch<express>                                   The content you want to watch, written by ognl. Default value is '{params, target, returnObj}'Examples:paramsparams[0]'params[0]+params[1]''{params[0], target, returnObj}'returnObjthrowExptargetclazzmethod<condition-express>                         Conditional expression in ognl style, for example:TRUE  : 1==1TRUE  : trueFALSE : falseTRUE  : 'params.length>=0'FALSE : 1==2'#cost>100'

相关文章:

arthas监控工具笔记(二)monior等

文章目录 monitor/watch/trace 相关monitormonitor例子monitor -c <value>monitor -m <vaule>monitor 条件表达式monitor -b monitor文档(界面描述)monitor文档(help) stack - 输出当前方法被调用的调用路径trace - 方法内部调用路径&#xff0c;并输出方法路径上的…...

【mybatis】mybatis-plus中主键生成策略

1、简介 MyBatis-Plus 中的主键生成策略是一个关键特性&#xff0c;它决定了如何为新插入的行生成唯一标识符&#xff08;即主键&#xff09;。MyBatis-Plus 提供了多种主键生成策略&#xff0c;以满足不同场景下的需求。 2、常见主键生成策略 1. AUTO&#xff08;数据库ID自…...

模型情景制作-如何制作棕榈树

夏天&#xff0c;沙滩&#xff0c;海景&#xff0c;棕榈树&#xff0c;外加美女&#xff0c;想象下热带海滨的样子吧 可是口年的上班族没有多少机会去到海滩&#xff0c;肿么办&#xff1f;我们自己DIY一个海滨情景摆在办公桌上吧~~~ 什么什么&#xff1f;棕榈树不会做&#xf…...

# mysql 中文乱码问题分析

mysql 中文乱码问题分析 一、问题分析&#xff1a; MySQL 中文乱码通常是因为字符集设置不正确导致的。MySQL 有多种字符集&#xff0c;如 latin1、utf8、utf8mb4 等&#xff0c;如果在创建数据库、数据表或者字段时没有指定正确的字符集&#xff0c;或者在插入数据时使用了与…...

[小试牛刀-习题练]《计算机组成原理》之指令系统

一、选择题 0.【指令-课本习题】某计算机按字节编址&#xff0c;指令字长固定且只有两种指令格式&#xff0c;其中三地址指令29条&#xff0c;二地址指令107条&#xff0c;每个地址字段为6位&#xff0c;则指令字长至少应该是&#xff08;A&#xff09; A.24位 B. 26位 C. 28位…...

JAVA 实现拍卖框架及拍卖详情流程介绍(包含代码示咧)

本人详解 作者:王文峰,参加过 CSDN 2020年度博客之星,《Java王大师王天师》 公众号:JAVA开发王大师,专注于天道酬勤的 Java 开发问题中国国学、传统文化和代码爱好者的程序人生,期待你的关注和支持!本人外号:神秘小峯 山峯 转载说明:务必注明来源(注明:作者:王文峰…...

力扣1177.构建回文串检测

力扣1177.构建回文串检测 因为子串可以重新排序 因此考虑一下什么情况需要替换字母1.当前有一个字母的数量为奇数 需要替换的次数为0 2.当前有二个字母的数量为奇数 需要替换的次数为1 (奇数个a 奇数个b 需要将b -> a) 3.当前有三个字母的数量为奇数 需要替换的次数为1 4.当…...

Vue跨域获取ip和ip位置城市等归属地信息

由于端口设置与查询服务器不一致&#xff0c;所以不能直接从ip138网上抓取&#xff0c;只能跨域查询。实现跨域查询&#xff0c;简单的方法是使用jsonp方式&#xff0c;只支持get请求&#xff0c;同时也需要查询的服务器支持jsonp。这时找到了腾讯位置服务。参考文章&#xff0…...

缺失的第一个正数

给你一个未排序的整数数组 nums &#xff0c;请你找出其中没有出现的最小的正整数。 请你实现时间复杂度为 O(n) 并且只使用常数级别额外空间的解决方案。 示例 1&#xff1a; 输入&#xff1a;nums [1,2,0] 输出&#xff1a;3 解释&#xff1a;范围 [1,2] 中的数字都在数组…...

mac 上 Docker Desktop的免费开源的替代工具Colima

当谈到在macOS上运行容器时&#xff0c;Docker长期以来一直是首选。但是&#xff0c;必须解决使用适用于macOS的Docker Desktop时出现的一些限制&#xff0c;特别是对于大中型公司&#xff0c;最大的问题是需要购买许可证。另外&#xff0c;macOS 版Docker Desktop的性能问题也…...

C语言 -- 函数

C语言 -- 函数 1. 函数的概念2. 库函数2.1 标准库和头文件2.2 库函数的使用方法2.2.1 功能2.2.2 头文件包含2.2.3 实践2.2.4 库函数文档的一般格式 3. 自定义函数3.1 函数的语法形式3.2 函数的举例 4. 形参和实参4.1 实参4.2 形参4.3 实参和形参的关系 5. return 语句6. 数组做…...

Cesium 立式雷达扫描

Cesium 立式雷达扫描 自定义 Primitive 实现支持水平和垂直交替扫描...

Oracle HTTP Server(OHS)与Oracle数据库的紧密绑定

Oracle HTTP Server&#xff08;OHS&#xff09;与Oracle数据库的紧密绑定通常是通过一系列的配置和集成步骤来实现的。以下是这些步骤的详细归纳&#xff0c;包括必要的分点表示和参考信息&#xff1a; 一、安装和配置Oracle HTTP Server 安装OHS&#xff1a; 在安装Oracle…...

mmcv安装失败及解决方案

假如想安装的版本是mmcv1.4.0, 但是pip install mmcv1.4.0总是失败&#xff0c;若是直接pip install mmcv会安装成功&#xff0c;但是安装的就是最新版本&#xff0c;后面代码跑起来还会报错&#xff0c;怎么办呢&#xff1f; 接下来分享一个mmcv指定版本安装的方式。 网页&a…...

国产强大免费WAF, 社区版雷池动态防护介绍

雷池WAF&#xff0c;基于智能语义分析的下一代 Web 应用防火墙 使用情况 我司于2023年4月23日对雷池进行测试&#xff0c;测试一个月后&#xff0c;于2023年5月24日对雷池进行正式切换&#xff0c;此时版本为1.5.1。 里程碑纪念 后续一直跟随雷池进行版本升级&#xff0c;当前…...

【Django】网上蛋糕项目商城-首页

概念 本文在上一文章搭建完数据库&#xff0c;以及创建好项目之后&#xff0c;以及前端静态文件后&#xff0c;对项目的首页功能开发。 后端代码编写 在views.py文件中创建方法&#xff0c;连接数据库&#xff0c;并获取首页需要的数据 def getGoodsList(type):# 获取所有横…...

Vue 父子页面使用指南

Vue3父子页面使用指南 Vue3作为一种现代化的前端框架&#xff0c;提供了强大的组件化功能&#xff0c;使得页面开发更加模块化和可维护。本文将深入探讨Vue3中父子页面的使用方法&#xff0c;包括如何传递参数、父组件如何调用子组件的方法&#xff0c;以及父子页面的加载原理…...

TVBox自定义配置+软件密码版本

apk地址 : https://gitee.com/wheat-wheat/kekeda-duck-apk 1、安装安卓SDK Android SDK Windows 安装及环境配置教程_sdk manager windows-CSDN博客 修改点: 基础配置: java版本:...

Java单体架构项目_云霄外卖-特殊点

项目介绍&#xff1a; 定位&#xff1a; 专门为餐饮企业&#xff08;餐厅、饭店&#xff09;定制的一款软件商品 分为&#xff1a; 管理端&#xff1a;外卖商家使用 用户端&#xff08;微信小程序&#xff09;&#xff1a;点餐用户使用。 功能架构&#xff1a; &#xff08…...

一文搞懂 java 线程池:ScheduledThreadPool 和 WorkStealingPool 原理

你好&#xff0c;我是 shengjk1&#xff0c;多年大厂经验&#xff0c;努力构建 通俗易懂的、好玩的编程语言教程。 欢迎关注&#xff01;你会有如下收益&#xff1a; 了解大厂经验拥有和大厂相匹配的技术等 希望看什么&#xff0c;评论或者私信告诉我&#xff01; 文章目录 一…...

边缘计算医疗风险自查APP开发方案

核心目标:在便携设备(智能手表/家用检测仪)部署轻量化疾病预测模型,实现低延迟、隐私安全的实时健康风险评估。 一、技术架构设计 #mermaid-svg-iuNaeeLK2YoFKfao {font-family:"trebuchet ms",verdana,arial,sans-serif;font-size:16px;fill:#333;}#mermaid-svg…...

五年级数学知识边界总结思考-下册

目录 一、背景二、过程1.观察物体小学五年级下册“观察物体”知识点详解&#xff1a;由来、作用与意义**一、知识点核心内容****二、知识点的由来&#xff1a;从生活实践到数学抽象****三、知识的作用&#xff1a;解决实际问题的工具****四、学习的意义&#xff1a;培养核心素养…...

Axios请求超时重发机制

Axios 超时重新请求实现方案 在 Axios 中实现超时重新请求可以通过以下几种方式&#xff1a; 1. 使用拦截器实现自动重试 import axios from axios;// 创建axios实例 const instance axios.create();// 设置超时时间 instance.defaults.timeout 5000;// 最大重试次数 cons…...

HTML前端开发:JavaScript 常用事件详解

作为前端开发的核心&#xff0c;JavaScript 事件是用户与网页交互的基础。以下是常见事件的详细说明和用法示例&#xff1a; 1. onclick - 点击事件 当元素被单击时触发&#xff08;左键点击&#xff09; button.onclick function() {alert("按钮被点击了&#xff01;&…...

k8s业务程序联调工具-KtConnect

概述 原理 工具作用是建立了一个从本地到集群的单向VPN&#xff0c;根据VPN原理&#xff0c;打通两个内网必然需要借助一个公共中继节点&#xff0c;ktconnect工具巧妙的利用k8s原生的portforward能力&#xff0c;简化了建立连接的过程&#xff0c;apiserver间接起到了中继节…...

SpringCloudGateway 自定义局部过滤器

场景&#xff1a; 将所有请求转化为同一路径请求&#xff08;方便穿网配置&#xff09;在请求头内标识原来路径&#xff0c;然后在将请求分发给不同服务 AllToOneGatewayFilterFactory import lombok.Getter; import lombok.Setter; import lombok.extern.slf4j.Slf4j; impor…...

智能分布式爬虫的数据处理流水线优化:基于深度强化学习的数据质量控制

在数字化浪潮席卷全球的今天&#xff0c;数据已成为企业和研究机构的核心资产。智能分布式爬虫作为高效的数据采集工具&#xff0c;在大规模数据获取中发挥着关键作用。然而&#xff0c;传统的数据处理流水线在面对复杂多变的网络环境和海量异构数据时&#xff0c;常出现数据质…...

使用 Streamlit 构建支持主流大模型与 Ollama 的轻量级统一平台

🎯 使用 Streamlit 构建支持主流大模型与 Ollama 的轻量级统一平台 📌 项目背景 随着大语言模型(LLM)的广泛应用,开发者常面临多个挑战: 各大模型(OpenAI、Claude、Gemini、Ollama)接口风格不统一;缺乏一个统一平台进行模型调用与测试;本地模型 Ollama 的集成与前…...

【Android】Android 开发 ADB 常用指令

查看当前连接的设备 adb devices 连接设备 adb connect 设备IP 断开已连接的设备 adb disconnect 设备IP 安装应用 adb install 安装包的路径 卸载应用 adb uninstall 应用包名 查看已安装的应用包名 adb shell pm list packages 查看已安装的第三方应用包名 adb shell pm list…...

适应性Java用于现代 API:REST、GraphQL 和事件驱动

在快速发展的软件开发领域&#xff0c;REST、GraphQL 和事件驱动架构等新的 API 标准对于构建可扩展、高效的系统至关重要。Java 在现代 API 方面以其在企业应用中的稳定性而闻名&#xff0c;不断适应这些现代范式的需求。随着不断发展的生态系统&#xff0c;Java 在现代 API 方…...