{"id":276160,"date":"2021-01-12T18:23:13","date_gmt":"2021-01-12T10:23:13","guid":{"rendered":"http:\/\/4563.org\/?p=276160"},"modified":"2021-01-12T18:23:13","modified_gmt":"2021-01-12T10:23:13","slug":"%e5%90%84%e4%bd%8d%e8%80%81%e9%93%81%e8%bf%99%e5%87%a0%e4%b8%aa%e9%9d%a2%e8%af%95%e9%97%ae%e9%a2%98%e6%80%8e%e4%b9%88%e5%9b%9e%e7%ad%94%e5%9b%9e%e7%ad%94%e7%9a%84%e5%9c%86%e6%bb%a1%e4%b8%8d","status":"publish","type":"post","link":"http:\/\/4563.org\/?p=276160","title":{"rendered":"\u5404\u4f4d\u8001\u94c1,\u8fd9\u51e0\u4e2a\u9762\u8bd5\u95ee\u9898\u600e\u4e48\u56de\u7b54(\u56de\u7b54\u7684\u5706\u6ee1\u4e0d)?"},"content":{"rendered":"<div>\n<div>\n<div>\n<h1>                  \u5404\u4f4d\u8001\u94c1,\u8fd9\u51e0\u4e2a\u9762\u8bd5\u95ee\u9898\u600e\u4e48\u56de\u7b54(\u56de\u7b54\u7684\u5706\u6ee1\u4e0d)?               <\/h1>\n<p> <\/p>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : hijoker <\/span>  <span><i><\/i> 1<\/span> <\/div>\n<div> <\/div>\n<\/p><\/div>\n<\/p><\/div>\n<\/p><\/div>\n<div isfirst=\"1\"> <\/p>\n<h3>\u5982\u679c\u4ece\u4e00\u4e2a map \u91cc\u968f\u673a\u62bd\u53d6 3 \u4e2a key,\u6982\u7387\u4fdd\u6301\u4e00\u6837,\u8981\u600e\u4e48\u505a<\/h3>\n<ul>\n<li>\u628a key \u653e\u5230 slice \u91cc,\u968f\u673a\u83b7\u53d6 3 \u4e2a key<\/li>\n<\/ul>\n<h3>channel,2 \u4e2a goroutine \u540c\u65f6\u53d1\u9001\u548c\u63a5\u6536,\u4f1a\u53d1\u751f\u4ec0\u4e48?<\/h3>\n<ul>\n<li>\u5bf9\u4e8e\u65e0\u7f13\u5b58\u7684,\u53d1\u9001\u7aef\u4f1a\u77ed\u6682\u7684\u963b\u585e<\/li>\n<li>\u5bf9\u4e8e\u6709\u7f13\u5b58\u7684, \u770b\u7f13\u5b58\u662f\u5426\u5df2\u6ee1,\u5982\u679c\u6ee1\u4e86\u5c31\u548c\u65e0\u7f13\u5b58\u4e00\u6837<\/li>\n<\/ul>\n<h3>map \u91cc\u7684\u5143\u7d20\u88ab delete \u540e,map \u7684\u5185\u5b58\u7684\u4f53\u79ef\u4f1a\u4e0d\u4f1a\u7acb\u5373\u51cf\u5c0f<\/h3>\n<ul>\n<li>\u4e0d\u4f1a,gc \u4e0d\u4f1a\u7acb\u5373\u6267\u884c<\/li>\n<\/ul>\n<h3>\u4e00\u4e2a work server,\u6bcf\u6b21\u6536\u5230\u4e00\u4e2a\u8bf7\u6c42,\u5c31\u521b\u5efa\u4e00\u4e2a\u534f\u7a0b\u53bb\u5904\u7406\u8fd9\u4e2a\u8bf7\u6c42,\u91cc\u9762\u6709\u5927\u91cf\u7684 slice,append \u8fd9\u79cd\u60c5\u51b5,\u77ed\u65f6\u95f4\u8bf7\u6c42\u7279\u522b\u591a,\u8fd9\u4e2a\u670d\u52a1\u5668\u4f1a\u53d1\u751f\u4ec0\u4e48\u60c5\u51b5<\/h3>\n<ul>\n<li>\u5185\u5b58\u66b4\u6da8?<\/li>\n<\/ul><\/div>\n<div> <b>\u5927\u4f6c\u6709\u8a71\u8aaa<\/b> (<span>23<\/span>)        <\/div>\n<div> <\/div>\n<\/p><\/div>\n<\/p><\/div>\n<ul>\n<li data-pid=\"4917274\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : virusdefender <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             map \u5c31\u662f\u968f\u673a\u7684\uff0c\u76f4\u63a5 for \u5faa\u73af\u53d6\u524d\u4e09\u4e2a\u5c31\u884c\u5427                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917275\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u4e3b<\/span> <span>\u8cc7\u6df1\u5927\u4f6c : hijoker <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @virusdefender \u5728\u6570\u91cf\u4e0d\u5927\u7684\u60c5\u51b5\u4e0b,\u597d\u50cf\u5e76\u4e0d\u662f\u5f88\u968f\u673a                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917276\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : CEBBCAT <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u6211\u89c9\u5f97\u60f3\u95ee\u7684\u8fd8\u662f runtime \u5b9e\u73b0\uff0c\u4f46\u597d\u50cf\u56de\u7b54\u6ca1\u6709\u600e\u4e48\u6d89\u53ca\u3002\u7279\u522b\u662f\u90a3\u4e2a map \u5220\u9664\u952e\u503c\u7684\uff0c\u786e\u5b9e\u4e0d\u4f1a\u7acb\u5373\u51cf\u5c0f\uff0c\u4f46\u539f\u56e0\u4e0d\u662f gc \u800c\u662f map \u7684\u5185\u5b58\u7ed3\u6784                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917277\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : CEBBCAT <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u4e0d\u8fc7\u611f\u8c22\u5206\u4eab\u9762\u8bd5\u9898                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917278\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : Aoang <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u7b2c\u4e8c\u4e2a\u95ee\u9898\uff0c\u5bf9\u4e8e channel \u4e24\u4e2a\u534f\u7a0b\u8fdb\u884c\u6536\u53d1\uff0c\u4f60\u7684\u77ed\u6682\u7684\u963b\u585e\u7684\u8bf4\u6cd5\u662f\u9519\u8bef\u7684\u3002<\/p>\n<p>\u4e00\u4e2a\u534f\u7a0b\u7ed9 channel \u53d1\u6d88\u606f\uff0c\u4e00\u4e2a\u534f\u7a0b\u4ece channel \u63a5\u6536\uff0c\u8981\u6c42\u662f\u8fd9\u4e24\u4e2a\u534f\u7a0b\u90fd\u51c6\u5907\u597d\uff0c\u624d\u80fd\u5b8c\u6210\u6536\u53d1\u64cd\u4f5c\u3002<\/p>\n<p>\u5f62\u8c61\u4e00\u70b9\u7684\u4f8b\u5b50\u5c31\u662f\uff0c\u5feb\u9012\u5458\u7ed9\u4f60\u9001\u5feb\u9012\uff0c\u4f60\u8981\u53bb\u62ff\u5feb\u9012\uff0c\u901a\u8fc7\u6c9f\u901a\u7ea6\u5b9a\u4e86\u65f6\u95f4\u5730\u70b9\uff0c\u5feb\u9012\u5458\u5f97\u5e26\u7740\u5feb\u9012\u8fc7\u53bb\uff0c\u4f60\u5f97\u8fc7\u53bb\u62ff\uff0c\u8fd9\u6837\u624d\u80fd\u5b8c\u6210\u8fd9\u4e2a\u6d41\u7a0b\u3002<\/p>\n<p>\u800c\u5bf9\u4e8e\u6709\u7f13\u51b2\u7684 channel\uff0c\u662f\u4e0d\u9700\u8981\u6536\u53d1\u540c\u6b65\u7684\uff0c\u4f46\u662f\u961f\u5217\u6ee1\u4e86\u4e4b\u540e\u5c31\u548c\u65e0\u7f13\u51b2\u7684\u4e00\u6837\u4e86\u3002<\/p>\n<p>\u6240\u4ee5\uff0c\u540c\u65f6\u6536\u53d1\u4f1a\u76f4\u63a5\u5b8c\u6210\u8fd9\u4e00\u6b21\u6d88\u606f\u4f20\u9012\u3002\u975e\u540c\u65f6\u6536\u53d1\uff0c\u90a3\u4e48\u53d1\u9001\u7aef\u4f1a\u88ab\u963b\u585e\uff0c\u63a5\u6536\u7aef\u4e5f\u4f1a\u88ab\u963b\u585e\u3002                                                            <\/p><\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917279\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : carlclone <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u4f53\u79ef\u90a3\u9898\u4e0d\u662f\u8003\u5bdf gc , \u54c8\u5e0c\u8868\u6709\u88c5\u586b\u56e0\u5b50\uff0c\u5927\u4e8e\u6216\u5c0f\u4e8e\u7684\u65f6\u5019\u624d\u4f1a\u6267\u884c resize                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917280\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u4e3b<\/span> <span>\u8cc7\u6df1\u5927\u4f6c : hijoker <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @carlclone \u611f\u8c22                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917281\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u4e3b<\/span> <span>\u8cc7\u6df1\u5927\u4f6c : hijoker <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @Aoang \u611f\u8c22                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917282\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : Aoang <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u5173\u4e8e map \u4e2d\u7684 key \u88ab\u5220\u9664\u4e4b\u540e gc \u7684\u95ee\u9898\uff0c\u4e0d\u662f\u7279\u522b\u597d\u56de\u7b54\u3002\u5370\u8c61\u4e2d\u8fd9\u4e2a\u95ee\u9898\u5f88\u65e9\u5c31\u6709\u4eba\u5728 github \u63d0\u51fa issues \u8fc7\uff0c\u521a\u521a\u627e\u51fa\u6765\u4e86\u3002<\/p>\n<p>https:\/\/github.com\/golang\/go\/issues\/20135<\/p>\n<p>\u53ef\u4ee5\u53bb\u770b\u770b\u8fdb\u5c55                                                            <\/p><\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917283\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : baiyi <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             1.\u6ca1\u7406\u89e3<br \/>2.channel \u5185\u90e8\u6709\u9501\u5b9e\u73b0\u7ebf\u7a0b\u5b89\u5168\uff0c\u5269\u4e0b\u7684\u5c31\u662f goroutine \u963b\u585e\u5524\u9192\u7b49\u6d41\u7a0b<br \/>3.\u4e0d\u4f1a\uff0cmap \u6ca1\u6709\u7f29\u5bb9\u673a\u5236\uff0c\u5185\u5b58\u5360\u7528\u53ea\u4f1a\u8d8a\u6269\u8d8a\u591a<br \/>4.\u5927\u91cf\u7684 slice append \u64cd\u4f5c\u4f1a\u5bfc\u81f4\u5927\u91cf\u7684 \u5185\u5b58\u62f7\u8d1d\uff0c\u5e94\u8be5\u662f\u8003\u7684\u8fd9\u4e2a\u5427<\/p>\n<p>\u4ee5\u4e0a\u662f\u6839\u636e 1.13 \u7248\u672c\u6e90\u7801\u7684\u7406\u89e3\uff0c\u73b0\u5728\u53ef\u80fd\u4e0d\u51c6\u786e                                                            <\/p><\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917284\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u4e3b<\/span> <span>\u8cc7\u6df1\u5927\u4f6c : hijoker <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @Aoang \u6211\u4e5f\u521a\u521a\u770b\u5230\u8fd9\u4e2a\u4e86                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917285\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : guonaihong <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u5982\u679c\u662f\u6211\u56de\u7b54\u7684\u8bdd\u30021,4<br \/>\u628a map \u7684\u503c copy \u5230 slice \u3002\u7136\u540e\u4f7f\u7528 Fisher-Yates \u7b97\u6cd5\u4fdd\u6301\u6982\u7387\u4e00\u6837\u3002<\/p>\n<p>\u7b2c 4 \u4e2a\u9700\u8981\u95ee slice \u7684\u5927\u5c0f\u3002\u673a\u5668\u7684 total memory \u3002\u662f\u5426\u4f7f\u7528 sync.Pool \u3002\u7efc\u5408\u8003\u8651\u591a\u4e2a\u53d8\u91cf\u3002\u6700\u540e\u770b\u589e\u52a0\u548c\u6d88\u8d39\u7684\u901f\u5ea6\uff0c\u53ef\u80fd\u6709\u4e24\u79cd\u60c5\u51b5\u3002\u53ef\u80fd\u7206\u751f\u6210\u8005 &gt; \u6d88\u8d39\u8005(\u5185\u5b58\u56de\u6536)\uff0c\u53ef\u80fd\u751f\u6210\u8005==\u6d88\u8d39\u8005\u5e73\u8861(\u5185\u5b58\u56de\u6536)\uff0c\u5c31\u662f\u4e0d\u52a0\u4e0d\u51cf\u3002(\u5982\u679c\u4e0d\u5f15\u5165\u901f\u5ea6\u7684\u8bdd\uff0c\u8fd9\u9898\u63cf\u8ff0\u7684\u6709 bug)\u3002(\u8fd8\u6709\u4e00\u79cd\u6982\u7387\u5c0f\u7684\u60c5\u51b5\u751f\u6210\u8005 &lt; \u6d88\u8d39\u8005(\u5185\u5c11\u56de\u6536)\u3000\u57fa\u672c\u4e0d\u53ef\u80fd\u53d1\u751f)\u3002                                                            <\/p><\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917286\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : bruce0 <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @carlclone \u6211\u8bb0\u5f97 go \u7684 map \u5185\u5b58\u5360\u7528\u4e0d\u4f1a\u968f\u7740\u5143\u7d20\u7684 Delete \u800c\u51fa\u53d1 resize \u7684,\u4f8b\u5982 \u539f\u6765 map \u4e2d\u6709 100 \u4e2a\u5143\u7d20,\u8fd9\u65f6 map \u5360\u7528\u5185\u5b58 10M \u73b0\u5728\u628a map \u7684\u5143\u7d20\u5220\u9664 90 \u4e2a, map \u8fd8\u662f\u5360\u7528 10M \u5185\u5b58, \u5f53\u7136,\u5143\u7d20\u4f1a\u88ab gc \u56de\u6536\u6389.<\/p>\n<p>\u6211\u6ca1\u6709\u7814\u7a76\u8fc7\u6e90\u7801, \u53ea\u662f\u770b\u522b\u4eba\u7684\u5206\u6790\u6587\u7ae0\u4e86\u89e3\u7684,\u4e0d\u6b63\u786e\u8fd8\u8bf7\u6307\u6b63                                                            <\/p><\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917287\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : carlclone <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @bruce0 go \u7684\u597d\u50cf\u786e\u5b9e\u662f\u4e0d\u4f1a\uff0c\u6211\u7684\u6709\u95ee\u9898\uff0c\u6211\u662f\u6309\u7167\u4e00\u822c\u7684 map \u56de\u7b54\u7684                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917288\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : momo733 <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u6700\u540e\u7684\u90a3\u4e2a\u5e94\u8be5\u662f cpu \u4f1a\u66b4\u6da8\u5427\uff0c\u8bf4\u5230 append\uff0c\u5e94\u8be5\u662f\u8981\u95ee append \u6269\u5bb9                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917289\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : momo733 <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @momo733 \u5f53\u7136\u5185\u5b58\u4e5f\u6da8\u7684\u3002\u3002                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917290\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : carlclone <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @bruce0 \u67e5\u4e86\u4e00\u4e0b java \u7684 hashmap \u4e5f\u4e0d\u7f29\u5bb9&#8230;.\u76ee\u524d\u5c31\u53ea\u5728\u54c8\u5e0c\u8868\u5b66\u4e60\u65f6\u548c redis \u54c8\u5e0c\u8868\u91cc\u89c1\u5230\u8fc7\u7f29\u5bb9\u64cd\u4f5c,\u53ef\u80fd\u662f\u7f29\u5bb9\u7684\u6027\u4ef7\u6bd4\u786e\u5b9e\u4e0d\u9ad8\u5427                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917291\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : liuhan907 <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @hijoker<br \/>\u7b2c\u4e00\u9898\u6211\u89c9\u5f97\u662f\u8003\u5bdf\u968f\u673a\u91c7\u6837\u7b97\u6cd5\uff0c\u6700\u5e38\u89c1\u7684\u84c4\u6c34\u6c60\u7b97\u6cd5\u5c31\u53ef\u4ee5\u5904\u7406\u3002                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917292\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : lihongming <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @carlclone \u867d\u7136\u4e0d\u61c2 go\uff0c\u4f46\u73b0\u4ee3\u7cfb\u7edf\u786e\u5b9e\u4e0d\u518d\u6d41\u884c\u7f29\u5bb9\uff0c\u56e0\u4e3a\u73b0\u5728\u6700\u8d35\u7684\u786c\u4ef6\u8d44\u6e90\u662f CPU \u3002<\/p>\n<p>\u8fd9\u4e2a\u6982\u5ff5\u5728\u5b66 nosql \u7684\u65f6\u5019\u88ab\u53cd\u590d\u63d0\u53ca\uff0c\u4ee5\u524d\u6d41\u884c\u5173\u7cfb\u6570\u636e\u5e93\u662f\u56e0\u4e3a\u5b83\u53ef\u4ee5\u8282\u7ea6\u5b58\u50a8\u7a7a\u95f4\uff08\u4ee5\u524d\u6700\u8d35\u7684\u786c\u4ef6\u8d44\u6e90\uff09\uff0c\u4ee3\u4ef7\u5c31\u662f\u6570\u636e\u7528\u7684\u65f6\u5019\u9700\u8981\u4e34\u65f6\u7ec4\u88c5\uff0c\u8017\u8d39 CPU \u8d44\u6e90\u3002\u4f46\u73b0\u5728 CPU \u6210\u4e86\u6700\u8d35\u7684\u786c\u4ef6\u8d44\u6e90\uff0c\u6240\u4ee5\u5c31\u628a\u6570\u636e\u6309\u8bfb\u53d6\u65f6\u9700\u8981\u7684\u683c\u5f0f\u5b58\u50a8\uff0c\u5197\u4f59\u4e5f\u6ca1\u95ee\u9898\uff0c\u53ea\u8981\u80fd\u5c3d\u91cf\u51cf\u5c11\u4e34\u65f6\u7ec4\u88c5\u6570\u636e\u3002<\/p>\n<p>\u6240\u4ee5\uff0c\u9664\u975e\u8fc7\u5927\u7684\u54c8\u5e0c\u8868\u5f71\u54cd\u4e86\u6574\u4f53\u901f\u5ea6\uff0c\u5426\u5219\u4e0d\u7f29                                                            <\/p><\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917293\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : yzbythesea <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u6211\u89c9\u5f97\u524d\u4e09\u4e2a\u56de\u7b54\u5f97\u90fd\u53ef\u4ee5\u3002<\/p>\n<p>\u7b2c\u56db\u4e2a\u95ee\u9898\uff0c\u5982\u679c\u8bf7\u6c42\u592a\u591a\uff0c\u6bcf\u4e2a\u90fd\u5f00\u4e00\u4e2a goroutine \u663e\u7684\u5f88\u5931\u63a7\u3002\u7279\u522b\u662f goroutine \u91cc\u5bf9\u5185\u5b58\u6709\u660e\u663e\u538b\u529b\u3002\u4f60\u53ef\u4ee5 channel request \u5148\u3002                                                            <\/p><\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917294\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : Neo10373 <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             \u7b2c\u4e8c\u9898\u66f4\u5177\u4f53\u70b9\uff1a<br \/>\u65e0\u7f13\u5b58\uff0c\u540c\u65f6\u53d1\u9001\u548c\u63a5\u6536\u65f6\uff0c\u53d1\u9001\u7aef\u4f1a\u963b\u585e\uff0c\u63a5\u6536\u7aef\u5b8c\u6210\u63a5\u6536\uff0c\u53d1\u9001\u7aef\u89e3\u963b\u585e\u5b8c\u6210\u53d1\u9001\uff1b<br \/>\u6709\u7f13\u51b2\uff0c\u53d1\u9001\u7aef\u963b\u585e\u5230\u590d\u5236\u503c\u5230\u7f13\u51b2\u533a\u5b8c\u6210\uff0c\u7f13\u51b2\u533a\u6ee1\u4e00\u76f4\u963b\u585e\uff0c\u63a5\u6536\u7aef\u963b\u585e\u5230\u4ece\u7f13\u51b2\u533a\u53d6\u503c\u5b8c\u6210\uff0c\u7f13\u51b2\u533a\u7a7a\u4e00\u76f4\u963b\u585e                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917295\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u8cc7\u6df1\u5927\u4f6c : BBCCBB <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             3 \u8fd9\u4e2a delete map[key]. map \u7684\u5bb9\u91cf\u548c gc \u5e94\u8be5\u6ca1\u5173\u7cfb?                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li data-pid=\"4917296\" data-uid=\"2\">\n<div>\n<div>\n<div> <span>\u4e3b<\/span> <span>\u8cc7\u6df1\u5927\u4f6c : hijoker <\/span>  <\/div>\n<div> <i title=\"\u5f15\u7528\"><\/i>  <span>          <\/span> <\/div>\n<\/p><\/div>\n<div>                                                             @yzbythesea \u7b2c\u4e09\u4e2a\u95ee\u9898,\u9898\u76ee\u5c31\u662f\u6bcf\u4e2a\u8bf7\u6c42\u90fd\u5f00\u4e00\u4e2a goroutine, \u662f\u60f3\u95ee\u4f60\u8fd9\u4e2a\u670d\u52a1\u5668\u4f1a\u6709\u4ec0\u4e48\u8868\u73b0,\u6bd4\u8f83\u5f00\u653e,\u8fd9\u4e2a\u95ee\u9898                                                            <\/div>\n<\/p><\/div>\n<\/li>\n<li>\n","protected":false},"excerpt":{"rendered":"<p>\u5404\u4f4d\u8001\u94c1,\u8fd9\u51e0\u4e2a\u9762\u8bd5\u95ee\u9898\u600e\u4e48\u56de\u7b54(&hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[],"tags":[],"_links":{"self":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/276160"}],"collection":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=276160"}],"version-history":[{"count":0,"href":"http:\/\/4563.org\/index.php?rest_route=\/wp\/v2\/posts\/276160\/revisions"}],"wp:attachment":[{"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=276160"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=276160"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/4563.org\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=276160"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}