背景
IDEA 中搜索配置问题,有两个大坑,第一个是之前有提到过的,搜索结果如果超过100的话100外的结果不会显示(可以改)。第二个坑就是显示的不完整,以搜索properties配置为例,如
if.longer.than.200.will.not.display.full=/user/foo/{userId}/pets/{petId}/property/{propertyId}/account/{accountId}/bills/{billId}/foo/bar/example/chunk/retain/filter_out/fell_free/disconnect/history/{historyId}
配置包括key在内,如果字符数 >200 则会发生截断现象。上述配置210个chars,可以看到预览的时候截断到 /example。
截断的位置也比较奇怪,不是substring(0,200)的逻辑,这个预览到了/example就结束了,很容易让人误以为endpoint到了/example就结束了
if.longer.than.200.will.not.display.full=/user/foo/{userId}/pets/{petId}/property/{propertyId}/account/{accountId}/bills/{billId}/foo/bar/example/chunk/retain/filter_out/fell_free/disconnect/history/{
上述刚好是200字符,可以完整展示,多个字符就不行了,少个字符可以完整展示。说明200就是边界
解决办法
暂时还未找到 IDEA 里哪里可以设置。如有知道的请留言。