{"record":{"id":"e18fa5af9ccdac75","repo":"binarywang/WxJava","slug":"error-e18fa5","errorCode":null,"errorMessage":"微信服务端异常，超出重试次数","messagePattern":"微信服务端异常，超出重试次数","errorType":"exception","errorClass":"WxRuntimeException","httpStatus":null,"severity":"error","filePath":"weixin-java-cp/src/main/java/me/chanjar/weixin/cp/corpgroup/service/impl/BaseWxCpCgServiceImpl.java","lineNumber":153,"sourceCode":"   * @param <E>                    the type parameter\n   * @param executor               the executor\n   * @param uri                    the uri\n   * @param data                   the data\n   * @param withoutCorpAccessToken the without Corp access token\n   * @param req                    获取token请求参数\n   * @return the t\n   * @throws WxErrorException the wx error exception\n   */\n  public <T, E> T execute(RequestExecutor<T, E> executor, String uri, E data, boolean withoutCorpAccessToken, WxCpCorpGroupCorpGetTokenReq req) throws WxErrorException {\n    int retryTimes = 0;\n    do {\n      try {\n        return this.executeInternal(executor, uri, data, withoutCorpAccessToken, req);\n      } catch (WxErrorException e) {\n        if (retryTimes + 1 > this.maxRetryTimes) {\n          log.warn(\"重试达到最大次数【{}】\", this.maxRetryTimes);\n          //最后一次重试失败后，直接抛出异常，不再等待\n          throw new WxRuntimeException(\"微信服务端异常，超出重试次数\");\n        }\n\n        WxError error = e.getError();\n        /*\n         * -1 系统繁忙, 1000ms后重试\n         */\n        if (error.getErrorCode() == -1) {\n          int sleepMillis = this.retrySleepMillis * (1 << retryTimes);\n          try {\n            log.debug(\"微信系统繁忙，{} ms 后重试(第{}次)\", sleepMillis, retryTimes + 1);\n            Thread.sleep(sleepMillis);\n          } catch (InterruptedException e1) {\n            Thread.currentThread().interrupt();\n          }\n        } else {\n          throw e;\n        }\n      }","sourceCodeStart":135,"sourceCodeEnd":171,"githubUrl":"https://github.com/binarywang/WxJava/blob/1c43293a3c2c9d7e91304b6d037fb017f680d0c6/weixin-java-cp/src/main/java/me/chanjar/weixin/cp/corpgroup/service/impl/BaseWxCpCgServiceImpl.java#L135-L171","documentation":"Error \"微信服务端异常，超出重试次数\" thrown in binarywang/WxJava.","triggerScenarios":"Thrown at weixin-java-cp/src/main/java/me/chanjar/weixin/cp/corpgroup/service/impl/BaseWxCpCgServiceImpl.java:153 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["检查网络稳定性，适当增大重试次数或超时时间配置。","确认请求参数正确，排除微信服务端持续报错（如 access_token 失效）导致重试无效。"],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"1c43293a3c2c9d7e91304b6d037fb017f680d0c6","analyzedAt":"2026-08-14T02:29:11.060Z","schemaVersion":2},"datasetVersion":"2026-08-14T05:17:29.042Z"}