You are viewing limited content. For full access, please sign in.

Question

Question

Adding WF Web Service Reference to Visual Studio project fails

asked on June 10

We had a customer recently upgrade from LF 10.2 to LF 11.  During the upgrade they also moved to a new server.  They have several VS projects that use the /Workflow/api/ web services and since the server move, they have to update their projects to the new server.  Originally, they got an error that the authentication was invalid because anonymous authentication was disabled.  The enabled anonymous authentication and then they get an error that the "Metadata contains a reference that cannot be resolved: 'http://workflowserver/Workflow/api/RestWorkflowAPI.svc'.".  I tested on my Demo system and get the same errors.  Originally, I got the error for anonymous authentication and then after enabling it in IIS, I get the same error about the reference cannot be resolved.  Below are screenshots from my Demo machine of the config and the error.

The HTML document does not contain Web service discovery information.
Metadata contains a reference that cannot be resolved: 'http://desktop-a5ti2dh/Workflow/api/RestWorkflowAPI.svc'.
The content type text/html; charset=utf-8 of the response message does not match the content type of the binding (application/soap+xml; charset=utf-8). If using a custom encoder, be sure that the IsContentTypeSupported method is implemented properly. The first 1024 bytes of the response were: '<!DOCTYPE html> <!--[if !(IE 6) | !(IE 7) | !(IE 8)  ]><!--><html lang=en-US class=no-js> <!--<![endif]--><head><link rel=stylesheet href=https://www.laserfiche.com/wp-content/cache/minify/a1063.default.include.f26483.css media=all> <script type=application/ld+json>{"@context":"https://schema.org","@type":"WebSite","url":"https://www.laserfiche.com/","potentialAction":{"@type":"SearchAction","target":"https://www.laserfiche.com/Search/Index?q={search_term_string}","query-input":"required name=search_term_string"}}</script> <meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=0"><meta name="theme-color" content="#e35205"><link rel=profile href=https://gmpg.org/xfn/11> <script>if(/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)){var originalAddEventListener=EventTarget.prototype.addEventListener,oldWidth=window.innerWidth;EventTarget.prototype.addEventListener=function(eventName,eventHandler,useCapture)'.
If the service is defined in the current solution, try building the solution and adding the service reference again.

 

0 0

Replies

replied on June 11

Is your project targeting .Net 4.8? Are there any IIS redirects possibly getting in the way?

Could you open a support case and attach a log of failed requests from IIS so we can get a better idea of what's going on?

0 0
replied on June 11

The program is targeting .NET 4.7.2.

I did not add any redirects, so if there are any redirects, they are coming from the Workflow API site.

I added and turned on IIS Failed Request Tracing

I rebooted the PC just to be sure, but after trying to add the Service Reference to the VS project and getting the error, there is no file created for the failed request tracing.

The standard IIS log contains the following:

#Software: Microsoft Internet Information Services 10.0
#Version: 1.0
#Date: 2021-06-11 17:24:06
#Fields: date time s-ip cs-method cs-uri-stem cs-uri-query s-port cs-username c-ip cs(User-Agent) cs(Referer) sc-status sc-substatus sc-win32-status time-taken
2021-06-11 17:24:06 fe80::51f0:cd9a:7aea:51e6%14 POST /workflow/api/RestWorkflowAPI.svc - 80 - fe80::51f0:cd9a:7aea:51e6%14 - - 405 0 1 12
2021-06-11 17:24:06 fe80::51f0:cd9a:7aea:51e6%14 GET /Workflow/Home/BrowserSuggestion - 80 - fe80::51f0:cd9a:7aea:51e6%14 Mozilla/4.0+(compatible;+MSIE+6.0;+MS+Web+Services+Client+Protocol+4.0.30319.42000) - 200 0 0 496
2021-06-11 17:24:06 fe80::51f0:cd9a:7aea:51e6%14 GET /Workflow/Home/BrowserSuggestion - 80 - fe80::51f0:cd9a:7aea:51e6%14 Mozilla/4.0+(compatible;+MSIE+6.0;+MS+Web+Services+Client+Protocol+4.0.30319.42000) - 200 0 0 483
2021-06-11 17:24:06 fe80::51f0:cd9a:7aea:51e6%14 POST /workflow/api/RestWorkflowAPI.svc/mex - 80 - fe80::51f0:cd9a:7aea:51e6%14 - - 404 0 0 190

 

0 0
You are not allowed to follow up in this post.

Sign in to reply to this post.