MCPcopy Create free account
hub / github.com/OreosLab/bili / push2Target

Method push2Target

src/main/java/top/misec/push/AbstractPush.java:89–100  ·  view source on GitHub ↗
(String url, String pushContent)

Source from the content-addressed store, hash-verified

87 }
88
89 private PushResult push2Target(String url, String pushContent) {
90 try {
91 JsonObject jsonObject = retryer.call(() -> post(url, pushContent));
92 log.info("推送结果:{}", jsonObject.toString());
93 return PushResult.success();
94 } catch (RetryException e) {
95 log.error("重试最终失败:{}", this.getClass().getSimpleName(), e);
96 } catch (ExecutionException e) {
97 log.error("重试中断:{}", this.getClass().getSimpleName(), e);
98 }
99 return PushResult.failed();
100 }
101
102 private JsonObject post(String url, String content) {
103 return HttpUtils.doPost(url, content, null, requestConfig);

Callers 1

doPushMethod · 0.95

Calls 4

postMethod · 0.95
successMethod · 0.95
failedMethod · 0.95
toStringMethod · 0.80

Tested by

no test coverage detected