127.0.0.1:9200
URL: http://127.0.0.1:9200/likecs_art_db/_search
REQUEST:
Array
(
    [query] => Array
        (
            [match] => Array
                (
                    [text] => Array
                        (
                            [query] => kubesphere source code解析
                        )

                )

        )

    [highlight] => Array
        (
            [fields] => Array
                (
                    [text] => stdClass Object
                        (
                        )

                )

            [pre_tags] => #em#
            [post_tags] => #/em#
        )

    [size] => 8
    [from] => 0
)
RESPONSE:
string(7320) "{"took":13,"timed_out":false,"_shards":{"total":1,"successful":1,"skipped":0,"failed":0},"hits":{"total":{"value":10000,"relation":"gte"},"max_score":40.811676,"hits":[{"_index":"likecs_art_db","_type":"_doc","_id":"247601","_score":40.811676,"_source":{"id":"247601","text":"kubesphere source code\u89e3\u6790","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"good2study","tagsname":null,"tagsid":"","catesname":null,"catesid":"","createtime":"1630172404"},"highlight":{"text":["#em#kubesphere#/em# #em#source#/em# #em#code#/em##em#解#/em##em#析#/em#"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"203404296","_score":18.900578,"_source":{"id":"203404296","text":"VS code \u5b89\u88c5Source Code Pro\u5b57\u4f53","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"","tagsname":null,"tagsid":"","catesname":null,"catesid":"","createtime":"1631232318"},"highlight":{"text":["VS #em#code#/em# 安装#em#Source#/em# #em#Code#/em# Pro字体"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"21147","_score":18.573006,"_source":{"id":"21147","text":"Tree - AdaBoost with sklearn source code","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"gogoSandy","tagsname":"Machine Learning|Tree","tagsid":"[\"1347\",\"7081\"]","catesname":"","catesid":"[]","createtime":"1528639996"},"highlight":{"text":["Tree - AdaBoost with sklearn #em#source#/em# #em#code#/em#"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"791523","_score":18.573006,"_source":{"id":"791523","text":"Implementing a Queue - Source Code C++","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"nickchan","tagsname":"","tagsid":"","catesname":null,"catesid":"","createtime":"1636966348"},"highlight":{"text":["Implementing a Queue - #em#Source#/em# #em#Code#/em# C++"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"203701","_score":17.830893,"_source":{"id":"203701","text":"Tree - Decision Tree with sklearn source code","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"gogoSandy","tagsname":null,"tagsid":"","catesname":"","catesid":"","createtime":"1628871635"},"highlight":{"text":["Tree - Decision Tree with sklearn #em#source#/em# #em#code#/em#"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"203264328","_score":17.816898,"_source":{"id":"203264328","text":"Win10 VS Code \u4fee\u6539\u5b57\u4f53\u4e3aSource Code Pro","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"","tagsname":null,"tagsid":"","catesname":null,"catesid":"","createtime":"1631801776"},"highlight":{"text":["Win10 VS #em#Code#/em# 修改字体为#em#Source#/em# #em#Code#/em# Pro"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"203434359","_score":17.816898,"_source":{"id":"203434359","text":"Visual Studio Code\uff08VS Code\uff09\u4e0eGit Source Control\u96c6\u6210","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"","tagsname":null,"tagsid":"","catesname":null,"catesid":"","createtime":"1633728010"},"highlight":{"text":["Visual Studio #em#Code#/em#(VS #em#Code#/em#)与Git #em#Source#/em# Control集成"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"91264","_score":17.412235,"_source":{"id":"91264","text":"SuperSocket Code\u89e3\u6790","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"lovexinyi","tagsname":"","tagsid":"[]","catesname":"","catesid":"[]","createtime":"1580139461"},"highlight":{"text":["SuperSocket #em#Code#/em##em#解#/em##em#析#/em#"]}}]}}"
127.0.0.1:9200
URL: http://127.0.0.1:9200/likecs_art_db/_search
REQUEST:
Array
(
    [query] => Array
        (
            [match] => Array
                (
                    [text] => Array
                        (
                            [query] => kubesphere source code解析
                        )

                )

        )

    [highlight] => Array
        (
            [fields] => Array
                (
                    [text] => stdClass Object
                        (
                        )

                )

            [pre_tags] => #em#
            [post_tags] => #/em#
        )

    [size] => 8
    [from] => 8
)
RESPONSE:
string(7387) "{"took":12,"timed_out":false,"_shards":{"total":1,"successful":1,"skipped":0,"failed":0},"hits":{"total":{"value":10000,"relation":"gte"},"max_score":40.811676,"hits":[{"_index":"likecs_art_db","_type":"_doc","_id":"203404291","_score":17.321972,"_source":{"id":"203404291","text":"\u7f16\u7a0b\u5e38\u7528\u5b57\u4f53Consolas\u3001Fira Code\u3001Source Code Pro","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"","tagsname":null,"tagsid":"","catesname":null,"catesid":"","createtime":"1633291097"},"highlight":{"text":["编程常用字体Consolas、Fira #em#Code#/em#、#em#Source#/em# #em#Code#/em# Pro"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"247582","_score":16.684265,"_source":{"id":"247582","text":"KubeSphere \u6838\u5fc3\u67b6\u6784\u6d45\u6790","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"kubesphere","tagsname":"","tagsid":"","catesname":"","catesid":"","createtime":"1630172320"},"highlight":{"text":["#em#KubeSphere#/em# 核心架构浅#em#析#/em#"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"901305","_score":15.962858,"_source":{"id":"901305","text":"Code 128 \u89c4\u5219\u89e3\u6790","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"pengzhen","tagsname":"","tagsid":"","catesname":null,"catesid":"","createtime":"1638436898"},"highlight":{"text":["#em#Code#/em# 128 规则#em#解#/em##em#析#/em#"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"214267","_score":15.922291,"_source":{"id":"214267","text":"Smart Client Case Study Source Code Download from MSDN China","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"asyuras","tagsname":"","tagsid":"","catesname":null,"catesid":"","createtime":"1629025662"},"highlight":{"text":["Smart Client Case Study #em#Source#/em# #em#Code#/em# Download from MSDN China"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"537231","_score":15.922291,"_source":{"id":"537231","text":"Smart Client Case Study Source Code Download from MSDN China","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"asyuras","tagsname":"","tagsid":"","catesname":null,"catesid":"","createtime":"1634655060"},"highlight":{"text":["Smart Client Case Study #em#Source#/em# #em#Code#/em# Download from MSDN China"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"969889","_score":15.922291,"_source":{"id":"969889","text":"\u7f16\u7a0b\u7b49\u5bbd\u5b57\u4f53Source Code Pro(\u8f6c)","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"gisext","tagsname":"","tagsid":"","catesname":null,"catesid":"","createtime":"1639833768"},"highlight":{"text":["编程等宽字体#em#Source#/em# #em#Code#/em# Pro(转)"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"999554","_score":15.922291,"_source":{"id":"999554","text":"Smart Client Case Study Source Code Download from MSDN China","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"bobli","tagsname":"","tagsid":"","catesname":null,"catesid":"","createtime":"1640492377"},"highlight":{"text":["Smart Client Case Study #em#Source#/em# #em#Code#/em# Download from MSDN China"]}},{"_index":"likecs_art_db","_type":"_doc","_id":"1028899","_score":15.922291,"_source":{"id":"1028899","text":"Source Code Structure - Python \u6e90\u7801\u76ee\u5f55\u7ed3\u6784","intro":"\u76ee\u5f55\n\nECharts\n\u5f02\u6b65\u52a0\u8f7d\n\n\n\nECharts\r\n\u6570\u636e\u53ef\u89c6\u5316\u5728\u8fc7\u53bb\u51e0\u5e74\u4e2d\u53d6\u5f97\u4e86\u5de8\u5927\u8fdb\u5c55\u3002\u5f00\u53d1\u4eba\u5458\u5bf9\u53ef\u89c6\u5316\u4ea7\u54c1\u7684\u671f\u671b\u4e0d\u518d\u662f\u7b80\u5355\u7684\u56fe\u8868\u521b\u5efa\u5de5\u5177\uff0c\u800c\u662f\u5728\u4ea4\u4e92\u3001\u6027\u80fd\u3001\u6570\u636e\u5904\u7406\u7b49\u65b9\u9762\u6709\u66f4\u9ad8\u7684\u8981\u6c42\u3002\r\nchart.setOption({\r\n    color: [\r\n        ","username":"zzyzz","tagsname":null,"tagsid":"","catesname":"","catesid":"","createtime":"1641560340"},"highlight":{"text":["#em#Source#/em# #em#Code#/em# Structure - Python 源码目录结构"]}}]}}"
127.0.0.1:9200
URL: http://192.168.101.128/searchcore/index.php/cihere_cn_db/_search
REQUEST:
Array
(
    [query] => Array
        (
            [match] => Array
                (
                    [title] => Array
                        (
                            [query] => kubesphere source code解析
                        )

                )

        )

    [highlight] => Array
        (
            [fields] => Array
                (
                    [title] => stdClass Object
                        (
                        )

                )

            [pre_tags] => #em#
            [post_tags] => #/em#
        )

    [from] => 0
)
RESPONSE:
bool(false)
127.0.0.1:9200
URL: http://127.0.0.1:9200/likecs_down_db/_search
REQUEST:
Array
(
    [query] => Array
        (
            [bool] => Array
                (
                    [must] => Array
                        (
                            [0] => Array
                                (
                                    [match] => Array
                                        (
                                            [title] => Array
                                                (
                                                    [query] => kubesphere source code解析
                                                )

                                        )

                                )

                        )

                    [must_not] => Array
                        (
                            [0] => Array
                                (
                                    [term] => Array
                                        (
                                            [cate1] => 电子书籍
                                        )

                                )

                        )

                )

        )

    [highlight] => Array
        (
            [fields] => Array
                (
                    [title] => stdClass Object
                        (
                        )

                )

            [pre_tags] => #em#
            [post_tags] => #/em#
        )

    [size] => 5
    [from] => 0
)
RESPONSE:
string(2794) "{"took":108,"timed_out":false,"_shards":{"total":1,"successful":1,"skipped":0,"failed":0},"hits":{"total":{"value":1123,"relation":"eq"},"max_score":13.622944,"hits":[{"_index":"likecs_down_db","_type":"_doc","_id":"97887","_score":13.622944,"_source":{"id":"97887","title":"\u89c6\u9891\u5730\u5740\u89e3\u6790\u6e90\u7801|FLV\u89e3\u6790 php\u7248 v1.0","spidertime":"1623215697","contenttime":"1625472283","pageimage":"https:\/\/img.jbzj.com\/do\/uploads\/litimg\/121023\/113521101J9.gif","tag":"\u89c6\u9891\u5730\u5740\u89e3\u6790\u6e90\u7801|\u89c6\u9891","cate1":"\u6e90\u7801\u4e0b\u8f7d","cate2":"php\u6e90\u7801","cate3":"\u67e5\u8be2\u5de5\u5177","attr1":"63KB"},"highlight":{"title":["视频地址#em#解#/em##em#析#/em#源码|FLV#em#解#/em##em#析#/em# php版 v1.0"]}},{"_index":"likecs_down_db","_type":"_doc","_id":"146347","_score":13.478706,"_source":{"id":"146347","title":"Source Code Pro Bold\u5b57\u4f53,SourceCodePro-Bold\u5b57\u4f53\u4e0b\u8f7d","spidertime":"0","contenttime":"1672360733","pageimage":"2020415\/1586935271035.ttf","cate1":"\u5b57\u4f53\u4e0b\u8f7d","attr1":"Source Code Pro","attr2":"103516","attr3":"1","attr5":"SourceCodePro-Bold"},"highlight":{"title":["#em#Source#/em# #em#Code#/em# Pro Bold字体,SourceCodePro-Bold字体下载"]}},{"_index":"likecs_down_db","_type":"_doc","_id":"146350","_score":13.478706,"_source":{"id":"146350","title":"Source Code Pro Regular\u5b57\u4f53,SourceCodePro-Regular\u5b57\u4f53\u4e0b\u8f7d","spidertime":"0","contenttime":"1635490108","pageimage":"2020415\/1586935271068.ttf","cate1":"\u5b57\u4f53\u4e0b\u8f7d","attr1":"Source Code Pro","attr2":"103823","attr3":"1","attr5":"SourceCodePro-Regular"},"highlight":{"title":["#em#Source#/em# #em#Code#/em# Pro Regular字体,SourceCodePro-Regular字体下载"]}},{"_index":"likecs_down_db","_type":"_doc","_id":"144093","_score":13.478706,"_source":{"id":"144093","title":"Source Code Pro Bold\u5b57\u4f53,SourceCodePro-Bold\u5b57\u4f53\u4e0b\u8f7d","spidertime":"0","contenttime":"1680989881","pageimage":"2020415\/1586934904554.otf","cate1":"\u5b57\u4f53\u4e0b\u8f7d","attr1":"Source Code Pro","attr2":"83793","attr3":"1","attr5":"SourceCodePro-Bold"},"highlight":{"title":["#em#Source#/em# #em#Code#/em# Pro Bold字体,SourceCodePro-Bold字体下载"]}},{"_index":"likecs_down_db","_type":"_doc","_id":"144096","_score":13.478706,"_source":{"id":"144096","title":"Source Code Pro Regular\u5b57\u4f53,SourceCodePro-Regular\u5b57\u4f53\u4e0b\u8f7d","spidertime":"0","contenttime":"1672792158","pageimage":"2020415\/1586934904595.otf","cate1":"\u5b57\u4f53\u4e0b\u8f7d","attr1":"Source Code Pro","attr2":"81387","attr3":"1","attr5":"SourceCodePro-Regular"},"highlight":{"title":["#em#Source#/em# #em#Code#/em# Pro Regular字体,SourceCodePro-Regular字体下载"]}}]}}"
kubesphere source code解析 - 爱码网
good2study

kubesphere source code:

https://github.com/kubesphere/kubesphere

 

kubesphere解析

部分源于kubesphere 官方文档。文档不对具体代码解析,只对模块进行说明。

API 架构

下图是 KubeSphere API 的架构,所有请求都将通过 API Gateway 进行认证授权代理后发送到各个服务组件。

API路由

kubesphere使用caddy实现路由分发。下面是caddy配置文件。

####3个插件
  authenticate {
    token-idle-timeout 40m
    redis-url redis://redis.kubesphere-system.svc:6379
    secret {$JWT_SECRET}
    path /
    except GET /kapis/openpitrix.io/v1/apps /kapis/openpitrix.io/v1/attachments /kapis/openpitrix.io/v1/categories
    except * /apis/account.kubesphere.io/v1alpha1/authenticate /kapis/iam.kubesphere.io/v1alpha2/login /kapis/iam.kubesphere.io/v1alpha2/authenticate /images /kapis/devops.kubesphere.io/v1alpha2/webhook/github /kapis/devops.kubesphere.io/v1alpha2/webhook/git /swagger /kapis/v1alpha1/configz
  }

  authentication {
    path /
    except * /kapis/tenant.kubesphere.io/v1alpha2 /kapis/alerting.kubesphere.io/v1/comment /kapis/alerting.kubesphere.io/v1/resource_type /kapis/alerting.kubesphere.io/v1/metric /kapis/notification.kubesphere.io /kapis/resources.kubesphere.io/v1alpha2/registry /kapis/iam.kubesphere.io/v1alpha2/rulesmapping /kapis/jenkins.kubesphere.io /kapis/devops.kubesphere.io /apis/devops.kubesphere.io /kapis/resources.kubesphere.io/v1alpha2/git/verify
  }

  swagger
###路由策略
# k8s api
  proxy /api https://kubernetes.default {
    header_upstream Authorization "Bearer {$KUBESPHERE_TOKEN}"
    insecure_skip_verify
    transparent
    websocket
  }

  # fix jenkins auth plugin
  proxy /apis/account.kubesphere.io/v1alpha1/authenticate http://ks-account.kubesphere-system.svc/kapis/iam.kubesphere.io/v1alpha2/authenticate {
    without /apis/account.kubesphere.io/v1alpha1/authenticate
    transparent
  }

  # jenkins
  proxy /kapis/jenkins.kubesphere.io http://ks-jenkins.kubesphere-devops-system.svc {
    without /kapis/jenkins.kubesphere.io
    transparent
  }

  proxy /job http://ks-jenkins.kubesphere-devops-system.svc {
    transparent
  }

  # old devops api
  proxy /kapis/devops.kubesphere.io/v1alpha/ http://ks-devops.kubesphere-devops-system.svc/api {
    without /kapis/devops.kubesphere.io
    transparent
  }

  # new devops api
  proxy /kapis/devops.kubesphere.io/v1alpha2/ http://ks-apiserver.kubesphere-system.svc {
    transparent
  }

  # iam
  proxy /kapis/iam.kubesphere.io http://ks-account.kubesphere-system.svc {
    transparent
  }

  # tenant
  proxy /kapis/tenant.kubesphere.io http://ks-apiserver.kubesphere-system.svc {
    transparent
  }

  # operations
  proxy /kapis/operations.kubesphere.io http://ks-apiserver.kubesphere-system.svc {
    transparent
  }

  # openpitrix
  proxy /kapis/openpitrix.io http://ks-apiserver.kubesphere-system.svc {
    transparent
  }

  # logging
  proxy /kapis/logging.kubesphere.io http://ks-apiserver.kubesphere-system.svc {
    transparent
  }

  # alerting
  proxy /kapis/alerting.kubesphere.io http://alerting-client-server.kubesphere-alerting-system.svc:9200/api {
    without /kapis/alerting.kubesphere.io
    transparent
  }

  # servicemesh
  proxy /kapis/servicemesh.kubesphere.io http://ks-apiserver.kubesphere-system.svc {
    transparent
  }

  proxy /kapis/resources.kubesphere.io http://ks-apiserver.kubesphere-system.svc {
    transparent
  }

  proxy /kapis/metrics.kubesphere.io http://ks-apiserver.kubesphere-system.svc {
    transparent
  }

  # terminal
  proxy /kapis/terminal.kubesphere.io http://ks-apiserver.kubesphere-system.svc {
    transparent
    websocket
  }

  # monitoring
  proxy /kapis/monitoring.kubesphere.io http://ks-apiserver.kubesphere-system.svc {
    transparent
  }

  # notification
  proxy /kapis/notification.kubesphere.io http://notification.kubesphere-alerting-system.svc:9200 {
    without /kapis/notification.kubesphere.io
    transparent
  }

  # everything else goes to ks-apiserver
  proxy /kapis http://ks-apiserver.kubesphere-system.svc {
    transparent
  }

  log / stdout "{remote} {when} {method} {uri} {proto} {status} {size} {latency_ms}ms"
}

  

 

kubesphere模块

代码目录说明

源于docs/en/guides/Kubesphere-code-layout.md。一些目录已经使用中文说明

├── api // 自动生成的api 文档
│   ├── api-rules  
│   ├── ks-openapi-spec  
│   └── openapi-spec 
├── build // Dockerfile,用于生成各个模块docker镜像
│   ├── hypersphere 
│   ├── ks-apigateway
│   ├── ks-apiserver
│   ├── ks-controller-manager
│   ├── ks-iam
│   └── ks-network
├── cmd // kubesphere各个模块的程序入口.
│   ├── controller-manager  
│   │   └── app
│   ├── hypersphere 
│   ├── ks-apigateway // ks-apigateway模块
│   │   └── app
│   ├── ks-apiserver //ks-apiserver模块
│   │   └── app
│   ├── ks-iam // ks-iam模块
│   │   └── app
│   └── ks-network
├── config // CRD 配置文件
│   ├── crds // CRD yaml files
│   ├── default // kustomization yaml files
│   ├── manager // controller manager yaml files
│   ├── rbac // rbac yaml files
│   ├── samples // CRD sample
│   └── webhook // webhook yaml files
├── docs 
│   ├── en
│   │   ├── concepts-and-designs
│   │   └── guides
│   └── images
├── hack // Script files to help people develop
│   └── lib
├── pkg // 主要代码. 
│   ├── api // REST API的消息体
│   │   ├── devops
│   │   ├── logging
│   │   └── monitoring
│   ├── apigateway // ks-apigateway模块的重要依赖。
│   │   └── caddy-plugin //caddy的3个插件
│   ├── apis // CRD资源数据的结构体,
│   │   ├── devops
│   │   ├── network
│   │   ├── servicemesh
│   │   └── tenant
│   ├── apiserver // ks-apiserver模块的重要依赖。REST API的执行函数
│   │   ├── components
│   │   ├── devops
│   │   ├── git
│   │   ├── iam
│   │   ├── logging
│   │   ├── monitoring
│   │   ├── openpitrix
│   │   ├── operations
│   │   ├── quotas
│   │   ├── registries
│   │   ├── resources
│   │   ├── revisions
│   │   ├── routers
│   │   ├── runtime
│   │   ├── servicemesh
│   │   ├── tenant
│   │   ├── terminal
│   │   ├── workloadstatuses
│   │   └── workspaces
│   ├── client // k8s CRD客户端。代码自动生成
│   │   ├── clientset
│   │   ├── informers
│   │   └── listers
│   ├── constants // common constants
│   ├── controller // controller manger\'s reconciliation logic
│   │   ├── application
│   │   ├── clusterrolebinding
│   │   ├── destinationrule
│   │   ├── job
│   │   ├── namespace
│   │   ├── network
│   │   ├── s2ibinary
│   │   ├── s2irun
│   │   ├── storage
│   │   ├── virtualservice
│   │   └── workspace
│   ├── db // 数据库表
│   │   ├── ddl
│   │   ├── schema
│   │   └── scripts
│   ├── gojenkins // Jenkins客户端
│   │   ├── _tests
│   │   └── utils
│   ├── informers
│   ├── kapis // ks-apiserver模块的重要依赖。REST API注册
│   │   ├── devops
│   │   ├── iam
│   │   ├── logging
│   │   ├── monitoring
│   │   ├── openpitrix
│   │   ├── operations
│   │   ├── resources
│   │   ├── servicemesh
│   │   ├── tenant
│   │   └── terminal
│   ├── models // ks-apiserver模块的重要依赖。REST API的数据层
│   │   ├── components
│   │   ├── devops
│   │   ├── git
│   │   ├── iam
│   │   ├── kubeconfig
│   │   ├── kubectl
│   │   ├── log
│   │   ├── metrics
│   │   ├── nodes
│   │   ├── openpitrix
│   │   ├── quotas
│   │   ├── registries
│   │   ├── resources
│   │   ├── revisions
│   │   ├── routers
│   │   ├── servicemesh
│   │   ├── status
│   │   ├── storage
│   │   ├── tenant
│   │   ├── terminal
│   │   ├── workloads
│   │   └── workspaces
│   ├── server // Data processing part of REST API
│   │   ├── config
│   │   ├── errors
│   │   ├── filter
│   │   ├── options
│   │   └── params
│   ├── simple // common clients
│   │   └── client
│   ├── test
│   ├── utils // common utils
│   │   ├── hashutil
│   │   ├── idutils
│   │   ├── iputil
│   │   ├── jsonutil
│   │   ├── jwtutil
│   │   ├── k8sutil
│   │   ├── net
│   │   ├── readerutils
│   │   ├── reflectutils
│   │   ├── signals
│   │   ├── sliceutil
│   │   ├── stringutils
│   │   └── term
│   ├── version
│   └── webhook
├── test // e2e test code
│   ├── e2e
├── tools // tools to genereate API docs
│   ├── cmd
│   │   ├── crd-doc-gen // gen CRD API docs
│   │   └── doc-gen // gen REST API docs
│   └── lib

  

kubesphere apigateway

  1. 使用caddy作为网关。
  2. 添加authenticate,authentication,swagger三个插件。

kubesphere apiserver

  1. 直接使用go-restful,实现rest api接口
  2. 接口的注册位置/pkg/kapis
  3. 接口函数实现/pkg/apiserver
  4. 数据层/pkg/models

kubesphere iam

  1. 实现基本等同于kubesphere apiserver。

kubesphere control manager

  1. 功能类似于k8s control-manager。监控自定义CRD资源。并根据资源状态执行相关操作。

k8s apiserver

  1. 自定义crd资源,原生资源都是直接走k8s-apiserver
  2. 端口6443。可以使用curl -k -H "Authorization: Bearer {token}" https://ip:6443/直接访问。
  3. crd资源的客户端是自动生成的。kubesphere apiserver也会访问k8s apiserver的内容

S2i builder

流程如下

1.s2ioperator定义CRD资源
2.用户向api server申请执行S2ibuilder资源
3.ks control-manager监控到S2ibuilder资源。
       a.ks control-manager向api server申请执行deployment,configmap等资源。
       b.api server将根据deployment,configmap。运行起s2irun容器,并将目录挂载该容器上
        c.s2irun容器执行git clone、docker build和docker pull等操作。
4.ks control-manager监控到S2ibuilder资源完毕,清除资源。

  

 
 

分类:

技术点:

相关文章:

  • 2021-10-04
  • 2021-08-29
  • 2021-12-02
  • 2021-08-15
  • 2021-12-18
  • 2022-01-07
猜你喜欢
  • 2021-09-10
  • 2018-06-10
  • 2021-11-15
  • 2021-08-14
  • 2021-09-16
  • 2021-10-09
  • 2020-01-27
相关资源
相似解决方案