I spun up the new CF11 (Update 2) server, and under IIS 7.5, I now have the stock BE framework install running the stock BE app. The only problem is that I have to hit index.cfm explicitly, and can’t rely on the IIS default document, ending the URL with the app directory. If I do that, I get the same “index is not a valid registered event” exception.
Do you have some kind of URL rewriting engine configured in IIS? I don’t understand why your routed URL is index/ You also shouldn’t have to specify index.cfm if it is your default document, which it is by default.
We definitely DO NOT have any rewriting configured or turned on. It’s a brand new, vanilla IIS and CF11 install. Nothing tweaked. We don’t understand why Routed URL shows as index/ either.
What if you create a new folder and out nothing but an empty Application.cfc in it and a index.cfm and navigate to that folder in the URL. What loads? Dump out the cgi scope in your onRequestStart() if necessary to debug. That will tell us if IIS is serving index.cfm with an empty path_info by default.
Also, I don’t remember if we’ve covered this or not, but uninstall and reinstall your IIS web connectors. ← important.
Just out of curiosity, can you re-run the web configuration tools and try to reset the connectors for ColdFusion. It maybe that the default cfml documents didn’t get set up.
I’ll give these suggestions a try. To be precise, what constitutes an “empty” Application.cfc? Nothing but “component { }” ? What if I did the CGI dump in index.cfm? Same diff?
Well, I didn’t suggest that because you told us IIS isn’t serving index.cfm as the default document, so the purpose of the test is to NOT give a document to IIS and see what it asks ColdFusion for. The only way to do that would be to capture it in Application.cfc.
And don’t forget re-creating the IIS connectors. If you’ve applied any ColdFusion updates at all, you can get weird issues that happen regarding the CGI scope until you remove and re-add the IIS config.
The issue has to be that your path info is incorrect in your cgi scope. Can anyone else confirm if they’re using CF11 with IIS? I tested this on CF11, but I don’t have IIS to test with.
Can you hit Tomcat directly and see how it behaves? Look in C:\ColdFusion11\cfusion\runtime\conf\server.xml and see what the port is set to in the connector tag that uses an HTTP protocol. For instance, here is mine-- though I’ve changed the port from the default:
So if I hit http://localhost:8511, I’m hitting Tomcat directly and bypassing any kind of web server like IIS.
That is correct, the path info is sort of correct, however the index.cfm should not be there. This leads me to believe that the issue is with the routes table and/or the rewrite ISAPI being used. My guess, is that the routes.cfm has not been modified to remove the index.cfm, while being used with rewrite rules.
Or that the rules are not right.
Now I haven’t done it for a very long time, but I think the rewrite rule is the issue if it is not taking the Virtual Directory into account, just something else to thing about.
But yeah, the index.cfm should not be in the path_info at all.