Hot answers tagged

39

Does the business value of implementing them exceed the cost? If you implement, you need to change not just your server, but all clients (although you can support both formats and only change clients as needed). That will take time and testing, which is a direct cost. And don't underestimate the time taken to really understand protocol buffers (especially ...


38

When both sides have good arguments and the opinions on the issue are too strong to come to a consensus, you as a manager need to make a decision and end the debate. Otherwise it will just turn in circles and fortify the positions of all participants even more. The longer you wait, the harder will it be for the "losing" side to admit defeat and work ...


23

i maintain apis and somebody before me added protobuf (because it was "faster"). The only thing faster is RTT because of of smaller payload, and that can be fixed with gzipped JSON. The part that is distasteful to me is the relative work to maintain protobuf (compared to JSON). I use java so we use Jackson object mapping for JSON. Adding to a response ...


15

Ah yes...SOAP, the vaunted holy grail of computing. A lingua franca that promised interop between systems around the world. And then you get into the differences between SOAP implementations on Java and PHP and .NET. Or even between the WebSphere SOAP service and the Apache SOAP client. Never mind dealing with different WS-I compatability standards. Now ...


13

Assuming both sides are 100% correct in all of their arguments, which ones matter? WCF models are not POCO, because of [DataContract] & [DataMember] and those attributes Do you care? Are you planing on doing something that requires POCO? WCF supports distributed transactions Again is this something you are going to use and need to build if you ...


12

My suggestion, if you need to be quick about this and only need something simple to facilitate durable (disconnected) operation with WCF, is to look in to the WCF - MSMQ bindings. If you need something in a larger environment, look at nServiceBus. In my mind, nServiceBus would really begin to shine in a larger distributed environment. Take, for instance, ...


11

As far as writing one application that leverages both ASP.NET/MVC and WCF, its not great. WebAPI may have improved matters, but in one project I am familiar with that was using WCF and MVC in the same app, they ended up maintaining two different sets of models to represent the same concepts - one for the WCF code and one for the MVC code. You can imagine all ...


11

Put my two cents in. As a manager, you should ask your teammates to keep in mind the Yagni principle. This will help to reduce the list of reasons brought forward by both Teams. Our usage would be mostly for web, and we would expose our services over HTTP. In some cases (say 5 to 10 percent) we might need distributed transactions though. Rather ...


9

In my opinion, your observation is quite accurate. The high level implementations of XML based communication is usually not compatible with different platforms, even if they are both called "SOAP". Subtle differences in implementation, probably both within the scope of the standard implemented, create problems in real life use. My recommendation for service ...


9

I would do those in a different order- Firstly, I'd map my business domain, and figure out the best design to solve my business problem. This will give you your domain. Then, Ideally in a completely different mindset, think about the requirements of your client-side and UI; what data will be displayed, and how? This will give you your DTOs. Sometimes,...


9

You are correct, in that in terms of how the code will change over time, I typically lean toward parameter wrappers so that later, when I need more information to perform the same function when adding a new feature, I can preserve signatures, and add one more property to the existing wrapper object. When it comes to building communication contracts like you ...


8

I should begin by saying that WCF is the goto solution. What you mentioned above fits very well in the SOA (Service Oriented Architecture) definition, and WCF deals very well with SOA. Implementing a single locking service application, which can then be then integrated in all your components would be ideal because: When you update your locking and payment ...


7

Well, the famous WSHTTPBinding. It causes a lot of pain for non-.NET platforms. First of all, even if SOAP 1.2 is a standard, WSHTTPBinding is a Microsoft implementation over SOAP 1.2 and by experience, it's not as easy as "Our product support SOAP 1.2 so it'll work with WCF & WSHTTPBinding services, no problem!". Answer 1 There are two main security ...


7

I hesitate to offer this up as an answer, since it's not exactly objective. But my personal experience is that every time I have been involved in a project that used WCF, we regretted it. If you are implementing something that genuinely makes use of WCF's flexibility (e.g. a SOA that needs to be accessed via HTTP/SOAP over the web and also via TCP over an ...


7

In answer to the 1st part of your question, I agree with your colleague's assessment that outputting JSON would be much more efficient & simple to do. (KISS principle) Before you go ahead with WCF though, I highly recommend that you consider the excellent Service Stack - an opensource .NET & Mono REST web services framework. The performance is ...


7

They aren't a 1 for 1 replacement -- many times you'll use NServiceBus to feed messages into or take messages from a WCF endpoint. In any case, handling disconnected mode scenarios like this is where message queues really, really shine. NServiceBus is a good place to start. There are a number of other options out there. I'll note many of them do actually ...


7

This isn't really a direct answer to your question, but an alternative for you to explore. In addition to my other answer, you can also check out another .NET web service framework called ServiceStack. Some good points about it: Open source. Support both SOAP and REST endpoints out of the box. Focus on performance, e.g. fastest text serializers in .NET, ...


7

Using WCF has both advantages and disadvantages compared to direct socket programming. The main advantage is that you do not need to care about programming a server loop or communication protocol. You split your communication into function/method calls, include these functions/methods in your contract interface, create a class that implements it, ...


7

These are probably the requirements to use the software (such as samples) included on the DVD with the book or if WCF was ever to be distributed on DVD. It is also likely to be a copy and paste error.


6

Nothing. You're still free to use WCF where it is most suitable, or at your own discretion. ASP.NET MVC has supported a RESTful communication style since its inception, and many people use it as a thin veneer for RESTful services. That doesn't automatically cause WCF to go obsolete, or make ASP.NET MVC the One Tool to Rule Them All™. This is why ...


6

Just to follow-up and close out the post, with Preview 5, the WCF Web API took a huge leap forward making it incredibly simple to create REST APIs. And while the current codebase on Codeplex does not include a Silverlight client, there is a toolkit out there and I was able to easily strip out the Async-CTP parts from the open source code and create a SL ...


6

By leveraging the Windows Communications Foundation framework, you can create services over a number of different network protocols. This includes HTTP, HTTPS, MSMQ, and even TCP/IP sockets. In addition to these, it also support Named Pipes for connections between two processes on the same machine. IIS can host applications developed for WCF, even if they ...


6

I was asking myself the same question until I found this WCF and ASP.NET Web API comparison page on MSDN (with my own emphasis below): Use WCF to create reliable, secure web services that accessible over a variety of transports. Use ASP.NET Web API to create HTTP-based services that are accessible from a wide variety of clients. Use ASP.NET Web API ...


6

Having a separate business tier needs justification as it involves lots more work and costs more in performance (see: MS-Business Layer). According to one definition of Web Services, a Web Service is not generally required unless you are communicating between different physical tiers. Accordingly, a DLL may fit best for what you describe. It is common to use ...


5

You will need to write two separate parts: the service back end (which has no GUI) and the front end controller (the GUI). They will need to communicate using some form of windows interprocess communication. Doing this as a single application may be possible, but in the windows service case it would have no GUI so still need a separate one. If you are ...


5

I have had to implement a chat service in WCF. The main problem in my eyes was that web services are based on the HTTP query model. That means a client sends a request to the server, the server handles the request and returns the results. Communication is always coming from the client side, but never from the server side. In a chat scenario, this implies ...


5

What should I do now? How do I manage this debate in a constructive way? First, keep subjectivity away. In your WebAPI team's arguments, I find "Web API is just the modern way"*, "WCF models are not POCO, because of those attributes" and "SOAP is not as readable and handy as JSON" pretty opinionated, if not plain wrong, and will not help make a decision. ...


5

Patterns Abstract Details, not Vice Versa The clients will behave as "slaves", that is, they will only connect to server and from then on, only the server communicates with them. Eventually the server may request that the clients send "data streams ... MVC and MVP, ... don't seem to be designed to fulfill my specific requirements." I'm getting the ...


Only top voted, non community-wiki answers of a minimum length are eligible