You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@forrest.apache.org by "Ross Gardler (JIRA)" <ji...@apache.org> on 2006/07/24 12:13:14 UTC

[jira] Closed: (FOR-910) project DOAP file retrieved numerous times during docs generation

     [ http://issues.apache.org/jira/browse/FOR-910?page=all ]

Ross Gardler closed FOR-910.
----------------------------

    Resolution: Fixed
      Assignee: Ross Gardler

The resource is retrieved so often because it is needed to build the navigation  menus, which are on every page.

The resource, when retrieved from the remote location is not cached efficiently by Cocoon (I guess Cocoon does not check for validity of the remote file).

I fixed this by adding a cache to the pipeline that generates the site.ml snippets from the DOAP files. The requests are cached for 10 minutes - should be plenty of time for even a large site build - but this will cause problems if trying to dynamically edit a DOAP.

> project DOAP file retrieved numerous times during docs generation
> -----------------------------------------------------------------
>
>                 Key: FOR-910
>                 URL: http://issues.apache.org/jira/browse/FOR-910
>             Project: Forrest
>          Issue Type: Bug
>          Components: Plugin: input.projectInfo
>    Affects Versions: 0.8-dev
>            Reporter: David Crossley
>         Assigned To: Ross Gardler
>            Priority: Minor
>
> The ability to retrieve a project DOAP file to create "projectDetails" information pages is retrieving the example  forrest descriptor numerous times. Throughout the build of the projectInfo plugin's docs (130) it conducted requests for the remote doap.xml file a total of 603 times.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Re: [jira] Closed: (FOR-910) project DOAP file retrieved numerous times during docs generation

Posted by Ross Gardler <rg...@apache.org>.
Ross Gardler wrote:
> David Crossley wrote:
> 
>> Ross Gardler (JIRA) wrote:
>>
>>> Ross Gardler closed FOR-910.
>>> ----------------------------
>>>
>>>    Resolution: Fixed
>>>      Assignee: Ross Gardler
>>>
>>> The resource is retrieved so often because it is needed to build the 
>>> navigation  menus, which are on every page.
>>
>>
>>
>> Yes, however it is still strange that there are so many requests.
>> There are only 33 html pages generated, yet 603 requests for doap.xml
>> So perhaps there is another issue with this "projectDetails" stuff.
> 
> 
> Good point.
> 
> I didn't do any testing after my cache patch other than to look at the 
> time for site generation. Theoretically it should only be requested once 
> now.

Incidentally, I did not revert Davids workaround [1] of retrieving the 
content from the local src directory instead of SVN. This was because of 
my lack of exhaustive testing.

If anyone gets the time to revert Davids change and check that we are 
only retrieving the remote resource once that would be great. Otherwise 
we need to change this text from the index page of the plugin docs:

"Using the locationmap you can retrieve this content from anywhere you 
want, for example, the DOAP file for the Forrest project comes from 
directly from SVN, thus we are always assured of it being up to date."

Ross

[1] http://svn.apache.org/viewvc?view=rev&revision=424889

Re: [jira] Closed: (FOR-910) project DOAP file retrieved numerous times during docs generation

Posted by Ross Gardler <rg...@apache.org>.
David Crossley wrote:
> Ross Gardler (JIRA) wrote:
> 
>>Ross Gardler closed FOR-910.
>>----------------------------
>>
>>    Resolution: Fixed
>>      Assignee: Ross Gardler
>>
>>The resource is retrieved so often because it is needed to build the navigation  menus, which are on every page.
> 
> 
> Yes, however it is still strange that there are so many requests.
> There are only 33 html pages generated, yet 603 requests for doap.xml
> So perhaps there is another issue with this "projectDetails" stuff.

Good point.

I didn't do any testing after my cache patch other than to look at the 
time for site generation. Theoretically it should only be requested once 
now.

>>The resource, when retrieved from the remote location is not cached efficiently by Cocoon (I guess Cocoon does not check for validity of the remote file).
>>
>>I fixed this by adding a cache to the pipeline that generates the site.ml snippets from the DOAP files. The requests are cached for 10 minutes - should be plenty of time for even a large site build - but this will cause problems if trying to dynamically edit a DOAP.
> 
> 
> Thanks, that is a good demo of using a bit more of the Cocoon cache
> abilities.

We need to be careful about using it in a dynamic environment though, it 
destroys the dynamic behaviour of edit and see results immediately.

> I am not sure if this is related, but on a Cocoon app i use
> a patch by Ugo Cei:
> 
> Re: Supporting "conditional GET" in Cocoon
> http://thread.gmane.org/gmane.text.xml.cocoon.devel/59509

That looks like a useful addition. Maybe if I get the time I'll 
resurrect the discussion about that patch [1] and get it applied to 
Cocoon trunk. I don't want to apply it as the discussion you link to 
seems to imply it should be improved upon.

In the meantime, I'm afraid there are more pressing things.

Ross

[1] https://issues.apache.org/jira/browse/COCOON-1726

Re: [jira] Closed: (FOR-910) project DOAP file retrieved numerous times during docs generation

Posted by David Crossley <cr...@apache.org>.
Ross Gardler (JIRA) wrote:
> 
> Ross Gardler closed FOR-910.
> ----------------------------
> 
>     Resolution: Fixed
>       Assignee: Ross Gardler
> 
> The resource is retrieved so often because it is needed to build the navigation  menus, which are on every page.

Yes, however it is still strange that there are so many requests.
There are only 33 html pages generated, yet 603 requests for doap.xml
So perhaps there is another issue with this "projectDetails" stuff.

> The resource, when retrieved from the remote location is not cached efficiently by Cocoon (I guess Cocoon does not check for validity of the remote file).
> 
> I fixed this by adding a cache to the pipeline that generates the site.ml snippets from the DOAP files. The requests are cached for 10 minutes - should be plenty of time for even a large site build - but this will cause problems if trying to dynamically edit a DOAP.

Thanks, that is a good demo of using a bit more of the Cocoon cache
abilities.

I am not sure if this is related, but on a Cocoon app i use
a patch by Ugo Cei:

Re: Supporting "conditional GET" in Cocoon
http://thread.gmane.org/gmane.text.xml.cocoon.devel/59509

-David