Kiliman's Korner

.NET, The Universe and Everything

My Links

Blog Stats

Archives

Post Categories

Links

CassiniEx v0.94.402 has been released!

New configuration changes to work more like IIS. Can also change configuration without restarting web server.

Includes sample configurations for Infragistics UltraWebGrid sample and ASP.NET Issue Tracker Starter Kit.

Also see a screen shot of the new CassiniEx Management Console coming soon!

http://www.systemex.net/CassiniEx/

Kiliman

posted on Friday, April 02, 2004 12:42 PM

Feedback

# re: CassiniEx v0.94.402 has been released! 4/3/2004 2:46 AM eric@ensoft-software.com

does CassiniEx support a more Apache like mapping?

ie, in Apache you can specify an .htaccess in a web folder that also seems to be able to specify a specific httpmodule to use for the directory, and so forth

I think that would be cool and would be interested in helping to implement it if so!

# re: CassiniEx v0.94.402 has been released! 4/4/2004 10:28 AM Kiliman

Hi Eric, if I understand you correctly, you want to be able to configure CassiniEx on a per-directory basis, instead of the centralized method we have now.

http://httpd.apache.org/docs/howto/htaccess.html

The main reason I wrote CassiniEx was so I could create multiple web sites on Windows XP. I've always considered CassiniEx to be a development tool, and that the actual web app would eventually be deployed to IIS.

Therefore, I've tried hard to make CassiniEx as similar to IIS as possible. Adding .htaccess-like support would make it difficult to deploy the app to IIS.

However, I also understand that there are some people who are looking at CassiniEx as an alternative to IIS, especially paired with Apache. If you have some ideas on how you would want to do this, feel free to send me your specifications.

Thanks.



# re: CassiniEx v0.94.402 has been released! 4/5/2004 1:37 AM Sean

If you want Apache features, use Apache.

# re: CassiniEx v0.94.402 has been released! 4/13/2004 10:26 AM Raymond

The performance for a Web Service is worse in comparison to the IIS. Cassini is about 200 ms slower than IIS for a simple request. You can improve this by passing a network stream, in stead of the HttpRequest through the different Application Domains. This can lead to a improvement of 170 ms per request.

Ik hope this can help you to improve the performance of CassiniEx

# re: CassiniEx v0.94.402 has been released! 4/13/2004 11:51 AM Kilman

Raymond, thanks for the feedback.

First of all, I haven't really concentrated on performance. My main goal is to first make sure it works.

I think it's kind of unfair to compare IIS and CassiniEx as they serve different purposes. IIS is a high-end web server designed with performance and scalability in mind. CassiniEx is meant to be a local development tool. Granted, the fact that CassiniEx is an order of magnitude slower is a concern, but I'm sure I can get those numbers down in future versions.

The default build of CassiniEx is a Debug build, so there's some overhead there. As for AppDomain marshalling, I have tried to minimize that as much as possible.

For any given request, there are only 2 AppDomains involved. The main AppDomain listens for client requests, then creates an HttpRequest object that encapsulates all the information required to process this request. If it is an ASP.NET request, then it passes it to the AspNetHost object which is in a different AppDomain. It then creates an AspNetWorkerRequest to actually process this request by handing it to the HttpRuntime.

The AspNetWorkerRequest calls the HttpRequest object to get some properties and to read and write from the open connection. If you notice, all of the writing done by the AspNetWorkerRequest is buffered. Only when the HttpRuntime calls FlushResponse() will a call be made to HttpRequest to send the response to the client.

Once I get CassiniEx to a more “feature-complete” stage, then I will concentrate on improving the performance. My primary concern right now is to complete the Management Console and the ability to run as a Windows Service.

Thanks again!

# Adventures with Cassini, HTTP.SYS, XPSP2 4/13/2004 4:11 PM Bryant Likes's Blog

# Adventures with Cassini, HTTP.SYS, XPSP2 4/13/2004 4:14 PM Bryant Likes's Blog

# re: CassiniEx v0.94.402 has been released! 4/24/2004 2:37 AM Artyom

I'm getting a strange thing happening with v0.94.402 - after building a simple VS.NET web service (you know, the one with [WebService] HelloWorld()), CassiniEx perfectly serves it out by the hostname:

http://aspnet/TestWebService2/Service1.asmx?op=HelloWorld

But the testing form on this page is not really linking to the "aspnet" hostname, but to 127.0.0.1 instead - and consequently, clicking Invoke button sends a request with

Host: 127.0.0.1

so CassiniEx can't find the right host to serve the things from and fails with 400 Bad Request.

Furthermore, even the WSDL served by

http://aspnet/TestWebService2/Service1.asmx?WSDL

is containing 127.0.0.1, and not the "aspnet" hostname - so testing web services with CassiniEx hadn't been much of a success lately :(

Is there a setting in Web.config I should tweak up so that web applications find out that they're requested and served by "aspnet" domain, and not by 127.0.0.1?

Thanks.

# re: CassiniEx v0.94.402 has been released! 4/27/2004 4:34 AM Suzhq

hehe,
when i test the CassiniEx,i found a funny error.:)
i dont know why, buy when i set any webapp or website's "Enable=True" or have any upcase char
,and restart the service,and it is down!
change back,and up again!
hehe ^^,
i think the CassiniEx is great.
i test the text,image and flash ,all is ok!
but i cant load any webapp that you have setted. :( and i test any Http://localhost/any.aspx is 500 fail!
plz tell me why?

# re: CassiniEx v0.94.402 has been released! 4/27/2004 12:09 PM Kiliman

Artyom: The reason why CassiniEx (and Cassini) returns the IP address instead of the host name is because there is a bug in the code :(

The AspNetWorkerRequest class does not override the method GetServerName(). The default implemention returns nothing, so the HttpRuntime uses LocalAddress as the value.

I've included the fix in my latest version of CassiniEx. In the meantime, just add this to AspNetWorkerRequest:

public override string GetServerName()
{
return _httpRequest.KnownRequestHeaders[HeaderHost];
}

Kiliman

# re: CassiniEx v0.94.402 has been released! 4/27/2004 12:22 PM Kiliman

Suzhq: The config files are read using XmlSerialization. Because the Enabled property is a Boolean, it expects the string value to be anything that is valid for Boolean.Parse() e.g. "true" or "false" and is not case-sensitive.

Your comment says you are using "Enable". I'm not sure if that's a typo in your comment, but the correct attribute is "Enabled".

If you're still having problems, send me a copy of your config files.

Kiliman

# re: CassiniEx v0.94.402 has been released! 4/27/2004 12:54 PM Kiliman

I found another bug. If you call a web service like this:

http://aspnet/WebService1/Service1.asmx/HelloWorld

The part after the Service1.asmx is called the PathInfo.

Unfortunately when CassiniEx translates this to the PhysicalPath, I called it with the UriPath instead of FilePath. So I was getting C:\Inetpub\wwwroot\WebService1\Service1.asmx\HelloWorld instead of C:\Inetpub\wwwroot\WebService1\Service1.asmx.

In HttpRequest.Process(), change this line:


// translate path to physical location
FilePathTranslated = MapPath(_uriPath);

to


// translate path to physical location
FilePathTranslated = MapPath(_filePath);

Kiliman

# re: CassiniEx v0.94.402 has been released! 4/29/2004 10:37 PM Battleace

keep up the good work.

# re: CassiniEx v0.94.402 has been released! 5/6/2004 8:19 AM Artyom

Thanks for the fix, Michael! I just thought that such a great software like CassiniEx should have its own website, or at least a forum to discuss the things etc, maybe even a CVS would be cool. How about opening a project on SourceForge for that? It has forum, a CVS rep for the sources (if you wish that) and is a good serving source to offload your own server from binary downloads.

# re: CassiniEx v0.94.402 has been released! 5/20/2004 12:03 AM Vadim

Hi everybody,
I have made all the changes you suggested to CassiniEx. Still I have a problem using Web Services in my VB.Net project. My Web Service has XMLInclude for user defined class it uses, and when it is invoked from the program, I am getting an error:
The request failed with HTTP status 400: Bad Request.
I've found in Web References\Reference.VB this:

<System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://devel/SiteBuilder/sbServices/TemplService/TemplCatListAll", RequestNamespace:="http://devel/SiteBuilder/sbServices/TemplService"">http://devel/SiteBuilder/sbServices/TemplService", ResponseNamespace:="http://devel/SiteBuilder/sbServices/TemplService"">http://devel/SiteBuilder/sbServices/TemplService", Use:=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle:=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)> _
Public Function TemplCatListAll() As ArrayListWrapper
Dim results() As Object = Me.Invoke("TemplCatListAll", New Object(-1) {})
Return CType(results(0),ArrayListWrapper)
End Function

and CassiniEx fails here. When I am invoking 'normal' Web Service (no user types), everything looks just fine.
Any ideas?
Thanks for your great job,
Vadim

# re: CassiniEx v0.94.402 has been released! 5/20/2004 8:06 AM Kiliman

Vadim, can you email me a copy of your project, or a simple subset that causes the error? This will help me to track down the problem.

In the meantime, there are only 3 places where status 400 is returned. If you look in HttpRequest.Process(), the first is if there's a problem reading all headers. The second is if isBadPath() returns true. And finally, if CassiniEx can't find a WebSite that matches the host header, or the web site is not enabled.

I'd first verify that the site itself works by placing a test page that you can call directly. Once you've verified that it works, then look in the web log to see what the URL is that returned the 400 error.

If that still doesn't narrow it down, then you might want to install Fiddler http://www.fiddlertool.com/fiddler/. This is an HTTP Debugging Proxy that will let you see what is being sent between the browser and server.

Good luck,
Kiliman

# re: CassiniEx v0.94.402 has been released! 5/20/2004 10:50 AM Vadim

Thanks Kiliman, now it is working perfectly. The problem was, I didn't notice that in Web refereces url somehow it was http://local... instead of http://my... I changed properties and it is working!
However, what about debugging? I'm working on XP Home, and when I ty to start debugging, I get a message: You do not have permissions, you have to be a member of Debuggers group.
Thank you again,
Vadim

# re: CassiniEx v0.94.402 has been released! 5/20/2004 3:23 PM Vadim

Well, when I attach CassiniEx as a debugger process, everything is ok. But is here any way not to do it every time after VS started?
Vadim

# re: CassiniEx v0.94.402 has been released! 5/20/2004 5:12 PM Kiliman

I created a macro to attach to CassiniEx. Unfortunately, you don't get a lot of control through the automation interface.

The main problem is that when you attach, you can't specify the "program type" so it enables Native debugging as well as CLR. This causes it to be really slow to start up.

The other problem is that I'm not able to detach from the running process. My macro fails, so I have to stop debugging which terminates CassiniEx :(

Maybe I can come up with a way to send the messages to the Debug Processes dialog to automate it.

If you're interested, here's the macro:

Sub AttachToCassiniEx()

' This function attached to CassiniExWebServer.exe if it is running.

Dim attached As Boolean = False

Dim proc As EnvDTE.Process
For Each proc In DTE.Debugger.LocalProcesses
Debug.WriteLine(proc.Name)
If proc.Name.ToLower().EndsWith("cassiniexwebserver.exe") Then
proc.Attach()
attached = True
Exit For
End If
Next

If attached = False Then
MsgBox("CassiniExWebServer.exe is not running")
End If

# re: CassiniEx v0.94.402 has been released! 5/26/2004 5:48 PM kevin white

I seem to be having problem getting CEx to use a different log folder. Here is the commandline string:

"C:\Program Files\Cassini Extended\CassiniExWebServer.exe" -config "C:\Documents and Settings\kwhite.BOEDEPARTNERS\Application Data\Cassini Extended Web Server Configurations" - log "C:\logs"

The logs folder already exists and the permissions are wide open. CEx loads and runs just fine. It just won't accept the alternate log path.

# re: CassiniEx v0.94.402 has been released! 6/1/2004 6:43 PM Pam

If I install CassiniEX v0.94.402 on my XP Home computer with the original Microsoft Cassini program already installed, will CassiniEx work? I'm having trouble getting Cassini Personal Server to work on my system, so I'm looking for other solutions. Can you help?
Thanks. And -- I think you're a really nice person to offer all this stuff!

# re: CassiniEx v0.94.402 has been released! 6/1/2004 6:46 PM Pam

Here's how to reach me.

# re: CassiniEx v0.94.402 has been released! 6/2/2004 8:08 AM Kiliman

CassiniEx will run on XP Home, but you must have .NET 1.1. If you don't have a dev tool like Web Matrix or VS.NET 2003, you will need the .NET Framework SDK.

Kiliman

# re: CassiniEx v0.94.402 has been released! 6/2/2004 1:55 PM Eyal

Regarding performance.
Raymond mentioned that "You can improve this by passing a network stream". Can you explain how\why will it improve performance? The network stream will still be created in the "main" AppDomain and all network calls will be redirected to it.

# re: CassiniEx v0.94.402 has been released! 6/8/2004 12:47 PM Rainer

a few days ago I found your cassiniex server on the net, thanks for your good work.
but there are some problems i can not solve.
- when cassiniex is running and i switch between the other running programs, I can see an icon of cassinex's main window, when I then switch to that task the mainwindow appears and never goes away, maybe you can check if there is a way to don't show the icon in the tasklist.
- the next issue maybe a appache config problem, but I don't know how to figure it out. I've apache running with 4 virtual host, erverything fine so far, how can I enable different asp.net pages to these virtual host?

rainer
rainer.massmann@epost.de

(btw, this is my first answer in a blog, can you explain me what to put in the fileds: "Name" and "Url" from this answer)

# re: CassiniEx v0.94.402 has been released! 6/9/2004 12:50 PM Kiliman

Hi Rainer, to answer your questions:

1) Yes, that's a known problem. I've fixed it for the next release so CassiniEx no longer derives from the Form class.

2) I don't have the steps for configuration virtual hosts in Apache, but here's how I set it up to use mod_proxy:

Create a web site in CassiniEx:
<WebSite
Name = "AspHost1"
Bindings = "host1:8080"
Enabled = "true"
VirtualPath = "/"
PhysicalPath = "C:\Path\To\AspHost1"
ApplicationHost = "ASP.NET"
/>

Edit Apache httpd.conf
ServerName host1:80
Listen 80

Uncomment the lines (remove #)
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_http_module modules/mod_proxy_http.so

Add this to end of httpd.conf:
ProxyRequests Off
ProxyPass / http://host1:8080/">http://host1:8080/

Ok, now startup CassiniEx. Check the log file to make sure it's listening on port 8080. Now fire up Apache. It will be listening on port 80.

Now open your browser to http://host1

The ProxyPass setting basically means that when Apache sees anything that starts with "/", it will redirect the request to http://host1:8080 and be processed by CassiniEx.

One drawback to this is that all requests are proxied, even static files. It might be better to use mod_rewrite and only proxy .aspx files.

3) Finally, when commenting, you can enter anything you want in the Name/Url text box. The Name you enter will show up next to your comment, and if you enter a URL, it will be used as a hyperlink on your name. Unfortunately, if you enter your email address in the Url box, it seems that .Text will always convert it to an http:// reference.

Anyway, good luck with your configuration.

Let me know if there is anything else I can help you with.

Kiliman

# re: CassiniEx v0.94.402 has been released! 6/9/2004 12:53 PM Kiliman

Note, it appears that .Text doesn't render URLs with explicit ports properly.

ProxyPass should be:

ProxyPass / http://host1 :8080 (note: no space between host1 and :8080)

# re: CassiniEx v0.94.402 has been released! 6/9/2004 1:36 PM Rainer

thanks for the quick reply,
I'll try it the next week.
One more question, when will the next version of cassiniex be released?

Rainer

# re: CassiniEx v0.94.402 has been released! 6/17/2004 5:48 PM Greg

Excellent software, just wondering how your management console is coming along?

# re: CassiniEx v0.94.402 has been released! 6/29/2004 9:23 PM Tan Chin Leong

Nice work out there ... I appreciate the most on "Supports multiple virtual folders" feature ;)

Anyway, how is the management console and window service coming along? can't wait to test and use your nice piece of work ;)

# re: CassiniEx v0.94.402 has been released! 8/23/2004 2:49 PM Jeff Patrick

Excellent tool. However, debugging under VS 2003 is problematic. I get the following error:

System.IO.IOException: The process cannot access the file: "C:\projects\CassiniEx\Logs\2004-08-23.log" because it is being used by another process. <followed by a long stack trace>

I've set the debug mode to program and the app to cassiniexwebserver.exe. I've tried it with and without command line arguments: /port:80 /path:c:\projects\test2

Thanks,

- Jeff Patrick

# re: CassiniEx v0.94.402 has been released! 8/27/2004 6:12 AM SwitchBL8

Good work. Has there been any progress in the past 4.5 months?

# re: CassiniEx v0.94.402 has been released! 9/24/2004 7:30 PM polyman

Hi,

I tried to invoke my web service written in C#. It works in IIS but failed with CassiniEx. the error is:

Configuration Error
Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Unrecognized attribute 'xmlns'.

Source Error:

Line 5: A full list of settings and comments can be found in machine.config.comments usually
Line 6: located in \Windows\Microsft.Net\Frameworks\v2.x\Config -->
Line 7: <configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">
Line 8: <appSettings>
Line 9: </appSettings>


Source File: C:\WebSites\addService\web.config Line: 7
please let me know thanks

# re: CassiniEx v0.94.402 has been released! 9/27/2004 2:07 PM C#lover

This is very good work.

I have a question regarding to use VC6 COM object. What will be the easiest way to do so using cassini?

Thanks

# re: CassiniEx v0.94.402 has been released! 10/16/2004 8:30 AM Jacob

Hmmm... I've been trying to use CassiniEx with VS2003 for quite a while now, but I just can't seem to get it working. Whenever I try to create a Web Project in the server, i get a dialog box saying that the folder could not be created, as the server has encountered error 500... I've looked in the logs, and apparently VS tries to load a file called get_asp_version.aspx, which either I don't have or don't know about... Could anyone enlighten me as to what I'm missing?

Oh, and by the way, does anyone know where Kiliman went? He hasn't posted in months, and he doesn't respond to email. Are you out there somewhere, Kiliman?

# re: CassiniEx v0.94.402 has been released! 12/6/2004 8:28 PM TheFreak

Plz support GZip ! Thx

# CassiniEX allows you to run Tourney Pool Manger on your desktop computer 1/30/2005 11:12 PM BRIAN'S BLOG

# CassiniEx Web Server 2/16/2005 3:10 AM .Net Adventures

Comments have been disabled. Please use Contact Form to reach me. Thanks!