开发者

Is it advisable to write a server application in pure Ruby code?

I am using Ruby on Rails 3 and I am trying to develop a server application that interacts with web services.

Since it is "hard" to develop that using the Ruby on Rails framework because there are many complications on the way (e.g.: classe开发者_JAVA百科 encapsulation using namespaces), is it advisable to write the server application entirely in pure Ruby code?


I wouldn't advocate using Ruby on Rails as a persistent server, as it's completely engineered for a web-based request-driven approach, but Ruby is a perfectly fine language to pursue that sort of thing in.

eventmachine is a great place to start as it has a number of example modules that implement standard services like SMTP, DNS and Websocket.

It really depends on what kind of a server you're trying to build.


I highly recommend Node.js for quick yet fast servers. Node is evented and is really easy to get a functional server up and running. Most of us know enough Javascript to work with Node. Check the docs at the site I linked - may work out.

It is pretty 'new' though and is changing/evolving fast - that may be an issue.

For me I just use what I know and keep an eye out for road blocks. Ruby + Event Machine is a really solid choice as well.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜