Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Cassini seems to lock an external process launched by the hosted ASP.NET application
johncullington
#1 Posted : Monday, November 1, 2010 8:19:41 AM(UTC)
Groups: Member
Joined: 4/22/2010(UTC)
Posts: 2

Hi

I have an ASP.NET application hosted by Cassini (running as a Windows service). This has a call to launch an external Windowed executable (asynchronously), in the usual way:

With process
.StartInfo.FileName = exeFilename
.StartInfo.Arguments = arguments
.StartInfo.WindowStyle = ProcessWindowStyle.Normal
.StartInfo.WorkingDirectory = sPath
.Start()
End With

The user then performs various actions in this external app, and then closes it down via the GUI (of the external app). They will then usually re-launch the same external application multiple times in the same session.

This all works fine on Windows XP/7, but we have had problems on some client VISTA (32 Bit) machines, whereby closing down the external application seems to leave the application running as a Windowless process, which means that the user cannot then re-launch the external application (as it is already running, albeit silently). We do not wish to have the process launch automatically kill any existing instance of the application.

We can terminate the external app process via Task Manager, but it seems that Cassini is in some way retaining a lock on the process when the external app is closed via its GUI (ie not by the hosted ASP.NET application from which it was initially launched).

We unfortunately cannot replicate this on our test VISTA box ....

Can anyone think of a reason why Cassini should be keeping locks on a process on specific VISTA boxes ?

Many thanks

John
Ultidev Team
#2 Posted : Monday, November 1, 2010 8:58:46 AM(UTC)
Ultidev Team

Groups: Administration
Joined: 11/3/2005(UTC)
Posts: 2,253

Thanks: 28 times
Was thanked: 60 time(s) in 59 post(s)
Hello, John.

It's a puzzler, and the biggest mystery for us is why launching an interactive UI app from a service is possible in the first place. We don't understand how a UI-less service can bring up a UI. What if there are multiple users logged in - how the service would know which user is supposed to see the UI, especially given that current version of Cassini does not support impersonation? Or if there are no users logged on, and a person uses a browser from another box to access the application - in this case the user won't see the interactive application because it will be launched on another box. But given that somehow it can be done and interactive UI application can be started from the service, it means that your clients will always have to work on the same machine where the server is, in which case you don't need (and probably don't want) to run the web server as a service. Instead you could just start UltiDevCassinWebServer2.exe with /run parameter, in which case you should be able to accomplish what you need.

We can't think of why the process would be held and not shut down. We are not sure that the process is held by Cassini - the process just as likely to fail to exit for some internal reason. If you have Visual Studio on the machine in question, you could attach debugger to the hanging process and hit Pause button to see where it's hanging.

Please let us know if this information was helpful.

Best regards,
UltiDev Team.
Please donate at http://www.ultidev.com/products/Donate.aspx to help us improve our products.
Rss Feed  Atom Feed
Users browsing this topic
Guest (3)
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You can vote in polls in this forum.