0
votes

I am facing error while receiving response on my production environment. but same method is working fine on test environment.

An error occurred while receiving the HTTP response to http://localhost:54544/Services/XXX.svc. This could be due to the service endpoint binding not using the HTTP protocol. This could also be due to an HTTP request context being aborted by the server (possibly due to the service shutting down). See server logs for more details.

If I use test db server on production then it runs perfectly fine

stack trace of full error is

Server stack trace: at System.ServiceModel.Channels.HttpChannelUtilities.ProcessGetResponseWebException(WebException webException, HttpWebRequest request, HttpAbortReason abortReason)
at System.ServiceModel.Channels.HttpChannelFactory`1.HttpRequestChannel.HttpChannelRequest.WaitForReply(TimeSpan timeout) at System.ServiceModel.Channels.RequestChannel.Request(Message message, TimeSpan timeout) at System.ServiceModel.Dispatcher.RequestChannelBinder.Request(Message message, TimeSpan timeout) at System.ServiceModel.Channels.ServiceChannel.Call(String action, Boolean oneway, ProxyOperationRuntime operation, Object[] ins, Object[] outs, TimeSpan timeout) at System.ServiceModel.Channels.ServiceChannelProxy.InvokeService(IMethodCallMessage methodCall, ProxyOperationRuntime operation) at System.ServiceModel.Channels.ServiceChannelProxy.Invoke(IMessage message)

Exception rethrown at [0]: at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg) at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type) at Common.Infrastructure.Impl.SubService.ISubscription.GetProductLicensesByUser(String userId) at Common.Infrastructure.Impl.X.Y.Z(String userId) in C:\Users\XXX\Source\Repos\XXX\Src\Common.Infrastructure.Impl\Service References\XXXX\Reference.cs:line 10303 at Common.Infrastructure.Impl.X.Y(String userGuid) in C:\Users\XXXX\Source\Repos\XXX\XXXX\Common.Infrastructure.Impl\X.cs:line 1286 at Common.Infrastructure.Impl.X.Y(String userGuid) in C:\Users\XXXX\Source\Repos\XX\XX\Common.Infrastructure.Impl\XX.cs:line 1274

1
your problem is server-side, not client side. You need to find the serverside exception logging. See also: stackoverflow.com/questions/5870958/…. There are various causes mentioned in that post, eliminate them one by one.rene
Enable Message logging and tracing on server side and also set IncludeSaoapFaultException to true and check the logs.Hameed Syed
Solved by check in log of wcfImran Ahmad Shahid

1 Answers

1
votes

Solved by check in log of WCF services

The problem is that I have an Enum and i was storing enum value in database. now index of that Enum has been changed so when i am getting value from database and translate database value to Enum again it gives me an error. and on test environment all database values has mapping in Enum that's why on test environment it doesn't raise an error while fetching records.