cloudfoundry-attic / windows_app_lifecycle

Apache License 2.0
8 stars 13 forks source link

asp.net-3.5 framework does not exist #5

Closed ishwarps closed 7 years ago

ishwarps commented 7 years ago

Hi, I have developed the sample application on asp.net framework-3.5. after pushing the application on cloud foundry. it is giving an error("The page cannot be displayed because an internal server error has occurred."). After debugging, I come to know that there is no asp.net framework 3.5 exist So I have installed the asp.net framework 3.5 manually on window machine. I try to modified Web.config file base on your reference file applicationhost.config.

but i am not able to find the webengine.dll file on asp.net framework-3.5 which is required for the configuring the following lines on Web.config

I have following questions. 1)why asp.net framework-3.5 does not exist on applicationhost.conf file. 2)if i want to add asp.net framework-3.5, is there any guideline.

cf-gitbot commented 7 years ago

We have created an issue in Pivotal Tracker to manage this:

https://www.pivotaltracker.com/story/show/142139221

The labels on this github issue will be updated when the story is started.

mdelillo commented 7 years ago

Hi @ishwar1987,

We only support .NET framework 4.5 and above. The WebAppServer is built with version 4.5 and will likely not with with version 3.5.

ishwarps commented 7 years ago

Hi @mdelillo ,

Here https://docs.pivotal.io/pivotalcf/1-7/opsguide/deploying-diego.html, http://cloud.rohitkelapure.com/2016/06/replatforming-net-applications-to-cloud.html They have mention that "Twelve-factor ASP.NET MVC apps compiled against .NET 3.5+ were tested most extensively".

So how its working, if its working then is there any guide line to support .net framework 3.5?

mdelillo commented 7 years ago

Hi @ishwar1987,

The sample application that those docs are referencing is a .NET 4.5.1 app. In theory, a .NET 3.5 app will work as long as that framework is installed on the windows cell and your web.config targets that version. Does your app work outside of CF?

ishwarps commented 7 years ago

Hi @mdelillo, Yes. The sample application which i have developed is working on asp.net framework-3.5 locally. The sample application web.config is similar example here. https://www.lavinski.me/example-web-config-files-3-5-and-4-5/.

Even i have tested, After manually installed the asp.net framework 3.5. after that also not working. As mention here https://www.lavinski.me/example-web-config-files-3-5-and-4-5/ , The web.confi is it right?

if not then if you have sample web.config for asp.net framework-3.5. can you provides.

ishwarps commented 7 years ago

Hi, After RDP on window-cell. I have manually installed the asp.net framework 3.5. And i have registered asp.net 3.5 framework. Then I have tested the sample application with web.config for asp.net framework 3.5 and asp.net framework 4.1. The both are working.

But with same web.config file of asp.net framework 3.5. after pushing on cloud foundry. its giving an following error

"The page cannot be displayed because an internal server error has occurred."

For troubleshooting this error. I check the event-viewer log. but did not get any information. I have use the web.config file which is given example here. https://www.lavinski.me/example-web-config-files-3-5-and-4-5/.

Any idea how to troubleshoot this error?

aminjam commented 7 years ago

@ishwar1987 It sounds like the web.config for 3.5 might include DLLs that is not present in the Windows cell. Looking at the web.config, there are a few things that pops out:

It sounds like your apps is pushed successfully, so I would look at the cf logs for your app for an error message.

ishwarps commented 7 years ago

HI @aminjam , The same web.config file is working after testing from window cell locally on asp.net framework 3.5.

The cf logs app-name giving following output:

OUT demoservice-3-1-2.test.com - [23/03/2017:17:58:59.193 +0000] "GET / HTTP/1.1" 500 0 75 "-" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36" "xxxx" "10.1.16.221:65344" x_forwarded_for:"xxxxx" x_forwarded_proto:"http" vcap_request_id:"bdd94111-4855-4d3a-6292-42dab43012ef" response_time:0.002331067 app_id:"4e77a8fa-d169-4373-a9b8-ff77a6951566" app_index:"0" 2017-03-23T17:58:59.50+0000 [RTR/0] OUT demoservice-3-1-2.test.com - [23/03/2017:17:58:59.499 +0000] "GET /favicon.ico HTTP/1.1" 500 0 75 "http://demoservice-3-1-2.test.com/" "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36" "1xxxxx" "xxxx:65344" x_forwarded_for:"45.250.248.233" x_forwarded_proto:"http" vcap_request_id:"ae849013-0c10-4c6a-54bd-b9f3a39a90fd" response_time:0.002550045 app_id:"4e77a8fa-d169-4373-a9b8-ff77a6951566" app_index:"0"

Is there any way i can find-out why this error is coming?

ishwarps commented 7 years ago

After removing the asp.net framework-4 from window cell. After that pushing an application with any asp.net framework. its giving an following error.

"Error restarting application: NoCompatibleCell"

Look like .The windows_app_lifecycle service is not able to choose the asp.net framework at run time. its only working with asp.net framework-4. Which will be default with operating system.

aminjam commented 7 years ago

@ishwar1987 Our CI tests and verifies .NET Framework 4.x. When you see NoCompatibleCell, it's related to a failing healthcheck not the .NET Framework

ishwarps commented 7 years ago

@aminjam : Thanks for response. Finally i come to know that why the asp.net framework 3.5 is not working. As We have hard coded asp.net framework 4 values in https://github.com/cloudfoundry/windows_app_lifecycle/blob/d74e304120f9c9a86147500bf272c940e0cb9674/WebAppServer/Program.cs#L70. I am closing this ticket.