Hello every body
i have developed a wcf app using .net framework 4.0,
i have not problem with it and it is working without error in my local machine.
but i changed the machine and deploye it in a server that has rooted IIS (with public IP).
public interface IOssServices
{
[OperationContract]
[WebGet(UriTemplate = "GetPlates",
BodyStyle = WebMessageBodyStyle.WrappedRequest,
ResponseFormat = WebMessageFormat.Json,
RequestFormat = WebMessageFormat.Json)]
IList<string> GetPlates();
[OperationContract]
[WebGet(UriTemplate = "GetTasks",
BodyStyle = WebMessageBodyStyle.WrappedRequest,
ResponseFormat = WebMessageFormat.Json,
RequestFormat = WebMessageFormat.Json)]
OssResponeMessage GetTasks();
[OperationContract]
[WebInvoke(Method = "POST",
UriTemplate = "Login",
BodyStyle = WebMessageBodyStyle.WrappedRequest,
ResponseFormat = WebMessageFormat.Json,
RequestFormat = WebMessageFormat.Json)]
OssResponeMessage Login(OssRequestMessage request);
[OperationContract]
[WebInvoke(Method = "POST",
UriTemplate = "GetTaskDetail",
BodyStyle = WebMessageBodyStyle.WrappedRequest,
ResponseFormat = WebMessageFormat.Json,
RequestFormat = WebMessageFormat.Json)]
OssResponeMessage GetTaskDetail(OssRequestMessage request);
}
calling each of this operations and my local pc will not face error but in server and by an ip gives me error except the
GetPlates
operation. i mean that only this operation works fine either in my pc or server.
this is my web.config
<system.serviceModel>
<behaviors>
<endpointBehaviors>
<behavior name="httpBehavior">
<webHttp />
</behavior>
</endpointBehaviors>
<serviceBehaviors>
<behavior name="">
<serviceMetadata httpGetEnabled="true" />
<serviceDebug includeExceptionDetailInFaults="false" />
</behavior>
</serviceBehaviors>
</behaviors>
<serviceHostingEnvironment multipleSiteBindingsEnabled="true" />
<services>
<service name="JooyaServices.OssServices">
<endpoint address=""
behaviorConfiguration="httpBehavior"
binding="webHttpBinding"
contract="JooyaServices.IOssServices" />
</service>
<service name="JooyaServices.TrackingServices">
<endpoint address=""
behaviorConfiguration="httpBehavior"
binding="webHttpBinding"
contract="JooyaServices.ITrackingServices" />
</service>
</services>
</system.serviceModel>
calling the method causes error in iis and this is the event log output:
WebHost failed to process a request.
Sender Information: System.ServiceModel.Activation.HostedHttpRequestAsyncResult/39508813
Exception: System.Web.HttpException (0x80004005): There was no channel actively listening at 'http://OssServer.local:16025/OssServices.svc/GetTasks'. This is often caused by an incorrect address URI. Ensure that the address to which the message is sent matches an address on which a service is listening. --->
System.ServiceModel.EndpointNotFoundException: There was no channel actively listening at 'http://OssServer.local:16025/OssServices.svc/GetTasks'. This is often caused by an incorrect address URI. Ensure that the address to which the message is sent matches an address on which a service is listening.
at System.ServiceModel.Activation.HostedHttpTransportManager.HttpContextReceived(HostedHttpRequestAsyncResult result)
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.HandleRequest()
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.BeginRequest()
at System.Runtime.AsyncResult.End[TAsyncResult](IAsyncResult result)
at System.ServiceModel.Activation.HostedHttpRequestAsyncResult.End(IAsyncResult result)
Process Name: w3wp
Process ID: 7560
anybody know why this happend and how can i use my services ?
tanx in advance.
sorry for weak english.