目 录CONTENT

文章目录

[Java]程序自动检查页面是否被收录,并推送至百度

沙漠渔
2022-05-25 / 0 评论 / 2 点赞 / 72 阅读 / 25,906 字 / 正在检测是否收录...
温馨提示:
本文最后更新于 2022-05-25,若内容或图片失效,请留言反馈。部分素材来自网络,若不小心影响到您的利益,请联系我们删除。

在前面已经说过怎么查询页面是否被百度收录了,这里就把整个流程说一下,下面涉及不明白的部分可以参考
[Java]程序自己检查当前页面是否被百度收录的方法 http://www.sammery.com/archives/48.html

首先需要获取所有需要提交的页面地址,或者直接提交当前页面的地址,这里我通过sitemap获取到站点内的url,对所有url进行遍历,筛选出未被百度收录的页面,然后一次性提交,非常方便,主要是需要考虑百度的校验,访问速度过快会被百度跳转至人工校验环节。

代码实现

package com.sammery.ops.tester.edge;

import org.apache.http.HttpEntity;
import org.apache.http.HttpResponse;
import org.apache.http.HttpStatus;
import org.apache.http.client.config.CookieSpecs;
import org.apache.http.client.config.RequestConfig;
import org.apache.http.client.methods.CloseableHttpResponse;
import org.apache.http.client.methods.HttpGet;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.entity.StringEntity;
import org.apache.http.impl.client.CloseableHttpClient;
import org.apache.http.impl.client.HttpClientBuilder;
import org.apache.http.impl.client.HttpClients;
import org.apache.http.util.EntityUtils;
import org.jsoup.Jsoup;
import org.jsoup.nodes.Document;

import java.io.IOException;
import java.util.stream.Collectors;

public class CheckBaiduUpUtil {
    private static String URL = "http://data.zz.baidu.com/urls";

    public static void main(String[] args) throws IOException {
        Document document = obtainDocument("http://www.sammery.com/sitemap.html");

        pushPost(document.getElementsByTag("a").stream().filter(x -> {
            try {
                Thread.sleep(8000);
                return !CheckBaiduStatusUtil.checkBaiduStatus(x.attr("href"));
            } catch (Exception e) {
                e.printStackTrace();
            }
            return false;
        }).map(x -> x.attr("href")).collect(Collectors.joining("\n")));


    }

    public static Document obtainDocument(String url) throws IOException {
        try (CloseableHttpClient httpClient = HttpClients.createDefault()) {
            HttpGet request = new HttpGet();
            RequestConfig defaultConfig = RequestConfig.custom().setCookieSpec(CookieSpecs.STANDARD).build();
            request.setConfig(defaultConfig);
            try (CloseableHttpResponse response = httpClient.execute(request)) {
                if (response.getStatusLine().getStatusCode() == HttpStatus.SC_OK) {
                    return Jsoup.parse(EntityUtils.toString(response.getEntity(), "utf-8"));
                } else {
                    throw new IOException();
                }
            }
        }
    }

    public static String pushPost(String postUrl) {
        //推送链接的域名,即 你的网站的域名
        String domain = "https://www.sammery.com";
        //百度主动推送链接准入密钥,即获取到的token
        String bdToken = "";
        String host = "data.zz.baidu.com";
        URL += "?site=" + domain + "&token=" + bdToken;
        String result = "";
        HttpClientBuilder httpClientBuilder = HttpClientBuilder.create();
        //HttpClient
        CloseableHttpClient client = httpClientBuilder.build();
        HttpPost post = new HttpPost(URL);
        //发送请求参数
        try {
            StringEntity s = new StringEntity(postUrl, "utf-8");
            s.setContentType("application/json");
            post.setEntity(s);
            post.setHeader("Host", host);
            post.setHeader("User-Agent", "curl/7.12.1");
            post.setHeader("Content-Type", "text/plain");
            HttpResponse res = client.execute(post);
            HttpEntity entity = res.getEntity();
            result = EntityUtils.toString(entity, "utf-8");

        } catch (Exception e) {
            result = null;
            e.printStackTrace();
        }
        return result;
    }
}

执行效果

00:29:20.839 [main] DEBUG org.apache.http.client.protocol.RequestAddCookies - CookieSpec selected: default
00:29:20.839 [main] DEBUG org.apache.http.client.protocol.RequestAuthCache - Auth cache not set in the context
00:29:20.840 [main] DEBUG org.apache.http.impl.conn.PoolingHttpClientConnectionManager - Connection request: [route: {}->http://data.zz.baidu.com:80][total kept alive: 0; route allocated: 0 of 2; total allocated: 0 of 20]
00:29:20.840 [main] DEBUG org.apache.http.impl.conn.PoolingHttpClientConnectionManager - Connection leased: [id: 139][route: {}->http://data.zz.baidu.com:80][total kept alive: 0; route allocated: 1 of 2; total allocated: 1 of 20]
00:29:20.840 [main] DEBUG org.apache.http.impl.execchain.MainClientExec - Opening connection {}->http://data.zz.baidu.com:80
00:29:20.879 [main] DEBUG org.apache.http.impl.conn.DefaultHttpClientConnectionOperator - Connecting to data.zz.baidu.com/112.80.255.152:80
00:29:20.917 [main] DEBUG org.apache.http.impl.conn.DefaultHttpClientConnectionOperator - Connection established 192.168.43.77:62296<->112.80.255.152:80
00:29:20.917 [main] DEBUG org.apache.http.impl.execchain.MainClientExec - Executing request POST /urls?site=https://www.sammery.com&token=U39GAup7u7o1Uox4 HTTP/1.1
00:29:20.917 [main] DEBUG org.apache.http.impl.execchain.MainClientExec - Target auth state: UNCHALLENGED
00:29:20.917 [main] DEBUG org.apache.http.impl.execchain.MainClientExec - Proxy auth state: UNCHALLENGED
00:29:20.917 [main] DEBUG org.apache.http.headers - http-outgoing-139 >> POST /urls?site=https://www.sammery.com&token=U39GAup7u7o1Uox4 HTTP/1.1
00:29:20.917 [main] DEBUG org.apache.http.headers - http-outgoing-139 >> Host: data.zz.baidu.com
00:29:20.917 [main] DEBUG org.apache.http.headers - http-outgoing-139 >> User-Agent: curl/7.12.1
00:29:20.917 [main] DEBUG org.apache.http.headers - http-outgoing-139 >> Content-Type: text/plain
00:29:20.917 [main] DEBUG org.apache.http.headers - http-outgoing-139 >> Content-Length: 5530
00:29:20.917 [main] DEBUG org.apache.http.headers - http-outgoing-139 >> Connection: Keep-Alive
00:29:20.917 [main] DEBUG org.apache.http.headers - http-outgoing-139 >> Accept-Encoding: gzip,deflate
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "POST /urls?site=https://www.sammery.com&token=U39GAup7u7o1Uox4 HTTP/1.1[\r][\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "Host: data.zz.baidu.com[\r][\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "User-Agent: curl/7.12.1[\r][\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "Content-Type: text/plain[\r][\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "Content-Length: 5530[\r][\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "Connection: Keep-Alive[\r][\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "Accept-Encoding: gzip,deflate[\r][\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "[\r][\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/sitemap.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/60.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/59.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/58.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/57.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/56.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/55.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/11.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/54.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/52.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/51.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/50.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/49.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/21.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/48.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/47.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/46.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/45.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/44.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/43.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/42.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/41.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/40.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/39.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/38.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/37.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/36.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/35.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/34.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/33.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/32.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/31.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/30.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/29.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/28.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/27.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/26.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/25.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/24.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/23.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/22.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/20.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/13.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/9.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/10.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/15.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/14.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/12.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/archives/5.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/categories/software.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/categories/frp.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/categories/gupiao.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/categories/computer.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/categories/shenghuo.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/categories/springboot.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/categories/database.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/halo.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe6][0xa0][0xa1][0xe5][0x8f][0x8b][0xe4][0xbc][0x9a].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0x88][0x9b][0xe6][0x96][0xb0].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0x93][0x88][0xe5][0xb7][0xa5][0xe5][0xa4][0xa7].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe9][0xb8][0xbf][0xe8][0x92][0x99].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe7][0x8e][0x8b][0xe6][0x88][0x90][0xe5][0xbd][0x95].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe6][0xa0][0x87][0xe9][0xa2][0x98].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe4][0xb8][0xbb][0xe9][0xa2][0x98].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0x8c][0x97][0xe4][0xba][0xac].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe7][0x96][0xab][0xe6][0x83][0x85].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0x9f][0x9f][0xe5][0x90][0x8d].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe6][0xb2][0x99][0xe6][0xbc][0xa0][0xe6][0xb8][0x94][0xe6][0xba][0x8f].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe6][0x96][0xb9][0xe6][0xb3][0x95][0xe5][0xa3][0xb0][0xe6][0x98][0x8e].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/jpa.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe8][0xa1][0xa8][0xe6][0x83][0x85][0xe5][0x8c][0x85].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/emoji.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/javaagent.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0xa7][0x93][0xe5][0x90][0x8d][0xe6][0xb5][0x8b][0xe8][0xaf][0x95].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0xa7][0x93][0xe5][0x90][0x8d][0xe6][0x89][0x93][0xe5][0x88][0x86].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe8][0xb5][0xb7][0xe5][0x90][0x8d].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe7][0x99][0xbe][0xe5][0xba][0xa6].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe6][0x94][0xb6][0xe5][0xbd][0x95].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/seo.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/groupby.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/distinct.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0x8e][0xbb][0xe9][0x87][0x8d].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/jdbc.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/validationquery.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0x85][0x84][0xe5][0xbc][0x9f][0xe5][0x85][0x83][0xe7][0xb4][0xa0].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe7][0x82][0xb9][0xe5][0x87][0xbb][0xe4][0xba][0x8b][0xe4][0xbb][0xb6].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/event.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/9600.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe4][0xbc][0xa0][0xe8][0xbe][0x93][0xe5][0xbb][0xb6][0xe6][0x97][0xb6].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe6][0xb3][0xa2][0xe7][0x89][0xb9][0xe7][0x8e][0x87].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe4][0xb8][0xb2][0xe5][0x8f][0xa3].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe7][0xab][0x99][0xe7][0x82][0xb9][0xe7][0xbb][0x9f][0xe8][0xae][0xa1].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe7][0xab][0x99][0xe9][0x95][0xbf][0xe5][0xb7][0xa5][0xe5][0x85][0xb7].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/cnzz.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe7][0x94][0x9f][0xe5][0x91][0xbd][0xe5][0x91][0xa8][0xe6][0x9c][0x9f].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/refs.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/vue.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/replaceall.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/replace.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/javascript.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe8][0xbd][0xaf][0xe4][0xbb][0xb6].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/frp.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0x86][0x85][0xe7][0xbd][0x91][0xe5][0xa4][0x96][0xe5][0x85][0xa5].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0x86][0x85][0xe7][0xbd][0x91][0xe7][0xa9][0xbf][0xe9][0x80][0x8f].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0xad][0xa6][0xe4][0xb9][0xa0].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe8][0xa7][0xa3][0xe9][0xa2][0x98].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/leetcode.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe4][0xba][0x91][0xe8][0xae][0xa1][0xe7][0xae][0x97].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe4][0xb8][0xad][0xe5][0x9b][0xbd][0xe5][0x8c][0xbb][0xe8][0x8d][0xaf].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe7][0xa5][0x9e][0xe6][0x80][0x9d][0xe7][0x94][0xb5][0xe5][0xad][0x90].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe8][0x82][0xa1][0xe7][0xa5][0xa8].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/java.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe6][0x8a][0xa5][0xe9][0x94][0x99].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe6][0x95][0xb0][0xe6][0x8d][0xae][0xe5][0x9d][0x97].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0x85][0xb3][0xe9][0x94][0xae][0xe8][0xaf][0x8d].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe9][0xa3][0x8e][0xe7][0xad][0x9d].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe6][0xb8][0x85][0xe6][0x98][0x8e][0xe8][0x8a][0x82].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe6][0xb3][0xa8][0xe8][0xa7][0xa3].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/spring.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/clang-format.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe6][0xa0][0xbc][0xe5][0xbc][0x8f][0xe5][0x8c][0x96].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0x8f][0x8d][0xe5][0x90][0x91][0xe4][0xbb][0xa3][0xe7][0x90][0x86].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/nginx.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe7][0xb4][0xa2][0xe5][0xbc][0x95].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/linux.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/vim.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe6][0x95][0xb0][0xe6][0x8d][0xae][0xe5][0xba][0x93].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe4][0xbb][0x93][0xe5][0xba][0x93][0xe7][0xae][0xa1][0xe7][0x90][0x86].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/git.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/[0xe5][0x8e][0x8b][0xe7][0xbc][0xa9].html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/winrar.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/mysql.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/test.html[\n]"
00:29:20.918 [main] DEBUG org.apache.http.wire - http-outgoing-139 >> "http://www.sammery.com/tags/markdown.html"
00:29:21.102 [main] DEBUG org.apache.http.wire - http-outgoing-139 << "HTTP/1.1 200 OK[\r][\n]"
00:29:21.102 [main] DEBUG org.apache.http.wire - http-outgoing-139 << "Content-Length: 29[\r][\n]"
00:29:21.102 [main] DEBUG org.apache.http.wire - http-outgoing-139 << "Content-Type: application/json[\r][\n]"
00:29:21.102 [main] DEBUG org.apache.http.wire - http-outgoing-139 << "Date: Tue, 24 May 2022 16:29:21 GMT[\r][\n]"
00:29:21.102 [main] DEBUG org.apache.http.wire - http-outgoing-139 << "[\r][\n]"
00:29:21.102 [main] DEBUG org.apache.http.wire - http-outgoing-139 << "{"remain":2865,"success":134}"
00:29:21.102 [main] DEBUG org.apache.http.headers - http-outgoing-139 << HTTP/1.1 200 OK
00:29:21.102 [main] DEBUG org.apache.http.headers - http-outgoing-139 << Content-Length: 29
00:29:21.102 [main] DEBUG org.apache.http.headers - http-outgoing-139 << Content-Type: application/json
00:29:21.102 [main] DEBUG org.apache.http.headers - http-outgoing-139 << Date: Tue, 24 May 2022 16:29:21 GMT
00:29:21.103 [main] DEBUG org.apache.http.impl.execchain.MainClientExec - Connection can be kept alive indefinitely
00:29:21.103 [main] DEBUG org.apache.http.impl.conn.PoolingHttpClientConnectionManager - Connection [id: 139][route: {}->http://data.zz.baidu.com:80] can be kept alive indefinitely
00:29:21.103 [main] DEBUG org.apache.http.impl.conn.DefaultManagedHttpClientConnection - http-outgoing-139: set socket timeout to 0
00:29:21.103 [main] DEBUG org.apache.http.impl.conn.PoolingHttpClientConnectionManager - Connection released: [id: 139][route: {}->http://data.zz.baidu.com:80][total kept alive: 1; route allocated: 1 of 2; total allocated: 1 of 20]
{"remain":2865,"success":134}

最终显示的{"remain":2865,"success":134}表明本次成功提交134条记录,当天还有2865条记录可以提交。

2
广告 广告

评论区