App URL setting broken for .NET Core 2.0 projects in Visual Studio 2017 15.5.0 - visual-studio-2017

I recently upgraded Visual Studio 2017 to version 15.5.0 and later on to 15.5.1.
So far everything was working fine developing .NET Core (2.0) web apis but after the updates the problems started. The problems occur on existing projects as well as newly created ones.
Problems:
Sometimes I receive the error message:
Unable to start process C:\Program Files\dotnet\dotnet.exe. The web server request failed with status code 500, Internal Server Error. The full response has written to C:\Users\username\AppData\Local\Temp\HttpFailure_04-01-08.html
This hidden directory is a great place to store error files by the way.
If i look into that file I can read:
HTTP Error 500.19 - Internal Server Error
Module: IIS Web Core
Notification: Begin Request
Error Code: 0x800700b7
Configuration file: \?\C:\solution\project\web.config
configuration source
<handler>
<add name="aspNetCore" path="*" verb="*" module="AspNetCoreModule" resourceType="Unspecified" />
</handler>
It seems to automatically add the add-tag on start even when I delete it.
So far, deleting the .vs directory up and on seemed to help against this but this shouldn't be a permanent solution.
The second (and more blocking problem) that occured is that the APP URL setting seems to be broken somehow.
For testing this bug I created a new Web API project (with the values controller) and added and configured swashbuckle.AspNetCore to show the UI for the ValuesController.
The default route for the values controller is api/values.
When I now configure the App URL settings in the project properties to start at http://localhost:50000/swagger the browser opens and shows the wrong url, namely http://localhost:50000/swagger/api/values with the correct response of the ValuesController but not the swagger ui. At this point it shouldn't have the extension /api/values since it is not configured and I don't know why or where this is added (it's not in the configuration).
If I now enter (without stopping the app) http://localhost:50000/swagger I start receiving 404 errors an urls, even on http://localhost:50000/api/values.
Anyone else having this problem?
Anyone knows a fix for that?
Anyone knowing what is happening there and what the problem could be?

Related

Error occurred while generating PDF in Coldfusion using cfhtmltopdf

I am getting the following error using cfhtmltopdf:
Error occurred while generating PDF. Reason: PDF conversion is failed due to timeout. Increase the timeout value in PDFgService manager settings.
According to these docs (see "Configuring the PDF service manager"), I should be able to tweek the PDF Service Settings in the web.xml file:
https://helpx.adobe.com/coldfusion/pdf-generation-in-coldfusion.html
On Production, I am able to find the file and make these changes. It is located here:
//jetty/webapps/PDFgServlet/WEB-INF/.
However, locally, using CF2018 Developer Edition using IIS Server Mode, I cannot find any reference to any PDF service settings in any of the web.xml files in my CF directories. This folder also does not exist: //jetty/webapps/PDFgServlet/WEB-INF/.
I did find locally this folder:
C:\ColdFusion2018\cfusion\hf-updates\hf-2018-00003-314033\jetty\webapps\PDFgServlet\WEB-INF
There was no web.xml file there though, and adding one in with the settings had no effect (after restarting CF).
So I'd like to know how does one change these PDF settings in a local/development environment like this, like I was able to do on Production, in order to further debug this error I am getting.
UPDATE: We have logged the underlying issue with Adobe: https://tracker.adobe.com/#/view/CF-4208624

WSO2 ESB: Getting Dead Pages When Running in Windows Service

I'm getting blank pages when navigating the WSO2 ESB-4.9.0 management console. For example, the registry, templates, endpoints, and local entries pages are all blank when navigating to them in the console UI.
I've found the following errors in the logs:
Error during rendering
IO Error executing tag: JSPException while including path '/templates/list_templates.jsp'. ServletException while including page.
The ESB is running in a YAJSW Windows Service. I should note that the ESB runs fine when running straight from the command line, it's just when using the service wrapper.
Strainy
Since you mentioned that the ESB starts as a window service, in carbon 4.4.x, default wrapper.conf file needs to be updated with following additional entries.
wrapper.java.additional.26 = -Dwso2.carbon.xml=${carbon_home}\\repository\\conf\\carbon.xml
wrapper.java.additional.27 = -Dwso2.registry.xml=${carbon_home}\\repository\\conf\\registry.xml
wrapper.java.additional.28 = -Dwso2.user.mgt.xml=${carbon_home}\\repository\\conf\\user-mgt.xml
wrapper.java.additional.29 = -Dwso2.transports.xml=${carbon_home}\\repository\\conf\\mgt-transports.xml
wrapper.java.additional.31 = -Dorg.apache.jasper.compiler.Parser.STRICT_QUOTE_ESCAPING=false
wrapper.java.additional.33 = -Dfile.encoding=UTF8
You can verify these configurations in wrapper.conf and these configurations may help you to solve the jsp error.
Following link may help you if you need more information regarding this.
https://docs.wso2.com/display/ESB490/Installing+as+a+Windows+Service#InstallingasaWindowsService-SettinguptheYAJSWwrapperconfigurationfile
I just used the NSSM - the "Non-Sucking Service Manager".
It's actually amazingly simple to install a Service using this tool.
https://nssm.cc
Just set it up to point at the wso2server.bat file
Keeping an eye on this issue however: https://wso2.org/jira/browse/ESBJAVA-4342

Azure Web Site with Django 500 Error

I've spent over 8 hours trying to get this Django site up and running on an Azure Website. I've nearly thrown in the towel would really appreciate some help.
So far I have tried numerous methods and followed different tutorials, but they have all yielded the same result. Here is the most recent tutorial I have followed: http://www.windowsazure.com/en-us/develop/python/tutorials/web-sites-with-django/
Now that my site is "up", I am seeing a 500 error for all requests. Here is the error in the log:
The page cannot be displayed because an internal server error has occurred.
Most likely causes:
IIS received the request; however, an internal error occurred during
the processing of the request. The root cause of this error depends on which mo
dule handles the request and what was happening in the worker process when this
error occurred. IIS was not able to access the web.config file for t
he Web site or application. This can occur if the NTFS permissions are set incor
rectly. IIS was not able to process configuration for the Web site o
r application. The authenticated user does not have permission to u
se this DLL. The request is mapped to a managed handler but the .
NET Extensibility Feature is not installed.
Things you can try:
Ensure that the NTFS permissions for the web.config file are correct
and allow access to the Web server's machine account. Check the ev
ent logs to see if any additional information was logged. Verify the p
ermissions for the DLL. Install the .NET Extensibility feature if th
e request is mapped to a managed handler. Create a tracing rule to tra
ck failed requests for this HTTP status code. For more information about creatin
g a tracing rule for failed requests, click here.
Please help!
I got it working by settings up a new django project from the azure gallery and changed some configs and such.
Edit: The configs I updated was just the name of my app. In my case I also updated the database config with the database I wanted to use in settings.py.
The lesson learned from this is that it is easier to initialize the app from Azure's "Create from gallery" feature, and then pull down the source and modify it via ftp or git to achieve the desired project structure/naming.

Maven User-Agent property and pluginRepository

What I want
To get this guide to work
http://blog.bigpixel.ro/2012/07/building-cc-applications-with-maven/
The Error
I'm running into into troubles with a HTTP 500 error code, which is as follows:
[ERROR] Unresolveable build extension: Plugin org.apache.maven.plugins:maven-nar-plugin:2.1-SNAPSHOT or one of its dependencies could not be resolved: Failed to collect dependencies for org.apache.maven.plugins:maven-nar-plugin:jar:2.1-SNAPSHOT (): Failed to read artifact descriptor for org.apache.maven.plugins:maven-nar-plugin:jar:2.1-SNAPSHOT: Could not transfer artifact org.apache.maven.plugins:maven-nar-plugin:pom:2.1-SNAPSHOT from/to Duns maven snapshot (http://duns.github.com/maven-snapshots/): Failed to transfer file: http://duns.github.com/maven-snapshots/org/apache/maven/plugins/maven-nar-plugin/2.1-SNAPSHOT/maven-nar-plugin-2.1-SNAPSHOT.pom. Return code is: 500, ReasonPhrase:( The request was rejected by the HTTP filter. Contact your Forefront TMG administrator. ). -> [Help 2]
What I've tried
I started with the 'maven getting started in 5 minutes' tutorial. This didn't go smoothly as I ran into a 500 HTTP error because of forefront that's implemented on my current network. I managed to get around this by setting the User Agent string property within my settings.xml.
<servers>
<server>
<id>central</id>
<configuration>
<httpHeaders>
<property>
<name>User-Agent</name>
<value>Mozilla/5.0 (compatible; MSIE 8.0; Windows NT 6.0; Trident/4.0; InfoPath.1; SV1; .NET CLR 3.8.36217; WOW64; en-US)</value>
</property>
</httpHeaders>
</configuration>
</server>
</servers>
This worked and I was able to get maven working for java projects.
I would have thought that that would be the end of the HTTP 500 errors but I'm still getting them whenever I try to pull plugins from a new pluginRepository.
I've followed the guide linked at top with one exception. Instead of putting the pluginRepository in the pom.xml in the parent folder, I put it into a profile within my settings.xml file. I did first try putting in the pom.xml but later pulled it out in the hopes that it would fix it.
Is there something within maven that is not honouring this User-Agent string that I've specified? Why does it work for the maven 5 minute tutorial and not for anything else?
Any help would be greatly appreciated. Thanks!
Figured it out.
Turns out I had to make another server entry for each of the plugin repositories I wanted maven to user the custom User-Agent string for by targetting the ID of the pluginRepository in the tags.
Now if only there was some way to apply the user-agent string to all future defined pluginrepositories
edit: Following up, I couldn't find a way within maven to apply the user-agent string to all pluginrepository configurations. I've come up with a work around that involves Squid as a proxy that replaces the User-Agent property in outgoing http requests with a custom defined one and configured maven to use that proxy. It works perfectly.

recieving error The file you are attempting to save or retrieve has been blocked from this Web site by the server administrators.<nativehr>0x800401e6

After building and deploying, checked the solution management from Central administration and it's up, a simple web service method that only created a Document Library list with a few columns when trying to retrieve the wsdl or even just by calling the WS fromt the adress since its a void method I recieve some error:
The file you are attempting to save or retrieve has been blocked from this Web site by the server administrators.<nativehr>0x800401e6</nativehr><nativestack></nativestack>
The very same method runs fine when called from another web service project that is already deployed so there's nothing wrong with the code. I'm most probably doing something wrong but can't figure.
The system is running on a win server 2008 with sharepoint 2010, framework 3.5 and "ANY" cpu mode.
thank you!
[edit]
Managed to get rid of the previous error by removing asmx extention from the blocked file list in central administration now instead I'm recieving a 404 error:
The resource cannot be found.
Description: HTTP 404. The resource you are looking for (or one of its dependencies) could have been removed, had its name changed, or is temporarily unavailable. Please review the following URL and make sure that it is spelled correctly.
Requested URL: /_layouts1/my2claims/tt_claims.asmx
it must run under the same application pool as SharePoint