You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by "Caldarale, Charles R" <Ch...@unisys.com> on 2009/06/11 14:57:43 UTC

RE: Loading dynamically created content: An old chestnut but still a problem.

> From: Hassan Schroeder [mailto:hassan.schroeder@gmail.com]
> Subject: Re: Loading dynamically created content: An old chestnut but
> still a problem.
> 
> Then I copied a random example.gif image to the ROOT directory
> and entered http://localhost:8080/example.gif in my address bar.
> And there it is in my browser.

Just to confirm that there's no long-term caching, I extended the above by starting Tomcat, loaded the home page in Firefox, replaced tomcat.gif by one of Bill the Cat with the name tomcat.gif, refreshed the page with F5, and got the revised, much uglier image in the upper left corner.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Loading dynamically created content: An old chestnut but still a problem.

Posted by Lyallex <ly...@gmail.com>.
2009/6/11 Caldarale, Charles R <Ch...@unisys.com>:
>> From: Christopher Schultz [mailto:chris@christopherschultz.net]
>> Subject: Re: Loading dynamically created content: An old chestnut but
>> stilla problem.
>>
>> I suspect that Hassan and Chuck are nto using anti-resource-locking
>> while Lyallex is.
>
> Correct; as stated, both Hassan and I are using stock Tomcat 6.0.20 downloads.
>
> If the external webapp approach I suggested is used, the antiResourceLocking attribute should be set to false for that <Context>.
>
>  - Chuck
>
>

I have this working now. I removed the locking attributes from the
context as explained in the other thread.

Thanks to all those who took the time to reply, it's much appreciated.

lyallex

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: Loading dynamically created content: An old chestnut but still a problem.

Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Christopher Schultz [mailto:chris@christopherschultz.net]
> Subject: Re: Loading dynamically created content: An old chestnut but
> stilla problem.
> 
> I suspect that Hassan and Chuck are nto using anti-resource-locking
> while Lyallex is.

Correct; as stated, both Hassan and I are using stock Tomcat 6.0.20 downloads.

If the external webapp approach I suggested is used, the antiResourceLocking attribute should be set to false for that <Context>.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers.


Re: Loading dynamically created content: An old chestnut but still a problem.

Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Mark,

On 6/11/2009 9:36 AM, Mark Thomas wrote:
> This all all a expected side-effect of using the anti resource locking
> features.

Oh, good: some /real/ information as to the cause. I suspect that Hassan
and Chuck are nto using anti-resource-locking while Lyallex is.

I've never had this problem myself because I don't try to generate
static content dynamically :)

- -chris
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkoxKw0ACgkQ9CaO5/Lv0PCqigCeLDj4JIz/5Q/3RcCTQg6hiJQ5
Y7EAoLwc3qisk1loM3+zq2AdfX6vD3Lm
=WmdG
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Loading dynamically created content: An old chestnut but still a problem.

Posted by Mark Thomas <ma...@apache.org>.
Lyallex wrote:
> 2009/6/11 Caldarale, Charles R <Ch...@unisys.com>:
>>> From: Hassan Schroeder [mailto:hassan.schroeder@gmail.com]
>>> Subject: Re: Loading dynamically created content: An old chestnut but
>>> still a problem.
>>>
>>> Then I copied a random example.gif image to the ROOT directory
>>> and entered http://localhost:8080/example.gif in my address bar.
>>> And there it is in my browser.
>> Just to confirm that there's no long-term caching, I extended the above by starting Tomcat, loaded the home page in Firefox, replaced tomcat.gif by one of Bill the Cat with the name tomcat.gif, refreshed the page with F5, and got the revised, much uglier image in the upper left corner.
>>
>>  - Chuck
> 
> OK, all very nice ... I just tried this. The server was running and my
> application was up and working.
> I copied an image into the ROOT directory then tried to access it like
> so http://localhost/main.jpg and got a 404 not found.
> 
> I stopped and restarted the server (very important this) and tried the
> same request again and the image loaded.
> 
> I'm not imagining this. It is a fact. On my setup (tomcat 6.0.16.
> jdk1.6.0_03, Windows XP SP 2) I cannot load images that have been
> written to disk after the server starts ... sorry if this offends you
> in some way, it's driving ME nuts especially as you all seem to have
> no trouble with this. I'm almost tempted to load the app onto the live
> server and see if it works there. .. no, that way lies madness.

This all all a expected side-effect of using the anti resource locking
features.

Mark



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: Loading dynamically created content: An old chestnut but still a problem.

Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Lyallex [mailto:lyallex@gmail.com]
> Subject: Re: Loading dynamically created content: An old chestnut but
> still a problem.
> 
> I'm not imagining this. It is a fact. On my setup (tomcat 6.0.16.
> jdk1.6.0_03, Windows XP SP 2) I cannot load images that have been
> written to disk after the server starts ...

Both Hassan and I were using a stock Tomcat 6.0.20 (mine was on Vista 64).  Try it with a 6.0.20 clean installation, and then compare configs between your 6.0.16 and 6.0.20 versions to see what you've changed that is preventing the normal behavior.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers.



---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Loading dynamically created content: An old chestnut but still a problem.

Posted by Lyallex <ly...@gmail.com>.
2009/6/11 Caldarale, Charles R <Ch...@unisys.com>:
>> From: Hassan Schroeder [mailto:hassan.schroeder@gmail.com]
>> Subject: Re: Loading dynamically created content: An old chestnut but
>> still a problem.
>>
>> Then I copied a random example.gif image to the ROOT directory
>> and entered http://localhost:8080/example.gif in my address bar.
>> And there it is in my browser.
>
> Just to confirm that there's no long-term caching, I extended the above by starting Tomcat, loaded the home page in Firefox, replaced tomcat.gif by one of Bill the Cat with the name tomcat.gif, refreshed the page with F5, and got the revised, much uglier image in the upper left corner.
>
>  - Chuck

OK, all very nice ... I just tried this. The server was running and my
application was up and working.
I copied an image into the ROOT directory then tried to access it like
so http://localhost/main.jpg and got a 404 not found.

I stopped and restarted the server (very important this) and tried the
same request again and the image loaded.

I'm not imagining this. It is a fact. On my setup (tomcat 6.0.16.
jdk1.6.0_03, Windows XP SP 2) I cannot load images that have been
written to disk after the server starts ... sorry if this offends you
in some way, it's driving ME nuts especially as you all seem to have
no trouble with this. I'm almost tempted to load the app onto the live
server and see if it works there. .. no, that way lies madness.

lyallex

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org