On May 18, 2005, at 1:01 PM, Patrick Yip wrote:
Hi Erik,
Can you please give a brief example to show us how to use the AssetExternalizer? Where should the AssetExternalizer be set up and configured?
If possible, can you add it to the FAQ because I believe it is not in any of the documentation or in the TIA book?
I don't have a working example handy, as the externalizer is used primarily for production deployments, not for development. But, it works exactly as documented at the page I sent. Set those two system properties as described and any private assets will get externalized to the directory specified and the generated URLs to those assets will be modified to use the base URL specified.
On second thought, asset externalization is not a good solution for this particular case. Asset externalization is for private assets that get served from the classpath, which is probably not the case here. I consider the asset externalization feature of Tapestry one of its really clever strong points - beating up the app. server to feed the DatePicker calendar icon from the classpath dynamically is not good for production, yet you can flip a couple of switches and off-load that calendar icon to Apache directly.
Erik
Thanks, -Patrick
-----Original Message----- From: Erik Hatcher [mailto:[EMAIL PROTECTED] Sent: Tuesday, May 17, 2005 5:41 AM To: Tapestry users Subject: Re: Serving large number of product images
On May 16, 2005, at 8:00 PM, Patrick Yip wrote:
I apologize if this question has been asked too many times. I did a quick search and haven't been able to find a satisfactory answer.
Currently, I face a practical issue of serving the images when the image files are packaged into the war file. Adding images require me to repackage the war file and upload to the JBoss server.
Is there a way to specify a directory outside of JBoss server directory (but on the same physical machine) so I can have a permanent home for my product images?
For instance, I would like to store all the product images under c:\products\ directory. Any suggestion is greatly appreciated.
You will need c:\products be web accessible for this to work, check out the externalizer capability built into Tapestry asset handling:
http://jakarta.apache.org/tapestry/doc/api/org/apache/tapestry/ asset/AssetExternalizer.html
Erik
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
