You are viewing a plain text version of this content. The canonical link for it is here.
Posted to axkit-dev@xml.apache.org by Matt Sergeant <ma...@sergeant.org> on 2003/03/24 08:29:14 UTC
Fwd: [cpan #2277] Stylesheet mtime comparison broken when using custom ContentProvider
Begin forwarded message:
> From: "Guest via RT" <bu...@rt.cpan.org>
> Date: Mon Mar 24, 2003 05:06:31 Europe/London
> To: "AdminCc of cpan Ticket #2277": ;
> Subject: [cpan #2277] Stylesheet mtime comparison broken when using
> custom ContentProvider
> Reply-To: bug-AxKit@rt.cpan.org
>
>
> This message about AxKit was sent to you by guest <> via rt.cpan.org
>
> Full context and any attached attachments can be found at:
> <URL: https://rt.cpan.org/Ticket/Display.html?id=2277 >
>
> When a resource's dependencies are checked for changes (mtime) to
> determine whether to serve cached output, each dependency is
> initialized with Apache::AxKit::Provider->new(), which calls
> new_content_provider(). This occurs for both content _and_ style
> dependencies. Style dependencies, obviously, should use
> new_style_provider().
>
> The symptom of this bug is that if the ContentProvider uses a method
> to find the mtime that differs from that of the File provider, the
> style resource will report a non-accurate mtime. In my case I could
> modify the stylesheets and their mtime would still be reported as old
> so the output would not be regenerated.
>
> To fix this we need a way to specify which items in the dependency
> cache are content and which are style resources. I have attached a
> patch against current CVS that does this by adding {style} or
> {content} before each dependency, and that prefix is checked later to
> use the correct Provider constructor.
>
> Please check this patch to see if it is actually a sound solution (it
> works for me in my particular usage).
>