开发者

Need a better language/frameworks doing RESTful webservices [closed]

开发者 https://www.devze.com 2022-12-13 11:05 出处:网络
Closed. This question is opinion-based. It is not currently accepting answers. Want to improve this question? Update the question so it can be answered with facts and citations by editing
Closed. This question is opinion-based. It is not currently accepting answers.

Want to improve this question? Update the question so it can be answered with facts and citations by editing this post.

Closed 3 years ago.

Improve this question

I'm developing out replacements for our company's web service stack.

The current stack was developed using SOAP 开发者_如何学Pythonand had some REST endpoints manually hacked in. It's a maintenance nightmare.

I can use any language, tech, and framework as long as it it fits the goal.

Requirements are:

  • easy for serving up RESTful services
  • uses an MVC model
  • supports injecting middle layers to do authentication (OAuth and Basic Auth) around calls (preferably in a declarative way)
  • makes it easy to do JSON, JSONP, and Plain ol' XML (Simple XML) type serialization of the return data
  • preferably has built in caching control and built in E-Tags support
  • preferably using a statically typed language but this doesn't matter if the amount of code I have to write is dramatically less
  • it would be awesome to have a framework that supports doing microthreaded/epoll type HTTP handling so I can easily support HTTP long polling, but this isn't a requirement

So far I've looked at:

  • .NET (C#)
    • ASP.NET MVC (simple MVC framework, would have to add the missing pieces manually to fit my requirements)
    • Monorails (simple MVC framework, less supported)
    • WCF (unfortunately it takes a lot of overriding to force it into submission to work nicely for consumption on clients not using WCF themselves)
  • Python
    • Pylons (top of my list right now, but it lacks easy XML serialization)
    • DJango (more traditional web framework than REST framework)
  • Scala (still new but big startups are using it)
  • Ruby on Rails (doesn't scale the way I like)

Any other ideas or thoughts?


I just started to work with Django and Piston — I think its a great combination


If you're considering .Net, there's OpenRasta ( http://trac.caffeine-it.com/openrasta/wiki/Doc ) , a really nice REST framework, simple yet powerful, where REST was not retrofitted as an afterthought like it was in WCF.


Ruby on Rails (doesn't scale the way I like)

Generally speaking, Ruby on Rails can scale well (now, anyway; the past is the past).

What kind of scalability does your system require and does Rails not offer?

In all other aspects of your requirements aside from static typing, Rails seems to be the industry leader.


There's alternative Ruby frameworks like Sinatra. It's very lightweight and flexible - definitely worth a look.

The example app:

require 'rubygems'
require 'sinatra'
get '/hi' do
  "Hello World!"
end

There's also a glue framework for Sinatra called 'Monk' which makes setting up more sophisticated project layouts much easier.


Nobody mentions http://www.jboss.org/resteasy/


There are several alternatives, many listed on this page: http://en.wikipedia.org/wiki/Representational_State_Transfer

I recommend Restlet, our RESTful framework for Java developers, with editions for Java SE, Java EE, Android, GWT and GAE.

Best regards,

Jerome Louvel

Restlet ~ Founder and Lead developer ~ http://www.restlet.org

Noelios Technologies ~ Co-founder ~ http://www.noelios.com


I would try Jello framework. It offers a clean, and simple to follow, JSON format and provides a very powerful and comprehensive RESTful implementation that follows the OData specification.

With Jello REST, you get complete support for all CRUD (Create, Retrieve, Update, Delete) operations and can construct complex queries to manipulate the data retrieval structure.

In addition, One of Jello's key features is its inline Authorization Model. With Jello you can assign different access levels for data elements at any resolution (Namespaces, Entities, Fields, Actions) and specify who is authorized to access the data via the REST API.

0

精彩评论

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