{"id":1584,"date":"2022-05-07T11:42:09","date_gmt":"2022-05-07T03:42:09","guid":{"rendered":"https:\/\/qishiya.com\/?p=1584"},"modified":"2022-05-07T11:42:09","modified_gmt":"2022-05-07T03:42:09","slug":"%e6%80%8e%e4%b9%88%e6%ad%a3%e7%a1%ae%e7%9a%84%e5%a4%8d%e5%88%b6%e4%bb%a3%e7%a0%81","status":"publish","type":"post","link":"https:\/\/qishiya.com\/?p=1584","title":{"rendered":"\u600e\u4e48\u6b63\u786e\u7684\u590d\u5236\u4ee3\u7801"},"content":{"rendered":"\n<p>\u4eca\u5e74\u6709\u4e00\u4e2a\u76ee\u6807\u662f\u7528 Go \u8bed\u8a00\u5199\u51e0\u4e2a\u5e94\u7528\uff0c\u5e76\u4e14\u8fd9\u51e0\u4e2a\u5e94\u7528\u4e00\u5b9a\u8981\u653e\u5230\u7ebf\u4e0a\u53bb\uff0c\u8ba2\u4e86\u4e00\u4e2a\u5c0f\u76ee\u6807\uff0c\u6bcf\u4e00\u4e2a\u5e94\u7528\u5e2e 10 \u4e07\u4eba\uff0c\u6211\u4ee5\u524d\u662f\u5199 C \u7684\uff0c\u4e5f\u5199\u8fc7 php\uff0c\u540e\u6765\u8d1f\u8d23\u5927\u6570\u636e\u7684\u65f6\u5019\uff0c\u4e5f\u7528\u8fc7 java\uff0cscala \u4e4b\u7c7b\u7684\uff0cGo \u8bed\u8a00\u6ca1\u6709\u5b8c\u6574\u7684\u5b66\u4e60\u8fc7\uff0c\u53ea\u662f\u770b\u4e86\u4e00\u4e0b <a href=\"https:\/\/go.dev\/tour\/welcome\/1\">A Tour of Go<\/a>\uff0c\u53d1\u73b0 Go \u8bed\u8a00\u6709 C \u8bed\u8a00\u7684\u4e00\u4e9b\u5f71\u5b50\uff0c\u6211\u5c31\u5f00\u59cb\u7528 Go \u6765\u5199\u6211\u7684\u7b2c\u4e00\u4e2a\u5e94\u7528\uff0c\u5b9e\u73b0\u4e00\u4e2a\u683c\u5f0f\u5316\u7684 Google \u670d\u52a1\u7ffb\u8bd1\uff0c\u5de5\u4f5c\u91cf\u5168\u90e8\u52a0\u8d77\u6765\u4e0d\u8d85\u8fc7 3 \u5929\uff0c\u5230\u76ee\u524d\u4e3a\u6b62\uff0c\u4f7f\u7528\u4eba\u6570\u5df2\u7ecf\u8d85\u8fc7 1 \u4e07\u4eba\u3002<\/p>\n\n\n\n<figure class=\"wp-block-image is-style-default\"><img decoding=\"async\" src=\"https:\/\/tutu-1252436247.cos.ap-beijing.myqcloud.com\/2022\/05\/20220506CpPY36.jpg\" alt=\"20220506CpPY36\"\/><\/figure>\n\n\n\n<div id=\"ez-toc-container\" class=\"ez-toc-v2_0_61 counter-hierarchy ez-toc-counter ez-toc-custom ez-toc-container-direction\">\n<div class=\"ez-toc-title-container\">\n<p class=\"ez-toc-title \" >\u76ee\u5f55<\/p>\n<span class=\"ez-toc-title-toggle\"><a href=\"#\" class=\"ez-toc-pull-right ez-toc-btn ez-toc-btn-xs ez-toc-btn-default ez-toc-toggle\" aria-label=\"Toggle Table of Content\"><span class=\"ez-toc-js-icon-con\"><span class=\"\"><span class=\"eztoc-hide\" style=\"display:none;\">Toggle<\/span><span class=\"ez-toc-icon-toggle-span\"><svg style=\"fill: #ff6200;color:#ff6200\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" class=\"list-377408\" width=\"20px\" height=\"20px\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"M6 6H4v2h2V6zm14 0H8v2h12V6zM4 11h2v2H4v-2zm16 0H8v2h12v-2zM4 16h2v2H4v-2zm16 0H8v2h12v-2z\" fill=\"currentColor\"><\/path><\/svg><svg style=\"fill: #ff6200;color:#ff6200\" class=\"arrow-unsorted-368013\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" width=\"10px\" height=\"10px\" viewBox=\"0 0 24 24\" version=\"1.2\" baseProfile=\"tiny\"><path d=\"M18.2 9.3l-6.2-6.3-6.2 6.3c-.2.2-.3.4-.3.7s.1.5.3.7c.2.2.4.3.7.3h11c.3 0 .5-.1.7-.3.2-.2.3-.5.3-.7s-.1-.5-.3-.7zM5.8 14.7l6.2 6.3 6.2-6.3c.2-.2.3-.5.3-.7s-.1-.5-.3-.7c-.2-.2-.4-.3-.7-.3h-11c-.3 0-.5.1-.7.3-.2.2-.3.5-.3.7s.1.5.3.7z\"\/><\/svg><\/span><\/span><\/span><\/a><\/span><\/div>\n<nav><ul class='ez-toc-list ez-toc-list-level-1 ' ><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-1\" href=\"https:\/\/qishiya.com\/?p=1584\/#%E7%BF%BB%E8%AF%91%E6%9C%8D%E5%8A%A1\" title=\"\u7ffb\u8bd1\u670d\u52a1\">\u7ffb\u8bd1\u670d\u52a1<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-2\" href=\"https:\/\/qishiya.com\/?p=1584\/#%E5%8A%9F%E8%83%BD%E7%82%B9\" title=\"\u529f\u80fd\u70b9\">\u529f\u80fd\u70b9<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-3\" href=\"https:\/\/qishiya.com\/?p=1584\/#%E6%8A%80%E6%9C%AF%E6%A0%88\" title=\"\u6280\u672f\u6808\">\u6280\u672f\u6808<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-4\" href=\"https:\/\/qishiya.com\/?p=1584\/#%E4%BE%9D%E8%B5%96%E6%9C%8D%E5%8A%A1\" title=\"\u4f9d\u8d56\u670d\u52a1\">\u4f9d\u8d56\u670d\u52a1<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-5\" href=\"https:\/\/qishiya.com\/?p=1584\/#%E5%A4%8D%E5%88%B6%E4%BB%A3%E7%A0%81\" title=\"\u590d\u5236\u4ee3\u7801\">\u590d\u5236\u4ee3\u7801<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-6\" href=\"https:\/\/qishiya.com\/?p=1584\/#Github\" title=\"Github\">Github<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-7\" href=\"https:\/\/qishiya.com\/?p=1584\/#hotexamples\" title=\"hotexamples\">hotexamples<\/a><\/li><li class='ez-toc-page-1 ez-toc-heading-level-2'><a class=\"ez-toc-link ez-toc-heading-8\" href=\"https:\/\/qishiya.com\/?p=1584\/#medium\" title=\"medium\">medium<\/a><\/li><\/ul><\/nav><\/div>\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E7%BF%BB%E8%AF%91%E6%9C%8D%E5%8A%A1\"><\/span>\u7ffb\u8bd1\u670d\u52a1<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>\u4e3a\u4ec0\u4e48\u8981\u5199\u8fd9\u4e2a\u7ffb\u8bd1\u670d\u52a1\uff0c\u6211\u662f\u6ca1\u80fd\u529b\u53bb\u5b9e\u73b0\u6574\u4e2a\u7ffb\u8bd1\u5f15\u64ce\u7684\uff0c\u4e00\u662f\u6ca1\u8fd9\u4e48\u591a\u8bed\u6599\uff0c\u4e8c\u662f\u4e5f\u6ca1\u8fd9\u4e2a\u7b97\u6cd5\u548c\u5de5\u7a0b\u80fd\u529b\uff0c\u8ba4\u6e05\u8fd9\u4e00\u70b9\u5c31\u975e\u5e38\u91cd\u8981\u4e86\uff0c\u6211\u4e3b\u8981\u662f\u89e3\u51b3\u6211\u7ecf\u5e38\u9047\u5230\u7684\u4e24\u4e2a\u95ee\u9898\uff1a<\/p>\n\n\n\n<ul class=\"wp-block-list\"><li>\u957f\u6587\u7ffb\u8bd1<\/li><li>\u6709\u683c\u5f0f\u7684\u7ffb\u8bd1(markdown\u3001HTML)<\/li><\/ul>\n\n\n\n<p>\u5728 Google \u6216\u8005 DeepL \u662f\u4e0d\u80fd\u7ffb\u8bd1\u957f\u6587\u7684\uff0c\u4e5f\u4e0d\u652f\u6301 markdown \u4e4b\u7c7b\u7684\u5bcc\u6587\u672c\u7ffb\u8bd1\uff0c\u6211\u5c31\u89e3\u51b3\u8fd9\u4e24\u4e2a\u95ee\u9898\u3002<\/p>\n\n\n\n<!--more-->\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E5%8A%9F%E8%83%BD%E7%82%B9\"><\/span>\u529f\u80fd\u70b9<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<ul class=\"wp-block-list\"><li>\u524d\u7aef\u5b9e\u73b0\u4e00\u4e2a markdown \u7f16\u8f91\u5668<\/li><li>\u540e\u7aef\u63d0\u4f9b\u4e00\u4e2a api \u7684\u5c01\u88c5\uff0c\u53ef\u4ee5\u8c03\u7528 google translate \u7b49\u7ffb\u8bd1\u670d\u52a1\u3002<\/li><li>\u9632\u6b62\u673a\u5668\u4eba\u6765\u6ee5\u7528 api\uff0c\u8981\u52a0\u4e00\u4e2a\u9632\u6b62\u673a\u5668\u4eba\u7b56\u7565\u3002<\/li><li>\u8d85\u8fc7\u67d0\u4e00\u4e2a\u989d\u5ea6\uff0c\u8981\u6c42\u7528\u6237\u8ba4\u8bc1(google sign)\u3002<\/li><\/ul>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E6%8A%80%E6%9C%AF%E6%A0%88\"><\/span>\u6280\u672f\u6808<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<ul class=\"wp-block-list\"><li>\u8bed\u8a00\u9009\u62e9 Go lang<\/li><li>web \u6846\u67b6\u9009\u62e9 Gin<\/li><li>\u673a\u5668\u4eba\u9a8c\u8bc1 recaptcha<\/li><li>\u7528\u6237\u8ba4\u8bc1 google oauth2<\/li><li>\u914d\u7f6e\u6587\u4ef6 multiconfig<\/li><li>\u65e5\u5fd7 zerolog<\/li><li>session \u7528\u7684\u662f gin sessions<\/li><li>\u7edf\u8ba1 google analytics<\/li><li>\u524d\u7aef\u6784\u67b6 bootstrap<\/li><li>\u7f16\u8f91\u5668 <a href=\"https:\/\/editor.stackoverflow.design\/\">Stacks Editor (stackoverflow.design)<\/a><\/li><\/ul>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E4%BE%9D%E8%B5%96%E6%9C%8D%E5%8A%A1\"><\/span>\u4f9d\u8d56\u670d\u52a1<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<ul class=\"wp-block-list\"><li>Google translate<\/li><\/ul>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"%E5%A4%8D%E5%88%B6%E4%BB%A3%E7%A0%81\"><\/span>\u590d\u5236\u4ee3\u7801<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>\u505a\u4efb\u4f55\u4e00\u4ef6\u4e8b\u60c5\uff0c\u90fd\u53ef\u4ee5\u62c6\u5206\u6210\u5f88\u5c0f\u7684\u70b9\uff0c\u8fd9\u4e9b\u5c0f\u7684\u70b9\u80af\u5b9a\u5f88\u591a\u4eba\u5b9e\u73b0\u8fc7\u4e86\uff0c\u6211\u8981\u505a\u7684\u662f\u628a\u6211\u8981\u5b9e\u73b0\u7684\u529f\u80fd\u62c6\u5206\u6210\u8fd9\u4e9b\u5c0f\u7684\u70b9\uff0c\u770b\u770b\u6709\u6ca1\u6709\u4eba\u5b9e\u73b0\u8fc7\uff0c\u5982\u679c\u6709\u4eba\u5b9e\u73b0\u8fc7\uff0c\u6211\u5c31\u53c2\u8003\u4ed6\u4eec\u7684\u5b9e\u73b0\uff0c\u81ea\u5df1\u53ea\u8981\u505a\u96c6\u6210\u5c31\u53ef\u4ee5\u4e86\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"Github\"><\/span>Github<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>github \u91cc\u9762\u6709\u5404\u79cd\u4ee3\u7801\uff0c\u4f46\u662f\u5f88\u591a\u662f\u4e0d\u80fd\u8dd1\u7684\uff0c\u6211\u627e\u4ee3\u7801\u7684\u9996\u9009\u7ad9\u70b9\u3002<br><a href=\"https:\/\/github.com\/davidleitw\/gin-oauth2-example\">davidleitw\/gin-oauth2-example: a simple example use gin to login with oauth2. (github.com)<\/a><\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"hotexamples\"><\/span>hotexamples<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p><a href=\"https:\/\/golang.hotexamples.com\/examples\/github.com.gin-gonic.contrib.sessions\/-\/Sessions\/golang-sessions-function-examples.html\">Golang Sessions Examples, github.com\/gin-gonic\/contrib\/sessions.Sessions Golang Examples &#8211; HotExamples<\/a><\/p>\n\n\n\n<p>\u8fd9\u4e2a\u7f51\u7ad9\u53ef\u4ee5\u67e5\u627e\u5404\u79cd demo\uff0c\u975e\u5e38\u597d\u7528\uff0c\u6bd4\u5982\u6211\u67e5\u627e sessions \u7684\u4f7f\u7528\uff0c\u5c31\u7ed9\u51fa\u4e86 30 \u591a\u4e2a example\u3002<\/p>\n\n\n\n<h2 class=\"wp-block-heading\"><span class=\"ez-toc-section\" id=\"medium\"><\/span>medium<span class=\"ez-toc-section-end\"><\/span><\/h2>\n\n\n\n<p>\u8fd9\u4e2a\u7f51\u7ad9\u7684\u8d28\u91cf\u76f8\u5bf9\u6765\u8bf4\u6bd4\u8f83\u9ad8\uff0c\u6211\u4e5f\u4f1a\u4ece\u8fd9\u79cd\u5730\u65b9\u627e\u4f8b\u5b50\u3002<br><a href=\"https:\/\/medium.com\/wesionary-team\/session-management-in-golang-gin-framework-using-redis-with-e-1f17b6980924\">How To Manage Your Sessions in Golang using Gin Framework And Redis ? | by Bikash dulal | wesionaryTEAM | Medium<\/a><\/p>\n\n\n\n<p><a href=\"https:\/\/medium.com\/@bnprashanth256\/oauth2-with-google-account-gmail-in-go-golang-1372c237d25e\">OAuth2 with Google Account (gmail) in GO \u2014 GoLang | by Balakrishnan Nalin Prashanth | Medium<\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>\u4eca\u5e74\u6709\u4e00\u4e2a\u76ee\u6807\u662f\u7528 Go \u8bed\u8a00\u5199\u51e0\u4e2a\u5e94\u7528\uff0c\u5e76\u4e14\u8fd9\u51e0\u4e2a\u5e94\u7528\u4e00\u5b9a\u8981\u653e\u5230\u7ebf\u4e0a\u53bb\uff0c\u8ba2\u4e86\u4e00\u4e2a\u5c0f\u76ee\u6807\uff0c\u6bcf\u4e00\u4e2a\u5e94\u7528\u5e2e 10 \u4e07\u4eba\uff0c\u6211\u4ee5\u524d\u662f\u5199 C \u7684\uff0c\u4e5f\u5199\u8fc7 php\uff0c\u540e\u6765\u8d1f\u8d23\u5927\u6570\u636e\u7684\u65f6\u5019\uff0c\u4e5f\u7528\u8fc7 java\uff0cscala \u4e4b\u7c7b\u7684\uff0cGo \u8bed\u8a00\u6ca1\u6709\u5b8c\u6574\u7684\u5b66\u4e60\u8fc7\uff0c &#8230; <a title=\"\u600e\u4e48\u6b63\u786e\u7684\u590d\u5236\u4ee3\u7801\" class=\"read-more\" href=\"https:\/\/qishiya.com\/?p=1584\" aria-label=\"\u66f4\u591a \u600e\u4e48\u6b63\u786e\u7684\u590d\u5236\u4ee3\u7801\">Read more<\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"templates\/template-full-width.php","format":"standard","meta":{"footnotes":""},"categories":[5],"tags":[312],"class_list":["post-1584","post","type-post","status-publish","format-standard","hentry","category-5","tag-google-"],"_links":{"self":[{"href":"https:\/\/qishiya.com\/index.php?rest_route=\/wp\/v2\/posts\/1584","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/qishiya.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/qishiya.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/qishiya.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/qishiya.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=1584"}],"version-history":[{"count":0,"href":"https:\/\/qishiya.com\/index.php?rest_route=\/wp\/v2\/posts\/1584\/revisions"}],"wp:attachment":[{"href":"https:\/\/qishiya.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=1584"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/qishiya.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=1584"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/qishiya.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=1584"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}