有没有人成功使用过新的 WCF REST Starter Kit,您会再次使用它吗? [英] Has anyone used the new WCF REST Starter Kit successfully and would you use it again?

查看:38
本文介绍了有没有人成功使用过新的 WCF REST Starter Kit,您会再次使用它吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

正如标题所暗示的那样,我想看看人们是否对此感到满意.

As the title suggests, I would like to see if this is something people are happy with.

我有几个项目,我将花一些时间来试验与 Web 服务相关的不同类型的技术,最好是 SOAP 的替代品,它可以很好地集成到 dotnet 内部/与 dotnet 集成.

I have several projects, where I will dedicate some time in experimenting with different kinds of technologies web service related, preferably alternatives to SOAP which would be well integrated inside/with dotnet.

我想听听是否已经有一些成功案例或人们对入门套件价值的看法:

I would like to hear if there are already some success stories or people's opinions on the worthiness of the starter kit:

该工具包是否仍然过于新鲜,以至于人们无法很好地接受它以对他们所取得的成就感到自豪?

Is the kit still too fresh for people to have been taking it on well enough to be proud of what they accomplished with it?

一些背景:

我的团队成员是新来的SOAP 和 REST,我正在平衡用哪一个来激励他们/我自己.

I have team members who are new to both SOAP and REST, and I am balancing which one to motivate them/myself on.

.

我个人不是太热情关于 SOAP,但就像我的厌恶对 SQL 我归咎于我自己的缺乏在这个主题上的经验比在技术本身.

I personally am not too enthusiastic about SOAP, but just like my aversion to SQL I blame my own lack of experience on the subject more than on the technology itself.

因此,在寻找其他方式来处理与 Web 相关的服务时,我遇到了 REST 并且到目前为止还不错..社区对此的接受情况如何?

So in looking for some other way to handle web related servicing, I bumped into REST and so far so good.. how is this being received by the community?

我很高兴看到关于入门套件替代品的评论和人们的建议.

I would be happy to see comments and people's recommendations on alternatives to the starter kit.

除了最初的问题之外,还欢迎对 REST 整体上取代 SOAP 的分布式超媒体以及想要捍卫 SOAP 的人发表评论.

Going a bit beyond the original question, comments on REST as a whole for distributed hypermedia in replacement of SOAP and from people who would like to defend SOAP are also welcomed.

抱歉,如果这是个骗局,我确实环顾四周,但没有找到与我想知道的完全相同的东西.

谢谢,

瑞克

推荐答案

我花了大约两周的时间使用 WCF 和 REST 入门工具包对 RESTful 服务进行原型设计,发现它非常难以掌握,非常不直观,并且让很多本该简单的事情变得非常困难.感觉就像他们试图在一个旨在抽象出 HTTP 的层之上添加一个 HTTP 仿真层,结果是很混乱.

I spent about two weeks prototyping a RESTful service using WCF with the REST starter kit, and found that it was extremely difficult to get to grips with, incredibly unintuitive, and made a lot of things that should be simple really quite difficult. It really feels like they're trying to bolt an HTTP emulation layer on top of a layer that's designed to abstract away HTTP and it's messy as a result.

作为参考,原型包括实现 CRUD 功能、X-HTTP-Method-Override 标头、将任何错误自定义转换为标准错误块、同时支持 XML 和 JSON 作为输入和输出格式、调用者的身份验证和授权,以及任何内部服务到对外服务的依赖注入.

For reference, the prototype included implementing CRUD functionality, the X-HTTP-Method-Override header, custom translation of any errors into a standard error block, support for both XML and JSON as both input and output formats, authentication and authorization of the caller, and dependency injection of any internal services into the outward-facing services.

然后我花了一周左右的时间使用 ASP.NET MVC 对相同的 API 进行原型设计,发现它更容易掌握,扩展直观,而且上面列表中的任何内容都没有困难(我被标题难住了)一会儿,但是 结果证明解决方案只有 10 行左右的代码).ASP.NET MVC 非常接近底层 HTTP 协议,因此可以轻松实现包含它的 RESTful API.

I then spent a week or so prototyping the same API using ASP.NET MVC and found it much simpler to get to grips with, intuitive to extend, and nothing in the above list was difficult (I was stumped on the header for a while, but the solution turned out to only be 10 lines of code or so). ASP.NET MVC is fairly close to the underlying HTTP protocol and as such makes it easy to implement a RESTful API which embraces it.

因此,我个人的建议(以及我公司根据我的研究采用的建议)是为 RESTful 服务避开 WCF,而使用 ASP.NET MVC.

So my personal recommendation (and the one my company has gone with on the basis of my research) is to steer well clear of WCF for RESTful services and go with ASP.NET MVC.

这篇关于有没有人成功使用过新的 WCF REST Starter Kit,您会再次使用它吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆