I think we do have a little misunderstanding here ;)

All the time I was talking about packaged (e.g. in a jar file), static resources. Dynamically created images are a whole different thing; I guess these could be either kept in memory or - if you want to keep mem consumption within limits - generate them to temporary files.

My whole point so far is that the way Wicket handles things (everything is a component) works great, but has a negative side effect in that packaged static resources (ie images and stuff that you keep in java packages) are bad for performance.

As an example, if you have a ListView, that you populate with an image, and you have ten rows in the list, you'll end up with eleven servlet invokes; one for the page, and one for each image (ten that is), as those images, even if they are exactely the same images, will be seperate components, that are thus requested seperately. Ideally, you want just one request for that image, and have the browser know, he doesn't need the others because that image is allready in it's cache.

Also, on a next request (e.g. a click on some other component on that page, will result in again ten requests for the images, as the browser still regards those images as non-cachable.

Eelco

        Ok, I follow you so far, so why does this prevent us from
serving up dynamically generated images from tempdir? I'm guessing
you're only objecting to the idea of serving up static images using the
servlet as opposed to using the webserver? I'd just like the ability to
dump my static images into the WebApp directory. It would be an option,
nothing else. There is nothing preventing us from dumping the static
images into another directory that the webserver can get at directly,
right?

Gili






------------------------------------------------------- The SF.Net email is sponsored by: Beat the post-holiday blues Get a FREE limited edition SourceForge.net t-shirt from ThinkGeek. It's fun and FREE -- well, almost....http://www.thinkgeek.com/sfshirt _______________________________________________ Wicket-develop mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/wicket-develop

Reply via email to