This project has moved and is read-only. For the latest updates, please go here.

RSS Feed 404

Mar 5, 2009 at 10:04 PM
OK, I'm starting to feel like a needy puppy....  :)

If I try to access the RSS feeds on Ticketdesk, I get a 404 not found error...  It doesn't matter what RSS feed I try...  For example:

http://cww.namfg.com/TicketDesk/services/rss.svc/createfeed/

http://cww.namfg.com/TicketDesk/services/rss.svc/createfeed/?status=closed

Etc. etc...

cww.namfg.com is the name of our web server (internal only)...  And the app's installed in the /TicketDesk/ folder.

Odd thind is that it runs OK if I run in Debug mode on my local machine through Visual WebDev 2008 Express.  But if I copy the app over to our intranet server (IIS7, Server 2008)  then the RSS doesn't work. 

Yes, I've got the key in the web.config

<add key="EnableRSS" value="true"/>

So, it's probably not a TicketDesk issue, but I'm stumped as to why it's not working...  There are no errors in the System Application log, and the only thing in the IIS log is the 404 error.

Joe P
Mar 6, 2009 at 6:22 PM
OK, ya leave me alone to poke at something long enough, and eventually I figure something out.  I'll post my finding here in case it helps someone in the future... 

I found that I did not have the *.svc script file type mapped within IIS.  These instructions allowed me to rectify the error: 

http://msdn.microsoft.com/en-us/library/ms752252.aspx

However, after that, I was getting another error when accessing any RSS URL, as follows:

This collection already contains an address with scheme http.  There can be at most one address per scheme in this collection.
Parameter name: item


etc etc etc (sorry, didn't copy the whole error message, but I can reproduce it agian if someone wants to see it)

Upon more digging, I found that I had to modify the <serviceHostingEnvironment> section of web.confiig as follows:

Original (located in <system.serviceModel> :

<serviceHostingEnvironment aspNetCompatibilityEnabled="true"/>

Modified: 

<serviceHostingEnvironment aspNetCompatibilityEnabled="true">
   <baseAddressPrefixFilters>
      <add prefix="
http://cww.namfg.com/ticketdesk/"/>
   </baseAddressPrefixFilters>
</serviceHostingEnvironment>

The 'prefix =' portion is the beginning URL of the Ticketdesk web app in my environment.


...and that's it...  Now the RSS feeds work correctly.  If anyone has feedback on what quirks in my enviorment may have caused this, or of there's a better fix than what I've implimented, let me know!  Otherwise, maybe these instructions will help someone in the future.

JP
Mar 6, 2009 at 7:40 PM
I don't really know about the configuration options you ended up with there at the end.... 

What I do know is that the initial problem you first reported sounds exactly like a problem we ran into with older versions of TicketDesk when we were pre-compiling the app. 

We used to do a full pre-compile version of TicketDesk where there were no aspx, ascx, etc files at all. But asp.net hosted WCF services require an actual *.svc file to be on the file system or it doesn't correctly handle the requests (at least it doesn't in the default configuration)... so you'd get a 404 on the RSS service if you had fully pre-compiled the app. 

So instead we switched to using the editable pre-compile... asp.net build tools often call it "Make the web site editable" or what not. This is where the code behind gets all compiled up to the bin folder but the aspx, ascx, svc, etc files don't.   



Mar 6, 2009 at 8:51 PM
I tried going into Build > Configuration Manager and switching my "Active Solution Configuration" to "EditablePreCompile" ...  Compiled into a local dir..  Then I tried changing from EditablePreCompile to "Release"  (the only other option is Debug)....  Compiled into another directory..   Then I compared both directories and both contained the exact same set of files...

Don't know if I'm flipping the right switch, but either option yeilded the same results... I tried copying them both to my web server and neither worked right without the changes to web.config that I outlined above.

JP 
Mar 7, 2009 at 9:33 AM
Sounds like the solution you ended up with is the correct one.  

The EditablePreCompile configuration in configuration manager actually won't do much in your case. The settings for the web project itself for EditablePreCompile are pretty much identical to the Release configuration. Where EditablePreCompile makes a difference is in the deployment project, but you said earlier that you were using Visual Web Developer Express. Deployment projects aren't compatible with VWD (sadly... ).