-
Notifications
You must be signed in to change notification settings - Fork 3k
[Bug] 代理组为select时testUrl配置不生效 #2013
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
Comments
看了一下代码似乎与这个 commit有关。 |
不返回testUrl不等于不在hc |
metaqube UI 等web UI都是通过这个testUrl来获取延迟测试地址延迟的, 这种情况下select类型的节点组就无法正确的测试延迟 |
@zipfile6652 这只是主动测试去获取testurl传入测试,延迟查看和hc不依赖 |
@xishang0128 感谢回复, 这种在UI上主动触发延迟测试去获取延迟的场景 应该如何正确配置呢? 正如issue一开始提到的, 需求是 特定的代理组配置了特定的延迟测试地址, 想要在主动触发延迟测试的时候使用前面配置的延迟测试地址来测试延迟。 |
@zipfile6652 建议直接url test,又不是不能fixed |
是的, url-test 甚至fallback都能用。 这个似乎没有在文档中或是代码中提示。 |
select 是完全用户控制节点的选择, url-test会主动去探测选择节点,这两者的语义和场景还是有些不同的。 |
@zipfile6652 说了,可以fixed |
刚尝试了一下 fixed的行为与预期的“手动选择优先还是有些区别,reload后还是需要手动再次fixed选择自己想要的proxy。 而且已经fixed的节点如果遇到临时延迟高的情况下会被自动切换。 总而言之, select 提交了一个PR link 在select类型的proxy-group API返回中也返回testUrl, 测试了下面三个面版下都能达到预期的效果: 理论上下述issue也可以得到解决: |
@zipfile6652 但是这会破坏原有逻辑,因为testurl默认附加,导致dashboard无法自定义测试地址 |
感谢提醒, 修改了一下,仅指定了url时才返回testUrl, 否则为空时保持原有逻辑。 经过测试,三个dashboard下的自定义测试地址逻辑保持了原样。 |
cmfa的逻辑是正常的吗?我之前测试就是type为select的代理组只有加上url字段才能正常测延迟。所以cmfa反而纠正了内核的逻辑? |
目前没有去关注cmfa, 不过理论上PR中的变更不会破坏CMFA的纠正。。 因为根据你的描述,CMFA可能是没有用到这个http api来获取group proxies. web dashboard均通过这个API来获取,因此我只测试了上述几个web dashboard |
好的,感谢回答。 |
commit 2b4726b Author: wwqgtxx <[email protected]> Date: Sat May 10 12:32:47 2025 +0800 fix: build on go1.24.3 golang/go#73617 commit 26e6d83 Author: xishang0128 <[email protected]> Date: Wed May 7 17:07:39 2025 +0800 chore: make select display the specified testUrl for MetaCubeX#2013 commit 50d7834 Author: wwqgtxx <[email protected]> Date: Mon May 5 01:32:25 2025 +0800 chore: change the separator of the `SAFE_PATHS` environment variable to the default separator of the operating system platform (i.e., `;` in Windows and `:` in other systems) commit 86c127d Author: wwqgtxx <[email protected]> Date: Sun May 4 10:39:15 2025 +0800 fix: missing read waiter for cancelers commit febb602 Author: wwqgtxx <[email protected]> Date: Sun May 4 11:09:40 2025 +0800 fix: hysteria2 inbound not set UDPTimeout commit 9e57b29 Author: wwqgtxx <[email protected]> Date: Sat May 3 15:06:13 2025 +0800 chore: update dependencies commit 791ea5e Author: wwqgtxx <[email protected]> Date: Thu May 1 12:33:21 2025 +0800 chore: allow setting addition safePaths by environment variable `SAFE_PATHS` package managers can allow for pre-defined safe paths without disabling the entire security check feature for MetaCubeX#2004 commit 7e7016b Author: wwqgtxx <[email protected]> Date: Thu May 1 01:27:08 2025 +0800 chore: removed `routing-mark` and `interface-name` of the group, please set it directly on the proxy instead commit b4fe669 Author: wwqgtxx <[email protected]> Date: Wed Apr 30 23:21:13 2025 +0800 chore: better path checks commit cad26ac Author: wwqgtxx <[email protected]> Date: Wed Apr 30 17:26:45 2025 +0800 chore: fetcher will change duration to achieve fast retry when the update failed with a 2x factor step from 1s to `interval` commit f328203 Author: wwqgtxx <[email protected]> Date: Wed Apr 30 16:03:02 2025 +0800 feat: not inline proxy-provider can also set `payload` as fallback proxies when file/http parsing fails commit 5c40a63 Author: wwqgtxx <[email protected]> Date: Wed Apr 30 14:09:15 2025 +0800 feat: not inline rule-provider can also set `payload` as fallback rules when file/http parsing fails commit 61d6a9a Author: wwqgtxx <[email protected]> Date: Wed Apr 30 13:21:42 2025 +0800 fix: fetcher does not start the pull loop when local file parsing errors occur and the first remote update fails commit a013ac3 Author: wwqgtxx <[email protected]> Date: Tue Apr 29 21:52:44 2025 +0800 chore: give better error messages for some stupid config files commit ee5d77c Author: wwqgtxx <[email protected]> Date: Tue Apr 29 21:15:48 2025 +0800 chore: cleanup tls clientFingerprint code commit 936df90 Author: wwqgtxx <[email protected]> Date: Tue Apr 29 09:01:54 2025 +0800 chore: update dependencies commit f774276 Author: Larvan2 <[email protected]> Date: Mon Apr 28 03:07:21 2025 +0000 fix: ensure wait group completes commit aa51b9f Author: wwqgtxx <[email protected]> Date: Mon Apr 28 10:28:45 2025 +0800 chore: replace using internal batch package to x/sync/errgroup In the original batch implementation, the Go() method will always start a new goroutine and then wait for the concurrency limit, which is unnecessary for the current code. x/sync/errgroup will block Go() until the concurrency limit is met, which can effectively reduce memory usage. In addition, the original batch always saves the return value of Go(), but it is not used in the current code, which will also waste a lot of memory space in high concurrency scenarios. commit d55b047 Author: wwqgtxx <[email protected]> Date: Sun Apr 27 09:39:46 2025 +0800 chore: ignore interfaces not with FlagUp in local interface finding commit efc7abc Author: xishang0128 <[email protected]> Date: Fri Apr 25 12:10:18 2025 +0800 actions: fix pacman build commit c2301f6 Author: wwqgtxx <[email protected]> Date: Fri Apr 25 10:34:34 2025 +0800 chore: rebuild fingerprint and keypair handle commit 468cfc3 Author: WeidiDeng <[email protected]> Date: Thu Apr 24 19:50:16 2025 +0800 fix: set sni to servername if not specified for trojan outbound (MetaCubeX#1991) commit 5dce957 Author: xishang0128 <[email protected]> Date: Thu Apr 24 17:25:14 2025 +0800 actions: improve build process commit 4ecb49b Author: wwqgtxx <[email protected]> Date: Wed Apr 23 12:25:42 2025 +0800 chore: dynamic fetch remoteAddr in hysteria2 service commit 7de4af2 Author: wwqgtxx <[email protected]> Date: Wed Apr 23 12:10:37 2025 +0800 fix: shadowtls test commit 48d8efb Author: wwqgtxx <[email protected]> Date: Wed Apr 23 12:00:10 2025 +0800 fix: do NOT reset the quic-go internal state when only port is different commit e6e7aa5 Author: wwqgtxx <[email protected]> Date: Tue Apr 22 23:44:55 2025 +0800 fix: alpn apply on shadowtls commit 99aa1b0 Author: wwqgtxx <[email protected]> Date: Tue Apr 22 20:49:54 2025 +0800 feat: inbound support shadow-tls commit 52ad793 Author: wwqgtxx <[email protected]> Date: Tue Apr 22 20:09:24 2025 +0800 fix: shadowtls v1 not work commit 2fb9331 Author: wwqgtxx <[email protected]> Date: Tue Apr 22 10:37:05 2025 +0800 fix: some resources are not released in listener commit 793ce45 Author: wwqgtxx <[email protected]> Date: Mon Apr 21 22:58:08 2025 +0800 chore: update quic-go to 0.51.0 commit 39d6a0d Author: wwqgtxx <[email protected]> Date: Mon Apr 21 12:07:33 2025 +0800 chore: update utls to 1.7.0 commit d5243ad Author: wwqgtxx <[email protected]> Date: Sat Apr 19 02:04:09 2025 +0800 chore: better global-client-fingerprint handle commit 6236cb1 Author: wwqgtxx <[email protected]> Date: Sat Apr 19 01:32:55 2025 +0800 chore: cleanup trojan code commit 619c9dc Author: wwqgtxx <[email protected]> Date: Fri Apr 18 20:16:51 2025 +0800 chore: apply the default interface/mark of the dialer in the final stage commit 9c5067e Author: wwqgtxx <[email protected]> Date: Fri Apr 18 19:34:21 2025 +0800 action: disable MinGW's path conversion in test commit feee9b3 Author: wwqgtxx <[email protected]> Date: Fri Apr 18 16:59:53 2025 +0800 chore: remove unneeded tls timeout in anytls commit 63e66f4 Author: wwqgtxx <[email protected]> Date: Fri Apr 18 16:59:28 2025 +0800 chore: cleanup trojan code commit bad61f9 Author: wwqgtxx <[email protected]> Date: Fri Apr 18 11:40:37 2025 +0800 fix: avoid panic in inbound test commit 69ce4d0 Author: wwqgtxx <[email protected]> Date: Thu Apr 17 23:40:46 2025 +0800 chore: speed up inbound test commit b59f11f Author: wwqgtxx <[email protected]> Date: Thu Apr 17 21:07:35 2025 +0800 chore: add singMux inbound test for shadowsocks/trojan/vless/vmess commit 30d90d4 Author: wwqgtxx <[email protected]> Date: Thu Apr 17 21:06:55 2025 +0800 chore: update option checks to use IsZeroOptions commit 76052b5 Author: wwqgtxx <[email protected]> Date: Thu Apr 17 12:54:36 2025 +0800 fix: grpc in trojan not apply client-fingerprint commit 7d7f5c8 Author: wwqgtxx <[email protected]> Date: Thu Apr 17 10:02:48 2025 +0800 chore: add inbound test for tuic commit e79465d Author: wwqgtxx <[email protected]> Date: Thu Apr 17 09:26:12 2025 +0800 chore: add inbound test for hysteria2 commit 345d3d7 Author: wwqgtxx <[email protected]> Date: Thu Apr 17 09:01:26 2025 +0800 chore: add inbound test for anytls commit 3d806b5 Author: wwqgtxx <[email protected]> Date: Thu Apr 17 01:36:14 2025 +0800 chore: add inbound test for shadowsocks/trojan commit b5fcd1d Author: wwqgtxx <[email protected]> Date: Thu Apr 17 00:11:24 2025 +0800 fix: chacha8-ietf-poly1305 not work commit b21b8ee Author: wwqgtxx <[email protected]> Date: Wed Apr 16 22:22:56 2025 +0800 fix: panic in ssr packet commit d0d0c39 Author: wwqgtxx <[email protected]> Date: Wed Apr 16 20:44:48 2025 +0800 chore: add inbound test for vmess/vless commit a75e570 Author: wwqgtxx <[email protected]> Date: Wed Apr 16 20:38:10 2025 +0800 fix: vision conn read short buffer error commit 9e0889c Author: wwqgtxx <[email protected]> Date: Wed Apr 16 13:16:11 2025 +0800 fix: observable test commit 55cbbf7 Author: wwqgtxx <[email protected]> Date: Wed Apr 16 13:13:01 2025 +0800 fix: singledo test commit 664b134 Author: wwqgtxx <[email protected]> Date: Wed Apr 16 13:02:50 2025 +0800 fix: websocket data losing commit ba3c44a Author: wwqgtxx <[email protected]> Date: Wed Apr 16 09:39:52 2025 +0800 chore: code cleanup commit dcb20e2 Author: wwqgtxx <[email protected]> Date: Wed Apr 16 08:47:44 2025 +0800 fix: websocket server upgrade in golang1.20 commit 3d2cb99 Author: wwqgtxx <[email protected]> Date: Wed Apr 16 01:00:06 2025 +0800 fix: grpc outbound not apply ca fingerprint commit 984535f Author: wwqgtxx <[email protected]> Date: Tue Apr 15 21:59:35 2025 +0800 action: run tests on more platforms commit 8fa4e81 Author: wwqgtxx <[email protected]> Date: Sun Apr 13 03:03:28 2025 +0800 chore: remove internal crypto/tls fork in reality server commit 7551c8a Author: wwqgtxx <[email protected]> Date: Sat Apr 12 23:42:57 2025 +0800 chore: remove unneed code commit 237e2ed Author: wwqgtxx <[email protected]> Date: Sat Apr 12 22:46:26 2025 +0800 chore: tun will add firewall rule for Profile ALL on windows system stack commit fe01033 Author: wwqgtxx <[email protected]> Date: Sat Apr 12 22:27:07 2025 +0800 chore: quic sniffer should use the exact length of crypto stream when assembling commit 84cd0ef Author: wwqgtxx <[email protected]> Date: Sat Apr 12 20:27:30 2025 +0800 chore: remove internal crypto/tls fork in shadowtls commit cedb36d Author: wwqgtxx <[email protected]> Date: Sat Apr 12 11:19:03 2025 +0800 chore: using SetupContextForConn to reduce the DialContext cannot be cancelled commit 7a260f7 Author: HiMetre <[email protected]> Date: Fri Apr 11 09:20:58 2025 +0800 fix: udp dial support ip4p (MetaCubeX#1377) commit 8085c68 Author: wwqgtxx <[email protected]> Date: Fri Apr 11 00:33:07 2025 +0800 chore: decrease direct using *net.TCPConn commit dbb5b7d Author: wwqgtxx <[email protected]> Date: Thu Apr 10 23:32:26 2025 +0800 fix: SetupContextForConn should return context error to user commit bfd06eb Author: wwqgtxx <[email protected]> Date: Thu Apr 10 01:16:54 2025 +0800 chore: rebuild SetupContextForConn with context.AfterFunc commit e8af058 Author: wwqgtxx <[email protected]> Date: Thu Apr 10 00:13:14 2025 +0800 fix: websocketWithEarlyDataConn can't close underlay conn when is dialing or not dialed commit 487d7fa Author: wwqgtxx <[email protected]> Date: Wed Apr 9 17:53:36 2025 +0800 fix: panic under some stupid input config commit 4b15568 Author: wwqgtxx <[email protected]> Date: Wed Apr 9 12:33:01 2025 +0800 chore: cleanup metadata code commit cac2bf7 Author: wwqgtxx <[email protected]> Date: Wed Apr 9 11:39:00 2025 +0800 chore: cleanup netip code commit b2d2890 Author: wwqgtxx <[email protected]> Date: Wed Apr 9 10:32:13 2025 +0800 chore: cleanup resolveUDPAddr code commit 8752f80 Author: anytls <[email protected]> Date: Wed Apr 9 10:55:53 2025 +0900 fix: anytls stream read error (MetaCubeX#1970) Co-authored-by: anytls <anytls> commit a6c0c02 Author: wwqgtxx <[email protected]> Date: Tue Apr 8 23:42:21 2025 +0800 chore: ignore interfaces not in IfOperStatusUp when fetch system dns server on windows commit 2acb0b7 Author: wwqgtxx <[email protected]> Date: Tue Apr 8 19:20:29 2025 +0800 fix: tun IncludeInterface/ExcludeInterface priority commit 2a40eba Author: wwqgtxx <[email protected]> Date: Tue Apr 8 19:07:39 2025 +0800 feat: tun add `exclude-src-port`,`exclude-src-port-range`,`exclude-dst-port` and `exclude-dst-port-range` on linux commit a22efd5 Author: okhowang <[email protected]> Date: Tue Apr 8 12:10:30 2025 +0800 feat: add exclude port and exclude port range options (MetaCubeX#1951) Fixes MetaCubeX#1769 commit 9e8f4ad Author: wwqgtxx <[email protected]> Date: Sun Apr 6 10:43:21 2025 +0800 chore: better addr parsing commit 09c7ee0 Author: wwqgtxx <[email protected]> Date: Sun Apr 6 10:12:57 2025 +0800 fix: grpc server panic commit 2a08c44 Author: wwqgtxx <[email protected]> Date: Sat Apr 5 10:48:07 2025 +0800 action: fix run build on pull_request commit 190047c Author: wwqgtxx <[email protected]> Date: Fri Apr 4 21:05:54 2025 +0800 fix: grpc transport not apply dial timeout commit 24a9ff6 Author: wwqgtxx <[email protected]> Date: Fri Apr 4 13:33:00 2025 +0800 fix: disallow dialFunc be called after grpc transport has be closed commit efa2243 Author: wwqgtxx <[email protected]> Date: Fri Apr 4 11:54:19 2025 +0800 fix: shut it down more aggressively in grpc transport closing commit b0bd4f4 Author: wwqgtxx <[email protected]> Date: Fri Apr 4 11:12:08 2025 +0800 fix: resources not released when hysteria2 verification failed commit eaaccff Author: wwqgtxx <[email protected]> Date: Fri Apr 4 10:55:16 2025 +0800 fix: race in Single.Do commit e81f3a9 Author: wwqgtxx <[email protected]> Date: Fri Apr 4 09:08:52 2025 +0800 fix: correctly implement references to proxies commit 323973f Author: wwqgtxx <[email protected]> Date: Fri Apr 4 00:22:52 2025 +0800 fix: converter judgment conditions commit ed7533c Author: 5aaee9 <[email protected]> Date: Thu Apr 3 08:52:19 2025 -0700 fix: tproxy high cpu usage (MetaCubeX#1957) commit 7de24e2 Author: wwqgtxx <[email protected]> Date: Thu Apr 3 23:41:24 2025 +0800 fix: StreamGunWithConn not synchronously close the incoming net.Conn commit 622d99d Author: wwqgtxx <[email protected]> Date: Thu Apr 3 22:42:32 2025 +0800 chore: rebuild outdated proxy auto close mechanism commit 7f1225b Author: wwqgtxx <[email protected]> Date: Thu Apr 3 22:41:05 2025 +0800 fix: grpc transport can't be closed commit 23ffe45 Author: wwqgtxx <[email protected]> Date: Thu Apr 3 19:47:49 2025 +0800 chore: using http/httptrace to get local/remoteAddr for grpc client commit 7b37fcf Author: wwqgtxx <[email protected]> Date: Wed Apr 2 23:47:34 2025 +0800 fix: auto_redirect should only hijack DNS requests from local addresses commit daa592c Author: wwqgtxx <[email protected]> Date: Wed Apr 2 21:13:46 2025 +0800 fix: converter panic commit 577f64a Author: wwqgtxx <[email protected]> Date: Wed Apr 2 14:39:07 2025 +0800 fix: X25519MLKEM768 does not work properly with reality commit 025ff19 Author: wwqgtxx <[email protected]> Date: Fri Mar 28 10:54:11 2025 +0800 fix: wrong conditional judgment in removeExtraHTTPHostPort MetaCubeX#1939 commit f615346 Author: anytls <[email protected]> Date: Thu Mar 27 20:25:31 2025 +0800 chore: anytls protocol version 2 (MetaCubeX#1936) commit 7b38261 Author: wwqgtxx <[email protected]> Date: Tue Mar 25 01:19:39 2025 +0800 chore: update gvisor commit 0f32c05 Author: enfein <[email protected]> Date: Thu Mar 20 05:58:04 2025 +0000 feat: support UDP over TCP in mieru (MetaCubeX#1926) commit 4f8b70c Author: 5aaee9 <[email protected]> Date: Wed Mar 19 12:20:48 2025 +0800 fix: buffer in tproxy not recycle (MetaCubeX#1923) commit dcef787 Author: wwqgtxx <[email protected]> Date: Tue Mar 18 09:09:54 2025 +0800 chore: update utls commit 7c444a9 Author: wwqgtxx <[email protected]> Date: Mon Mar 17 23:51:21 2025 +0800 fix: correctly handle ipv6 zone commit e3d4ec2 Author: wwqgtxx <[email protected]> Date: Mon Mar 17 14:00:51 2025 +0800 fix: race at interfaceName setting commit 14217e7 Author: xishang0128 <[email protected]> Date: Mon Mar 17 13:21:23 2025 +0800 chore: update service capabilities to include CAP_SYS_TIME and CAP_DAC_OVERRIDE commit 68abb13 Author: wwqgtxx <[email protected]> Date: Mon Mar 17 10:42:13 2025 +0800 chore: support longest-prefix matches in local interface finding commit dee5898 Author: Cesaryuan <[email protected]> Date: Sat Mar 15 13:27:29 2025 +0800 fix: memory leak due to unclosed session (MetaCubeX#1908) commit 1e22f4d Author: wwqgtxx <[email protected]> Date: Fri Mar 14 12:07:23 2025 +0800 chore: reduce data copying in quic sniffer and better handle data fragmentation and overlap commit a7a796b Author: wwqgtxx <[email protected]> Date: Thu Mar 13 16:27:29 2025 +0800 chore: cleanup quic sniff's code commit ff89bf0 Author: Cesaryuan <[email protected]> Date: Thu Mar 13 13:28:40 2025 +0800 feat: add gost-plugin in which only ws and mws are currently supported. (MetaCubeX#1896) commit 801f3c3 Author: 5aaee9 <[email protected]> Date: Thu Mar 13 13:19:36 2025 +0800 feat: support sniff quic fragment data (MetaCubeX#1899) commit 7ff046a Author: wwqgtxx <[email protected]> Date: Thu Mar 13 08:52:27 2025 +0800 chore: modify UDPSniff's function signature to prepare for its ability to handle multiple packets. commit 0ed159e Author: wwqgtxx <[email protected]> Date: Wed Mar 12 13:33:52 2025 +0800 chore: code cleanup commit 070eb31 Author: wwqgtxx <[email protected]> Date: Wed Mar 12 11:42:57 2025 +0800 chore: speedup system stack in tun commit f318b80 Author: wwqgtxx <[email protected]> Date: Tue Mar 11 22:50:55 2025 +0800 chore: better cache implement for group's getProxies commit c0de3c0 Author: wwqgtxx <[email protected]> Date: Mon Mar 10 11:10:39 2025 +0800 fix: some default value in dialer not restore in tun when config reload commit 4bd3ae5 Author: wwqgtxx <[email protected]> Date: Mon Mar 10 10:45:07 2025 +0800 chore: dialer will consider the routing of the local interface when auto-detect-interface in tun is enabled for MetaCubeX#1881 MetaCubeX#1819 commit 00e6466 Author: Skyxim <[email protected]> Date: Mon Mar 10 09:13:38 2025 +0800 chore: update checksum generation step commit c94b442 Author: Skyxim <[email protected]> Date: Mon Mar 10 09:02:08 2025 +0800 chore: add checksum generation for production artifacts
验证步骤
操作系统
MacOS
系统版本
all
Mihomo 版本
1.18.0到1.19.5均手动测试过,均存在这个问题,可完整复现:
配置文件
描述
https://wiki.metacubex.one/config/proxy-groups/#url 文档中 url 为通用字段。
但是当proxy-groups的类型为select时,url, expected-status等延迟配置不生效。
其他类型均可以生效。
重现方式
如下配置(如:fallback类型)
接口返回:
然而,如果将type fallback 改成select, 则不返回testUrl.
接口返回:
影响
无法实现独立的延迟测试。
场景:
为特定的proxy-group指定特定的延迟URL来得到更准确的延迟信息。 如仅特定子网相关的proxy-group 这种情况下testUrl为特定子网的地址会更准确
The text was updated successfully, but these errors were encountered: