[ 
https://issues.apache.org/jira/browse/WICKET-3357?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12987597#action_12987597
 ] 

Brad Grier commented on WICKET-3357:
------------------------------------

Thanks for looking at this. I'm willing to switch to 1.5 but it seems two of 
the libraries in our project require Wicket 1.4.

You mention solving the issue (at least in the quickstart) by deferring 
expensive actions to AbstractResourceStreamWriter.write(OutputStream). In my 
testing his method gets called twice as well. Am I misinterpreting what you 
wrote? Thanks.

> Resource getResourceStream called twice with single request
> -----------------------------------------------------------
>
>                 Key: WICKET-3357
>                 URL: https://issues.apache.org/jira/browse/WICKET-3357
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket
>    Affects Versions: 1.4.15
>         Environment: Tomcat on Windows 7. Jetty on Ubuntu Linux..
>            Reporter: Brad Grier
>            Assignee: Peter Ertl
>             Fix For: 1.5-RC2
>
>         Attachments: myproject.zip
>
>
> getResourceStream is being called multiple times for Resource subclasses used 
> to create dynamic images and/or textual data. This can be extremely 
> inefficient depending on the work required to generate the resource. In my 
> case, it presents a more serious problem because data inserted in the 
> overriden getResourceStream method is duplicated in the database.
> The attached quickstart creates a dynamic image in getResourceStream. The 
> method is called twice for a single request.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to