wcf - Task based asynchronous operation disabled in PCL Service Reference setting

I'm currently building a Xamarin based mobile application. For that project, I have created a PCL project with framework 4.5. I'm using VS 2013 as the development IDE. Now I want add a WCF service reference to this PCL. While adding service reference to this PCL project, I noticed that generation of asynchronous operation is disabled. Please check the image for more detail.I added the BCL.Async package via Nuget to the project. But still I can't access the Task based operation from the radiobutton list (its disabled).So is there any way to gene...Read more

Actual difference b/w WCF and REST in a client perspective

What is the actual difference b/w WCF vs REST service in a client perspective?I’m aware the following differenceWCF Support Multiple Transportation protocols, Hosting, WS-* Features and based on SOAP Message, etc.REST service based on URI’s with HTTP verbs, JSON/XML formats and Hypermedia as State Management, No need of WSDL documents etc.I can easily consume a WCF service from JavaScript client by using JQUERY like “Service Name/Method Name” with JSON DATA , I never faced any complication in regards to SOAP messages, so I think this applicable...Read more

WCF access through script manager

Question: 1I am a beginner to WCF , I have taken a web application and hosted on IIS(with some port(250) and added a new WCF file, added an operation contract and tried to call the WCF service from the client web app through javascript, i was not able to get the jsdebug file itself to check wheteher proxy is created or not.But when i add an new AjaxEnabledWCF file and added an operation contract and tried to call the WCF service from the client web app through javascript, i was able to get the jsdebug file, i am able to get the proxy object.In ...Read more

wcf - ContractFilter mismatch at the EndpointDispatcher exception

I have the following scenario that I'm trying to test for:A common WSDLWCF endpoint that implements objects based on the WSDL and is hosted in IIS.A client app that uses a proxy based off the WSDL to create requests. When I make a web service call from the client to the service endpoint, I get the following exception: {"The message with Action 'http://IMyService/CreateContainer' cannot be processed at the receiver, due to a ContractFilter mismatch at the EndpointDispatcher. This may be because of either a contract mismatch (mismatched Action...Read more

wcf - Is List<T> is serializable by default when T is serializable?

there is a data contract (say, EmployeeView) in my WCF service. I have decorated it with Serializable attribute, and all members are marked as DataMemberA method in the WCF is returning List<EmployeeView>.When I execute this method through WCF Test client or MVC app, it gets executed successfully, but while transferring result it is giving an error of The underlying connection was closed: The connection was closed unexpectedly. Is List<EmployeeView> not serialized though EmployeeView is marked as serialized?Further to add, if I exec...Read more

dependency injection - Decorate a WCF service with Autofac

I want to decorate WCF service with the following setup: SVC definition<%@ ServiceHost Language="C#" Debug="true" Service="Foo.IBarService, Foo" Factory="Autofac.Integration.Wcf.AutofacServiceHostFactory, Autofac.Integration.Wcf"%>Autofac registrationbuilder.RegisterType<FooService>().Named<IFooService>("fooservice");builder.RegisterType<LogFooService>().Named<IFooService>("logfooservice");builder .RegisterDecorator<IFooService>( (context, inner) => context.ResolveNamed<IFooService>(...Read more

wcf - Best Practices for securing a REST API / web service

When designing a REST API or service are there any established best practices for dealing with security (Authentication, Authorization, Identity Management) ?When building a SOAP API you have WS-Security as a guide and much literature exists on the topic. I have found less information about securing REST endpoints.While I understand REST intentionally does not have specifications analogous to WS-* I am hoping best practices or recommended patterns have emerged.Any discussion or links to relevant documents would be very much appreciated.If it ma...Read more

What are the differences between WCF and ASMX web services?

I am totally confused between WCF and ASMX web services. I have used a lot of web services in my earlier stage, and now there is this new thing introduced called WCF. I can still create WCF that function as a web service. I think there will be more stuff in WCF. What are the differences between WCF and Web services? When should each one be used?...Read more

Long communication time of WCF Web Services within the same server

Even if this question is a year old, I am still searching a good answer for this question. I appreciate any information that will lead me to fully understand this issue regarding low performances of communicating web services hosted on the same machine.I am currently developing a system with several WCF Web Services that communicate intensively.They are running under IIS7, on the same machine, each service being in a different Application Pool, with multiple workers in the Web Garden.During the individual evaluation of each Web Service, I can s...Read more

Powershell: Error consuming WCF services with MTOM message encoding

I'm currently exploring powershell capabilities, but I have encountered a problem that I have not been able to solve. Any quick tips would be greatly appreciated =)My goal:Invoke methods from a WCF service (configured with MTOM message encoding) from powershell v2.0 (hopefully using the new-webserviceproxy cmdlet)My problem:the new-webserviceproxy cmdlet cannot parse the service's response correctly when message encoding is set to Mtom. I receive the following error:PowerShell: $proxyObject = New-WebServiceProxy -URI "http://myserver.com/Acc...Read more

VSTS: Different Config Files (WCF endpoint addresses) for different environments using RM

I have different projects that are consuming many WCF services. I am using VSTS to automate deployments. Those services target different URLs (endpoint addresses) based on the environment where they are going to be deployed.I am trying to use web deploy with VSTS release management as suggested in this link:WebDeploy with VSTS, which proposes to create:Parmeters.xmlThen, add new task "Replace Tokens" with the specified variable for each environment.However, i don't guess this will work for me, because it generate tokens only for app settings ke...Read more