Any awesome problems to test my Go Concurrency chops?

blov · · 675 次点击    
这是一个分享于 的资源,其中的信息可能已经有所发展或是发生改变。
<p>Do you guys know any problems (or projects) which can be solved elegantly with Go&#39;s way of doing things?</p> <p>I&#39;m specifically looking for problems where concurrency comes into play.</p> <hr/>**评论:**<br/><br/>captncraig: <pre><p>Websocket or Long polling server. </p> <p>User submits job -&gt; Goes into queue -&gt; N workers take jobs off queue -&gt; User gets results.</p> <p>Doing this for a fairly complicated or long-runing task can be fun. The tricks come into reporting queue position and job status all the way through the pipeline to one or more interested watchers.</p></pre>cientificooo: <pre><p>Write a web crawler. Is really fun. Fetch a page, extract new urls, do again. You can create later on index, graphs,...</p> <p>If you have the data stored, you can later play that paralleling computation.</p> <p>Other options is scaling horizontally, modifying the crawler to be distributed across several machines.</p></pre>KimIlYong: <pre><p>If you want a crawler to test your go funcs:</p> <p>Shameless self ad: <a href="http://intogooglego.blogspot.co.at/" rel="nofollow">http://intogooglego.blogspot.co.at/</a></p> <p>Check my blog, im using my own crawler using GoQuery for my tests of different database layers/ORM libs.</p> <p>And the crawler is pulling from <a href="/r/golang" rel="nofollow">/r/golang</a> :)</p></pre>andreasblixt: <pre><p>I would say start with a simple ASCII chat server that can be used over telnet. Basically something that plays out like:</p> <pre><code>telnet localhost 1337 Trying ::1... Connected to localhost. Escape character is &#39;^]&#39;. - Welcome to the chat! - People currently here: -&gt; Bob - What is your name? Blixt - Blixt has joined the chat. Bob: Hello Blixt! Hello Blixt: Hello </code></pre></pre>Jalaska13: <pre><p><a href="http://archives.cazzaserver.com/SleepSortWiki/SleepSort.html" rel="nofollow">http://archives.cazzaserver.com/SleepSortWiki/SleepSort.html</a></p></pre>pinpinbo: <pre><p>Write your own in-memory task queue with websocket frontend.</p> <p>This is something I&#39;ve been meaning to write myself but it&#39;s hard to find the time.</p></pre>eduarto: <pre><p>Anything with more than one network/database/whatever connection.</p></pre>knowmonger: <pre><p>Along these lines, I can&#39;t think of anything other than a chat application. Can you think of more stuff, buddy?</p></pre>

入群交流(和以上内容无关):加入Go大咖交流群,或添加微信:liuxiaoyan-s 备注:入群;或加QQ群:692541889

675 次点击  
加入收藏 微博
0 回复
暂无回复
添加一条新回复 (您需要 登录 后才能回复 没有账号 ?)
  • 请尽量让自己的回复能够对别人有帮助
  • 支持 Markdown 格式, **粗体**、~~删除线~~、`单行代码`
  • 支持 @ 本站用户;支持表情(输入 : 提示),见 Emoji cheat sheet
  • 图片支持拖拽、截图粘贴等方式上传