<p>Hey!
I work on a project as backend developer for two mobile applications (Android and IOs) and wrote my server in c# with MVC. Now I found this great project so now my question, is it hard to wirte a rest service for a mysql server? (At the project I got about 10 tables and about 60 rows) And are there any advantages for the mobile applications if I choose golang? And what are the main advantages of golang against MVC c#?</p>
<p>Than you!</p>
<hr/>**评论:**<br/><br/>heraclmene: <pre><p>Please have a look on Google and decide for yourself. One person's opinion might not be the reason why you should make the switch. </p></pre>Mr_Swifts: <pre><p>Hiya</p>
<p>It is pretty easy to write rest services in go, but while the learning curve for go is smaller than other languages it is still there.</p>
<p>The main advantages of go server would be performance, and you get concurrency for no extra work</p></pre>PsyWolf: <pre><p>For a simple rest service over a few tables, either one will do just fine. Go and C# have similar performance characteristics (faster than python, slower than C), so I wouldn't base your decision making on that. If you want to do things concurrently, go may be easier. If your project does something specific that will benefit heavily from generics, C# will be easier.</p>
<p>I summed up my personal opinion on Go vs .NET a while back, so I'll just refer you to that for the broader comparison <a href="https://www.reddit.com/r/golang/comments/5cenu6/z/d9wpvpq" rel="nofollow">https://www.reddit.com/r/golang/comments/5cenu6/z/d9wpvpq</a> </p></pre>brightam1: <pre><p>There are no advantages for clients going with either C# or Go. That's kind of the point of writing a REST Service/API is that it separates client and server tasks. </p>
<p>tldr
C# for development speed,
Go for application speed</p>
<p>C# with WebAPI and Entity Framework (connector here: <a href="http://dev.mysql.com/downloads/connector/net/" rel="nofollow">http://dev.mysql.com/downloads/connector/net/</a>) should get you up and running with basic CRUD operations very quickly. C# is also a very mature and convenient language that should be able to handle every problem you throw at it.</p>
<p>While I very much enjoy programming in Go, it takes more work than C# to get every thing up and running. If you are already familiar with C# and are looking to get something done I'd suggest you continue with C#. Don't give up on Go though. If you want to learn more about all of the things that .NET WebAPI and MVC is handling for you then Go is a great language to learn about web servers and with some work you can put together a well-tuned and fast REST service.</p></pre>ultra_brite: <pre><p>asp.net MVC is a fully featured web framework. Go is a language with a standard library. There is no equivalent to MVC in Go, none.</p>
<p>Now imaging having to re-implement MVC with the asp.net std lib only. That's the difference between C# + MVC and Go . I don't think a Go web service would be faster, the bottleneck is going to be your RDBMS.</p></pre>
这是一个分享于 的资源,其中的信息可能已经有所发展或是发生改变。
入群交流(和以上内容无关):加入Go大咖交流群,或添加微信:liuxiaoyan-s 备注:入群;或加QQ群:692541889
- 请尽量让自己的回复能够对别人有帮助
- 支持 Markdown 格式, **粗体**、~~删除线~~、
`单行代码`
- 支持 @ 本站用户;支持表情(输入 : 提示),见 Emoji cheat sheet
- 图片支持拖拽、截图粘贴等方式上传