在wcf中找不到端点获取方法,但在Post方法中确定

问题描述:

我有wcf rest服务。在wcf中找不到端点获取方法,但在Post方法中确定

我写了POST方法和GET方法。 都工作良好,直到几天,但突然邮政工作正常,但所有的Get方法返回“未找到端点”。 我已经检查了几百万次Url模板,但一切正常。 这里是我的代码:

[OperationContract] 
    [WebInvoke(Method = "POST", RequestFormat = WebMessageFormat.Json,ResponseFormat = WebMessageFormat.Json, BodyStyle = WebMessageBodyStyle.Bare, UriTemplate = "AddActivities")] 
    AddActivitiesResponse AddActivities(List<Activity> activities); 

    [OperationContract] 
    [WebInvoke(Method = "GET", RequestFormat = WebMessageFormat.Json, ResponseFormat = WebMessageFormat.Json, BodyStyle = WebMessageBodyStyle.Bare, UriTemplate = "GetGeoLocation/{fullAddress}/{account}")] 
    GetGeoLocationResponse GetGeoLocation(string fullAddress, string account); 

对不起,我的错。我请求了错误的URL tempalte。我发送GetGeoLocation?fullAddress = NY 但我应该发送GetGeoLocation/NY