500 errors when publishing website

Hello


I have been working on a project using Groupdocs.Annotations and everything works fine when debugging in VS2012 on the built in server. Today when publishing the website to the local IIS server I get errors when running the viewer.

The App_Data folder is there with a clean DB.sdf and file-sessions.json and the temp folder have been created. When I look at the console I get the following error messages (see screenshot):

screencast

Hope you can point me in the right direction.

Best regards
Robert Badi

Hello Robert,

We are sorry to hear that you have such issue. We need the additional details about this issue:
1. What project type are you using, WebForms or MVC? If WebForms, do you have all HTTP-handlers properly configured in the web.config file? If MVC, do you have “Groupdocs.Web.UI.Viewer.InitRoutes();” in the Gllobal.asax?
2. From the browser debug window, request/response scanner, you can find out more details about these errors. Switch to the “Network” tab, select one of the failed requests, open it, and tell us what info is present in the “Preview” or “Response” tab.
3. Which application pool mode are you using in the IIS? Classic or Integrated? Are you using Virtual Directory system for hosting your web-site?

Thanks and waiting additional details from you.

Hello Denis


To answer your questions:

1. We are using WebForms. I think I have all the handlers properly configured. I checked the ones listed here and as far as I can see everything listed is there. Please find a partial web-config file here.

2. I just get “This request has no response data available” and “This request has no preview available”.

3. I am using Classic mode. I am not sure what you mean with “virtual directory system”. I am just running this on a development laptop with a built in IIS Server with a number of sites that have virtual directories and applications. I am running this website as an application.

I hope this helps.

Best regards
Robert Badi

Hello again


I recorded a screencast (this time with voice! :smiley: ) to explain the situation using your own Demo version 1.5. I hope it helps resolving the issue:

http://screencast.com/t/5S0eI5iRh

Best regards
Robert Badi

Hello Robert,

Thank you for very detailed screencast with voice. Up to you no one has ever done that.

There might be several reasons.

1. I’ve checked your partial web.config. Need to be very careful there. For example, I see that HTTP-handler “GetFontHandler” is commented for classic mode while uncommented for integrated. There might be a situation when in MS Visual Studio you are using local IIS Express (I see from the screencast that you are using MS VS 2012) which uses system.webServer → handlers (because it works in Integrated pipeline mode by default) and all is good. And when using Classic pipeline mode in IIS then errors are raising.

2. Maybe the publishing process corrupts the web-site somehow. You need to check this out using the description below.
2.1. Make sure that web-site with Annotation is compiled and working well in MS Visual Studio, you can add the annotations to the document and then see them, e.g. all is good.
2.2. Copy the full project folder (not overall solution folder, but only a project folder “Groupdocs.Demo.Annotation.Webforms”) to the place where you stores web-sites for IIS. Just pure copy/paste like Ctrl+C/Ctrl+V.
2.3. Create a new website in the IIS and point out this folder as its root location.
2.4. Add “Full permission” access to whole folder, not only for the “App_Data”.
2.5. Specify application pool “classic mode” for this web-site.
2.6. Run a web-site and see what is happening.
2.7. If you see the same situation as before, then please change the application pool to the “Integrated mode” or specify another application pool which works in “Integrated mode”.
2.8. This actions allow us to narrow the list of probable reasons why GroupDocs.Annotation is not working in the IIS.

3. About “validate” attribute. You are absolutely right, the “validate” attribute is not allowed in the “system.webServer / handlers”, it should be present only in the “system.web / httpHandlers”: Adding Handlers . This is a little drawback in our demo project.

Hope that this will help. Please come back to us in any case, with any results. Thanks and sorry for such long reply.

Hello Denis


Thank you! The Demo and our website worked on IIS when we switched the AppPool to integrated mode and I commented out the httpHandlers section completely. Without commenting out I got an IIS error.

Robert Badi

Hello Robert,

Thank you for response. Unfortunately I don’t understand, your web-site and Annotation in particular started to work properly right after switching application pool to Integrated mode? That is very strange, because GroupDocs.Annotation for .NET supports the Classic mode too.

Can you please try to remove/comment all that you have inside “httpHandlers” section, and paste the code from the article “How to use GroupDocs Annotation for .NET in an ASP.NET Project”, item 8? Using Classic mode, of course.

Thanks.

Hello Denis


I tried this again with the Demo as you recommended but now I get 404 errors when I run the app pool in Classic mode (not 500 as before). When I run in integrated mode I get errors in the reference to the jquery files only and the viewer does not show (just the “loading” icon spinning around).

I am a bit at a loss why this is behaving this way now.

Regards
Robert Badi