Blog defaulting to rss feed

Hey all,

All of a sudden my blog seems to be defaulting to an rss feed inside of
firefox.

It’s at http://blog.michaelcdever.com and I checked it in Firefox 2 & 3,
both with the same result. It was working just fine last night. If I run
dispatch.fcgi it outputs the html for the blog as I would expect.

Anyone have any ideas??

Regards,

Michael Dever

Michael Dever wrote:

All of a sudden my blog seems to be defaulting to an rss feed inside of
firefox.

It’s at http://blog.michaelcdever.com and I checked it in Firefox 2 & 3,
both with the same result. It was working just fine last night. If I run
dispatch.fcgi it outputs the html for the blog as I would expect.

It seems to be working ok now. I’m assuming you switchted to
dispatch.fcgi for now?

Anyone have any ideas??

Can you check the contents of the file index.html in the public/
subdirectory of your typo installation? Is it RSS or html?

Regards,
Matijs

Le 2 sept. 2009 à 14:19, Michael Dever a écrit :

Anyone have any ideas??

Hello,

It seems to happen sometimes on Rails app using caches_page and
serving both html and xml.
I have not found a workaround yet.

Regards,
Frédéric


Frédéric de Villamil
“What’s mine is mine. What’s yours is still unsetteled” – Go player
proverb
[email protected] tel: +33 (0)6 62 19 1337
http://t37.net Typo : http://typosphere.org

Yep, seems to be sorted. Thats a strange bug. I wonder why that happens,
is
it just Typo, or do you know of it occurring with other rails apps?

2009/9/2 de Villamil Frédéric [email protected]

both with the same result. It was working just fine last night. If I run
I have not found a workaround yet.


Typo-list mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/typo-list

Regards,

Michael Dever

Michael Dever wrote:

Yep, seems to be sorted. Thats a strange bug. I wonder why that happens,
is it just Typo, or do you know of it occurring with other rails apps?

I found this page:

http://railsenvy.com/2007/2/28/rails-caching-tutorial

which says:

Yup, page caching is going to ignore all additional parameters on 

your url.

So it should be a problem with all rails apps.

It seems to happen sometimes on Rails app using caches_page and
serving both html and xml.
I have not found a workaround yet.

So my guess is that this happens whenever a URL like

http://your.blog.org/?format=rss

(which caches like index.html!) is accessed before

http://your.blog.org/

gets a chance to cache its version. I don’t really see a solution for
this: Is
there a way to make Rails ignore parameters supplied this way?

Le 4 sept. 2009 à 11:37, Michael Dever a écrit :

happens,
on your url.

(which caches like index.html!) is accessed before

http://your.blog.org/

gets a chance to cache its version. I don’t really see a solution
for this: Is
there a way to make Rails ignore parameters supplied this way?

Hello,

Because of some other issues, I’ve planning to rewrite our cache
system from scratch. It will take some time and I’m not sure I’ll be
able to do it before the next release, but it may also solve the HTML
VS XML issue.

Cheers,
Frédéric


Frédéric de Villamil
“What’s mine is mine. What’s yours is still unsetteled” – Go player
proverb
[email protected] tel: +33 (0)6 62 19 1337
http://t37.net Typo : http://typosphere.org

Or is there a way to set a low lifetime on anthing thAt is a feed?
Like maybe a minute? The problem would still be there, but reduced.

Regards,
michael

On Friday, September 4, 2009, Matijs van Zuijlen [email protected]
wrote:

Yup, page caching is going to ignore all additional parameters on your url.

Regards,

Michael Dever

Michael Dever wrote:

Or is there a way to set a low lifetime on anthing thAt is a feed?
Like maybe a minute? The problem would still be there, but reduced.

I don’t believe there is any lifetime option for the Rails page caching
feature
that Typo uses.

However …

So my guess is that this happens whenever a URL like

http://your.blog.org/?format=rss

(which caches like index.html!) is accessed before

http://your.blog.org/

gets a chance to cache its version. I don’t really see a solution for this: Is
there a way to make Rails ignore parameters supplied this way?

… I have come up with a solution for this quandary! It is possible to
add a
condition to Rails’ page caching. I have just implemented the condition
that the
query string must be empty. This means that after a cache sweep,

http://your.blog.org/?format=rss

will return the RSS feed but will not cache anything. Then,

http://your.blog.org/

will return the proper html and cache it. Then

http://your.blog.org/?format=rss

will return the html. This is not what the client requested, but they
shouldn’t
be accessing the rss feed like that anyway, so I consider this a minor
problem,
and certainly a lot less bad than the current situation.

I’ve committed the fix to typo’s master branch.

Edward Middleton wrote:

Matijs van Zuijlen wrote:

http://your.blog.org/?format=rss

Shouldn’t this be http://your.blog.org/index.rss

That would be the one you want people to access, and it should be
cached. The
problem is that there is no way to stop people from accessing the first
one and
messing up the cache.

An even worse example:

http://your.blog.org/?year=1800

Guess what’s in your cache now :-).

Matijs van Zuijlen wrote:

there a way to make Rails ignore parameters supplied this way?

… I have come up with a solution for this quandary! It is possible to add a
condition to Rails’ page caching. I have just implemented the condition that the
query string must be empty. This means that after a cache sweep,

http://your.blog.org/?format=rss

Shouldn’t this be http://your.blog.org/index.rss

Edward