Error re-starting war application

2006-06-01 Thread ingo . bischofs
Hi list

I've posted that question already before. 

I am using Eclipse WTP for development of a web application and use it's 
'Export' function for creating the .war file.
Installing that application on Tomcat 5.5.x works fine.

But, stopping and re-starting the application fails every time with a 
NullPointerException. Do you have any hints?

Thanks

Re: Tomcat Logo on Public Server

2006-06-01 Thread Danny Lee

Of course it's legal, why not?

Danny

Torben Werner wrote:

Hello everybody,

i would like to know if it is legal to put the Tomcat logo and a link to 
tomcat.apache.org on my own homepage.


Thanks for your help!

Greetz Torben

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat Logo on Public Server

2006-06-01 Thread Mladen Turk

Torben Werner wrote:

Hello everybody,

i would like to know if it is legal to put the Tomcat logo and a link to 
tomcat.apache.org on my own homepage.




Of course.
Unless the name of your website does not have/contain any ASF project
name, you are welcome to use the official logo with a project
link.

For example:
www.tomcat5.org would be invalid,
but www.yoursite.org/tomcat5 is a valid name
unless you claim something opposite to the ASF license:
http://www.apache.org/licenses/LICENSE-2.0.html

Regards,
Mladen.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat Logo on Public Server

2006-06-01 Thread Torben Werner
I don't know. Maybe they don't want that i link to their Server!? I have 
done something like that a few years before and got a lot of trouble. 
Just wanted to be sure.


Thanks for your answer

Torben


Of course it's legal, why not?

Danny

Torben Werner wrote:


Hello everybody,

i would like to know if it is legal to put the Tomcat logo and a link 
to tomcat.apache.org on my own homepage.


Thanks for your help!

Greetz Torben

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat Logo on Public Server

2006-06-01 Thread Mladen Turk

Torben Werner wrote:
I don't know. Maybe they don't want that i link to their Server!? I have 
done something like that a few years before and got a lot of trouble. 
Just wanted to be sure.




Read the official:
http://httpd.apache.org/docs/1.3/misc/FAQ.html#logo

So:
You may NOT use any original artwork from the Apache Software 
Foundation, nor make or use modified versions of such artwork, except 
under the following conditions:
* You may use the 'Powered by Apache' graphic on a Web site that is 
being served by the Apache HTTP server software.
* You may use the aforementioned 'Powered by Apache' graphic or the 
Apache Software Foundation logo in product description and promotional 
material IF and ONLY IF such use can in no way be interpreted as 
anything other than an attribution. Using the Apache name and artwork in 
a manner that implies endorsement of a product or service is strictly 
forbidden.



It applies to all ASF projects.

Regards,
Mladen.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat Logo on Public Server

2006-06-01 Thread Torben Werner

@ Mladen

That sounds like my way to use to the tomcat logo is ok. I will just put 
the logo on my page to indicate that i'm using this server. More not. As 
I understand the official that is ok.


Thanks for your answer


Torben Werner wrote:

I don't know. Maybe they don't want that i link to their Server!? I 
have done something like that a few years before and got a lot of 
trouble. Just wanted to be sure.




Read the official:
http://httpd.apache.org/docs/1.3/misc/FAQ.html#logo

So:
You may NOT use any original artwork from the Apache Software 
Foundation, nor make or use modified versions of such artwork, except 
under the following conditions:
* You may use the 'Powered by Apache' graphic on a Web site that 
is being served by the Apache HTTP server software.
* You may use the aforementioned 'Powered by Apache' graphic or 
the Apache Software Foundation logo in product description and 
promotional material IF and ONLY IF such use can in no way be 
interpreted as anything other than an attribution. Using the Apache 
name and artwork in a manner that implies endorsement of a product or 
service is strictly forbidden.



It applies to all ASF projects.

Regards,
Mladen.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat Logo on Public Server

2006-06-01 Thread Mladen Turk

Torben Werner wrote:

@ Mladen

That sounds like my way to use to the tomcat logo is ok. I will just put 
the logo on my page to indicate that i'm using this server. More not. As 
I understand the official that is ok.




Sure. If you use any ASF project logo in a attribution way,
you are more then welcome :)

Regards,
Mladen.


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat Logo on Public Server

2006-06-01 Thread Torben Werner

Excellent. :-)


Torben Werner wrote:


@ Mladen

That sounds like my way to use to the tomcat logo is ok. I will just 
put the logo on my page to indicate that i'm using this server. More 
not. As I understand the official that is ok.




Sure. If you use any ASF project logo in a attribution way,
you are more then welcome :)

Regards,
Mladen.


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat as a standalone webserver. Why not?

2006-06-01 Thread Mark Hagger
This issue is discussed endlessly as far as I can see, both camps argue
very well for their case

However, my take from personal experience is that its very handy to
have Apache in front, because it gives you a lot of scope to do little
fixes and tweaks to odd users causing problems without any service
downtime.  For example you can pretty much add Apache Rewrite rules all
over the shop to fix up little issues without having to actually restart
any servers, (just an Apache SIGHUP, or reload).

You can also fiddle with the various request headers, response headers,
logging of request, response headers, with no impact on the back-end
tomcat layer and its webapps.

Of course there is the load balancer issue as well, if you
require/desire to have sticky sessions.

Obviously if your code is perfect and bug free and users are all
perfect, and sticky sessions are not required then then perhaps
tomcat-only is the solution.  Although I've yet to meet an author of bug
free code.

Thats my opinion anyway.

Mark


On Thu, 2006-06-01 at 12:05 +0200, Danny Lee wrote:
 Hi guys!
 
 I wondering if it's really so good to use Tomcat behind a real web 
 server like Apache or IIS.
 
 In my Tomcat 5 book there are two reasons to do it so:
 
 1. Tomcat is not as secure as common web servers, especially if   you 
 want  to use CGI and SSI (I don't think I want to)
 
 2. Tomcat is slow delivering static content.
 
 Well, as long it's just planned to use only 1 server for my application,
 I don't think the both points are true for me. On the Tomcat site 
 there's a note about performance:
 
 When using a single server, the performance when using a native 
 webserver in front of the Tomcat instance is most of the time 
 significantly worse than a standalone Tomcat with its default HTTP 
 connector, even if a large part of the web application is made of static 
 files
 
 And security... what about security? Why is Tomcat behind of Apache
 more secure then without it, especially (as I said) if both are running
 on the same server.
 
 Thanks in advance!
 
 Cheers,
 
 Danny
 
 
 -
 To start a new topic, e-mail: users@tomcat.apache.org
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 
 
 
 This email has been scanned for all known viruses by the MessageLabs SkyScan 
 service.



This email has been scanned for all known viruses by the MessageLabs SkyScan 
service.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat Logo on Public Server

2006-06-01 Thread Mladen Turk

Torben Werner wrote:

Excellent. :-)



Right.
I even know a guy that uses IIS+isapi_redirector,
and on the front page he has 'Powered by Apache'
Now, that's something :)

Regards,
Mladen.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Apache 2 + Tomcat 5.0.28

2006-06-01 Thread Greg Gamble
On Thu, Jun 01, 2006 at 10:23:35AM +0200, Ga??l Lams wrote:
 Hi
 
 I have Apache 2 (as part of a `LAMP' install) and TomCat 5.0.28 installed
 on a Debian Linux: 2.6.12-1-686 system
 and I want to make Apache and Tomcat listen/connect to the same port.
 
 2 services can not listen to the same port, you probably want Apache
 to listen to port 80 and Tomcat on another port and configure the
 mod_jk apache module + the Java-based Connector on the Tomcat end to
 passe the data between the two.

Thanks for clearing that up.
 
 
 
 Yes, one or two pages contain wrong information, the situation is the 
 following:
 - if you can, use apache 2.2.x and mod_proxy_ajp

I'm going to try this. I've already downloaded, compiled and installed
apache 2.2.2 ... if I reach a brick wall I can't surmount I still
have apache 2.0.55 from a Debian install, that I can fall back on and try
your other suggestion.

Thanks a lot ;-)

Regards,
Greg Gamble

 - if you prefer, or have to, use apache 2.0, use mod_jk. In this case,
 I wouldn't use a connector build for another distribution: download
 the source from tomcat's web site and compile following the
 instructions.
 Then you need to setup working entities, i.e Workers, between the
 apache and Tomcat engines using the mandatory workers.properties file
 (A Tomcat worker is a Tomcat instance that is waiting to execute
 servlets or any other content on behalf of some web server).
 Concrete steps are:
 1 Create a workers.properties file in your httpd's configuration folder
 2 Add the module jk to the list of apache modules
 3 modify your httpd.conf to point to the workers file, something like
 JkSet config.file /etc/httpd/workers2.properties
 4 create the jk.properties file in your tomcat root.
 5 (optional) Create an apache virtual host dedicated to tomcat,
 something like:
 VirtualHost myhost:80
ServerAdmin [EMAIL PROTECTED]
ServerName myhost
 
DocumentRoot /opt/jakarta/tomcat/webapps
 
ErrorLog /var/log/httpd/myhost-error_log
CustomLog /var/log/httpd/myhost-access_log combined
 
 Location /*
   JkUriSet worker ajp13:localhost:8009
 /Location
 
 /VirtualHost


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Redeploying a war file from a build script

2006-06-01 Thread Tim Lucia
Here is what I do:

target
name=deploy-context
description=Reload the given context
fail unless=tomcat.usernameUndefined: tomcat.username/fail
fail unless=tomcat.passwordUndefined: tomcat.password/fail
fail unless=tomcatURLUndefined: tomcatURL/fail
echo taskname=deploy-context
Deploying ${basedir}/${project.war} to ${tomcatURL}
/echo
undeploy
failonerror=false
taskname=deploy-context
username=${tomcat.username}
password=${tomcat.password}
url =${tomcatURL}
path=//
deploy
taskname=deploy-context
username=${tomcat.username}
password=${tomcat.password}
url =${tomcatURL}
path=/
war =file:${basedir}/${project.war}/
/target

The key is failonerror=false for the undeploy task.

Tim


-Original Message-
From: William Press [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, May 31, 2006 7:41 PM
To: users@tomcat.apache.org
Subject: Redeploying a war file from a build script

I am writing a build script that would redeploy a war file at the end of
the build.

 

If I use DeployTask and the application was already deployed from a
previous build, I get an error.

 

If I use UndeployTask first and the application is not already deployed
(which would happen the first time somebody runs the script on their
machine or if there's a failure between calls to UndeployTask and
DeployTask), I get an error.

 

I would like the script to be robust enough that it doesn't require the
user to do more than install Tomcat (and my distro, natch) on their
machine.

 

I thought ListTask useful, here, but I've read through the docs and
could not figure out how to capture the output for parsing (so I could
check whether this particular application is already deployed).

 

Any thoughts would be helpful,

Bill



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat as a standalone webserver. Why not?

2006-06-01 Thread Gaël Lams

Hi,


I wondering if it's really so good to use Tomcat behind a real web
server like Apache or IIS.

In my Tomcat 5 book there are two reasons to do it so:

1. Tomcat is not as secure as common web servers, especially if you
want  to use CGI and SSI (I don't think I want to)

2. Tomcat is slow delivering static content.

Well, as long it's just planned to use only 1 server for my application,
I don't think the both points are true for me. On the Tomcat site
there's a note about performance:
...


Not an easy question, I think that the answer to your question is a
mix of personal preferences and, taking into account your application
specifications, whether or not you need from apache something that you
can't have with Tomcat.

I personally started with an apache/tomcat/connector configuration
because the same servers were already serving php/mysql and cgi
applications. We moved then all the tomcat/jsp stuff to its own
servers and I decided to remove apache because:
- it was not required anymore (reason number one) and for me, the
simpler you keep things, the more robust they are. Also, I'm quite
paranoid and for me the less stuff you installed, the better
- I had some problems with the mod_jk (timeouts)
- we are not serving static content

Regards,

Gaël


Re: Tomcat as a standalone webserver. Why not?

2006-06-01 Thread Danny Lee

Hi Tim,

Thanks for your answer. I see your point about Apache more convenient 
for hackers, than Tomcat.


About outage message. This is of course a problem running Tomcat as 
standalone, but I have the control over WebServer IP through the 
firewall, so i just start some Show we're down message servlet on the

mmm... mailserver and if needed rewrite the current webserver IP :)



Cheers,

Danny


Tim Funk wrote:
...
Personally - I like having apache in front of tomcat because I find it 
easier to do CGI, static content directory aliasing, and the volume of 
available modules to be very convenient. It also allows my site to be up 
with a higher uptime since I can restart / replace a tomcat and in those 
periods of downtime - I can reconfigure apache to have an outage message.


YMMV

-Tim



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat as a standalone webserver. Why not?

2006-06-01 Thread Danny Lee

Hi,

thanks for the answer! I am paranoid AND lazy, so I totally see
your point :))

Cheers,

Danny

Gaël Lams wrote:

Also, I'm quite
paranoid and for me the less stuff you installed, the better
- I had some problems with the mod_jk (timeouts)
- we are not serving static content

Regards,

Gaël



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat as a standalone webserver. Why not?

2006-06-01 Thread Mark Hagger
As it happens I can't really begin to count the number of times we've
applied hacks at the Apache level to work around code bugs (did I say
bug?  I meant feature...).  Although to be fair most of these are caused
by users/customers doing odd things outside the spec of the current
code.

We also deal heavily with accesses from mobile phones, each one of which
has new and interesting features in its web browser, some of which just
can't be easily dealt with without direct control over the
request/response headers which Apache makes easy.

But more generally another big win we have found is the ability to
fairly easily have Apache catch certain requests (ie for specific users)
and hand them off to development/staging systems rather than the
production systems.  This is used quite often in our test/release cycle,
and avoids having to have the production system tomcat layer even know
that such hacky stuff is going on, whilst outside users can't
necessarily know which back-end system they are using.

Mark


On Thu, 2006-06-01 at 16:30 +0200, Danny Lee wrote:
 Hi!
 
 Thanks for your answer. I use url-rewrite magic servlet (analog to
 apache mod_rewrite), so I have the same on the fly rewrite 
 functionality (the rewrite-rules.xml is checked every minute or somth).
 
 I do all the request/response stuff in Tomcat as long it's relevant
 and a part of the system I don't want to move a part of functionality
 to Apache, I prefer having all-in-one solution (this is why I use
 Quartz for scheduled tasks and not some chron-jobs).
 
 And I can't see the connection, why my code have to be perfectly bug 
 free? I mean, if I do have bugs Apache wont come and save my ass right? :))




This email has been scanned for all known viruses by the MessageLabs SkyScan 
service.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat as a standalone webserver. Why not?

2006-06-01 Thread Wade Chandler
--- Ga�l Lams [EMAIL PROTECTED] wrote:

 Hi,
 
  I wondering if it's really so good to use Tomcat
 behind a real web
  server like Apache or IIS.
 
  In my Tomcat 5 book there are two reasons to do it
 so:
 
  1. Tomcat is not as secure as common web servers,
 especially if you
  want  to use CGI and SSI (I don't think I want to)
 
  2. Tomcat is slow delivering static content.
 
  Well, as long it's just planned to use only 1
 server for my application,
  I don't think the both points are true for me. On
 the Tomcat site
  there's a note about performance:
  ...
 
 Not an easy question, I think that the answer to
 your question is a
 mix of personal preferences and, taking into account
 your application
 specifications, whether or not you need from apache
 something that you
 can't have with Tomcat.
 
 I personally started with an apache/tomcat/connector
 configuration
 because the same servers were already serving
 php/mysql and cgi
 applications. We moved then all the tomcat/jsp stuff
 to its own
 servers and I decided to remove apache because:
 - it was not required anymore (reason number one)
 and for me, the
 simpler you keep things, the more robust they are.
 Also, I'm quite
 paranoid and for me the less stuff you installed,
 the better
 - I had some problems with the mod_jk (timeouts)
 - we are not serving static content
 
 Regards,
 
 Ga�l
 
As far as static content goes I don't think Apache is
really faster, it will probably use less memory, but
faster is in the details.  At least not with the more
recent Tomcat versions.  5.x.x versions that is.  I
think for anyone to say otherwise they need to have
proof readily available and it be comprehensively
comparative (or at least more than 1 configuration)
... not just some conceived notion that compiled C
code is going to run faster than Java code (look at
Transmeta processors if you need another example of a
virtual machine and speed improvements
http://www.transmeta.com/efficeon/codemorphing.html
just for an example native vs. non-native and which is
faster are all in the details as well).  The java heap
works differently from the C heap, and native
instructions at runtime are organized differently. 
Some things are faster in Java and some are faster in
C (depending on the optimizations of the java runtime
and hardware ... obviously a purely interpreted
runtime would be slower).  

Some information on the whole Java C thing:
http://www.idiom.com/~zilla/Computer/javaCbenchmark.html

For information about the Apache/Tomcat debate see:
http://tomcat.apache.org/faq/performance.html#faster

I think the main point and answer comes down to Gael's
email (personal preferences and needs/which provides
you the services and configurations you need).

Wade

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tomcat as a standalone webserver. Why not?

2006-06-01 Thread Andrew Miehs
If you are running a big site with multiple servers, you do NOT want  
to run

Apache in front of your Tomcats -

All that you do is increase latency, and half your performance. The HTTP
connector in TC 5.x is more than adequate to deal with heavy traffic  
loads.


To be honest, I try not to use Apache at all any more, and tend  
towards lighttpd

- depending of course on the requirements.

We deliver our images via a separate url ie: img.domain.com and  
www.domain.com.


We have the images delivered via a lighttpd, and our dynamic content  
delivered
via tomcat - we currently do our load balacing with an F5 BigIP for  
these two
fully qualified host names. Yes - you can do all sorts of snazzy  
things with
a proxy (like apache and mod_proxy/ mod_jk) out front - but I do not  
think

it is worth the cost of the performance that is lost...

We did some tests 2 years ago for our system and discovered, with  
Apache and TC

running on the same machine

With mod_jk, apache 2.0 and TC 5.0
50 requests/ sec

With just TC5.0
100 request/ sec

...

As for security - you have TC running in both cases - mod_jk passes  
the requests

unfiltered straight through

Therefore by adding Apache, you are only adding something else to go  
wrong -

be broken - not solving any problems...

Andrew


On 01/06/2006, at 5:39 PM, Nikola Milutinovic wrote:


--- Tim Funk [EMAIL PROTECTED] wrote:

Personally - I like having apache in front of tomcat because I  
find it easier


to do CGI, static content directory aliasing, and the volume of  
available
modules to be very convenient. It also allows my site to be up  
with a higher

uptime since I can restart / replace a tomcat and in those periods of
downtime - I can reconfigure apache to have an outage message.


Hi Tim.

And all of you out there. There is one thing that keeps bothering  
me. I AM a
configuration fanatic and when I build my own version of Apache  
(Tru64 UNIX, in
case anyone is screaming use RPM!), I tend to build it loaded  
with modules,

mod_jk1/2 included.



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Farm Deployer looping

2006-06-01 Thread Filip Hanik - Dev Lists

Can you provide more information around your problem.
There was a big change in the farm deployer between 5.0 and 5.5, and I 
am no longer sure on how it works, but I am more than happy to work 
through your issues with you.


Filip


Edoardo Causarano wrote:
Hello list, I have a 3 node farm testbed. Copying a distributable war (the 
servlet-examples and jsp-examples demo apps with a distributable / tag in 
the web.xml) to the war-listen directory of one of the members causes the 
following log:


INFO: check cluster wars at /srv/cluster01/war-listen
Jun 1, 2006 6:44:43 PM org.apache.catalina.cluster.deploy.FarmWarDeployer 
fileModified
INFO: Installing webapp[/jsp-examples] 
from /srv/cluster01/war-deploy/jsp-examples.war
Jun 1, 2006 6:44:43 PM org.apache.catalina.cluster.deploy.FarmWarDeployer 
remove

INFO: Cluster wide remove of web app /jsp-examples

What could be the cause of this?
e

  



--


Filip Hanik

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Webapp reload failing, but restarting tomcat allows webapp to load fine

2006-06-01 Thread Martin Gainty
If you check the logs ..more than likely you may be trying to pull a class that 
is not on classpath or maybe an aberrant configuration
abeerant config is servlet-mapping may be munged in web.xml 
HTH,
Martin --
*
This email message and any files transmitted with it contain confidential
information intended only for the person(s) to whom this email message is
addressed.  If you have received this email message in error, please notify
the sender immediately by telephone or email and destroy the original
message without making a copy.  Thank you.



- Original Message - 
From: David Wall [EMAIL PROTECTED]
To: Tomcat Users List users@tomcat.apache.org
Sent: Thursday, June 01, 2006 2:51 PM
Subject: Webapp reload failing, but restarting tomcat allows webapp to load fine


 It seems there's something that's gone wrong between TC 5.5.12 and TC 
 5.5.17 as it relates to reloading webapps through the Manager app.  I 
 upgraded to get the fix related to webapp reloads for listeners, and 
 that seemed to work (on restart with a new web.xml, it didn't call the 
 listeners from the previous web.xml anymore). 
 
 But I now get an odd error on restart related to decryption via JCE.  
 I've not been able to track down why this is occuring, but it seems to 
 be related to some sort of context/classpath issue on the reload.  This 
 can be seen in that when I start tomcat, all of my webapps load fine.  
 If I click to reload a webapp via the Manager, that webapp will fail.  
 If I then restart tomcat, that webapp loads fine again.
 
 Is this a known issue?  It may be related to other issues I've run into 
 with respect to JCE providers on reloads that did not occur in 5.5.12.
 
 Thanks,
 David
 
 -
 To start a new topic, e-mail: users@tomcat.apache.org
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]
 


Re: Tomcat as a standalone webserver. Why not?

2006-06-01 Thread Peter Lin

I'm gonna say that's quite a bit of myth here. If SSL is important, get a
cheap SSL enabled router. Doing software SSL is waste of CPU power and
impacts the server's stability.  Anyone that has a lot of HTTPS traffic
shouldn't be using software SSL in my bias opinion.  If you are so desparate
that you need software SSL, as remy says, there's APR.  no need to stick
apache httpd infront.

my bias 2 bits on this topic

peter

On 6/1/06, Remy Maucherat [EMAIL PROTECTED] wrote:


On 6/1/06, Michael Echerer [EMAIL PROTECTED] wrote:
 Danny Lee wrote:
  Hi guys!
 
  I wondering if it's really so good to use Tomcat behind a real web
  server like Apache or IIS.
 

 In case you have a lot of HTTPS traffic, you'll find that having Apache
 handle SSL is faster than the Java implementation that Tomcat can offer.

 IMHO for HTTP traffic performance is almost comparable as long as you
 don't need 100% perf, but for HTTPS Apache is definitely better already
 with not so many concurrent requests.

Great post. And now, for the real information:
http://tomcat.apache.org/tomcat-5.5-doc/apr.html

:)

--
x
Rémy Maucherat
Developer  Consultant
JBoss Inc
x

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Embedded Tomcat does not read META-INF/context.xml?

2006-06-01 Thread Kai Wei

I'm running Tomcat 5.5.7 in embedded mode, i.e., starting Tomcat using
the org.apache.catalina.startup.Embedded class. For some reason, the
JNDI resource I configured in
$tomcat_home/webapps/my_webapp/META-INF/context.xml is not created
when Tomcat starts. Your help will be greatly appreciated!!

The following is the code that I use for starting Tomcat:

  Embedded tomcat = new Embedded();

  // create an Engine
  Engine catalina = tomcat.createEngine();
  catalina.setName(Catalina);
  catalina.setDefaultHost(localhost);

  // create Host
  StandardHost localhost = (StandardHost)
tomcat.createHost(localhost, webapps);

  // add host to Engine
  catalina.addChild(localhost);

  // create application Context
  StandardContext appCtx = (StandardContext)
tomcat.createContext(/gc, gc);

  // make the web app's class loader use the normal delegation
model to search for classes
  appCtx.setDelegate(true);

  // add context to host
  localhost.addChild(appCtx);

  // add new Engine to set of Engine for embedded server
  tomcat.addEngine(catalina);

  // create HTTP Connector
  Connector httpConnector =
tomcat.createConnector((java.net.InetAddress)null, 8080, false);
  IntrospectionUtils.setProperty(httpConnector, redirectPort, 8443);

  // add new Connector to set of Connectors for embedded server,
associated with Engine
  tomcat.addConnector(httpConnector);

  // create HTTPS Connector
  Connector httpsConnector =
tomcat.createConnector((java.net.InetAddress)null, 8443, true);
  httpsConnector.setScheme(https);
  IntrospectionUtils.setProperty(httpsConnector, sslProtocol, TLS);
  IntrospectionUtils.setProperty(httpsConnector, keypass, changeit);
  IntrospectionUtils.setProperty(httpsConnector, keystore,
emf.keystore);

  // add new Connector to set of Connectors for embedded server,
associated with Engine
  tomcat.addConnector(httpsConnector);

  // start operation
  try {
  tomcat.start();
  } catch (org.apache.catalina.LifecycleException ex) {
  ex.printStackTrace();
  }

As you can see from the code, we have one web app called gc running
inside Tomcat. Under the $tomcat_home/webapps/gc directory, we have a
META-INF/context.xml file that defines one JNDI resource (a
javax.sql.DataSource object):

Context docBase=gc
   path=/gc
   crossContext=true reloadable=true debug=1
   workDir=work/Catalina/localhost/gc
Resource
  name=jdbc/gc
  auth=Container
  description=GC DataSource Reference
  type=javax.sql.DataSource
  factory=com.good.gc.common.util.GCTomcatDataSourceFactory
  driverClassName=org.postgresql.Driver
  url=jdbc:postgresql://localhost:5432/gc
  username=postgres
  maxIdle=2
  maxWait=-1
  maxActive=4
  validationQuery=select now()
  /
/Context

We use the Spring Framework (version 1.2.3 I believe) for the gc
webapp, and inside the spring context config file, we try to grab the
DataSource from the java:comp/env context this way:

  bean id=myDataSource
  class=org.springframework.jndi.JndiObjectFactoryBean
  property name=jndiName
valuejava:/comp/env/jdbc/gc/value
  /property
  /bean

Everything used to work just fine when we used Tomcat in standalone
mode. But now that we switched to embedded mode, we got the following
error when starting Tomcat up:

2006-06-01 15:02:15,448 ERROR main org.apache.catalina.core.ContainerBase.[Catal
ina].[localhost].[/gc] - Exception sending context initialized event to listener
instance of class org.springframework.web.context.ContextLoaderListener
org.springframework.beans.factory.BeanCreationException: Error creating bean wi
th name 'myDataSource' defined in ServletContext resource [/WEB-INF/springContex
tConfig.xml]: Initialization of bean failed; nested exception is javax.naming.Na
mingException: Cannot create resource instance
javax.naming.NamingException: Cannot create resource instance
  at org.apache.naming.factory.ResourceEnvFactory.getObjectInstance(Resour
ceEnvFactory.java:113)
  at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:3
04)
  at org.apache.naming.NamingContext.lookup(NamingContext.java:792)
  at org.apache.naming.NamingContext.lookup(NamingContext.java:139)
  at org.apache.naming.NamingContext.lookup(NamingContext.java:780)
  at org.apache.naming.NamingContext.lookup(NamingContext.java:139)
  at org.apache.naming.NamingContext.lookup(NamingContext.java:780)
  at org.apache.naming.NamingContext.lookup(NamingContext.java:139)
  at org.apache.naming.NamingContext.lookup(NamingContext.java:780)
  at org.apache.naming.NamingContext.lookup(NamingContext.java:152)
  at org.apache.naming.SelectorContext.lookup(SelectorContext.java:136)
  at 

Re: Webapp reload failing, but restarting tomcat allows webapp to load fine

2006-06-01 Thread David Wall
On reading more in the release notes 
(http://tomcat.apache.org/tomcat-5.5-doc/RELEASE-NOTES.txt), I figured 
I'd give the shared/lib idea a try.  I found that just by moving the 
BouncyCastle JCE jar into shared/lib and out of the WEB-INF/lib of the 
various webapps, all seems to work okay.


On another note, I tried moving log4j's JAR into shared/lib, but it 
didn't seem to work.  Even though each webapp has its own 
log4j.properties file in the WEB-INF/classes, with each pointing to a 
distinct log, when the log4j jar was put in shared/lib, all of the 
output from all of the webapps went into the same file.  So it seems to 
have some static initializations too that introduce this oddity.


David


David Wall wrote:

Martin,

Thanks for your suggestion, but it's unlikely that web.xml was 
misconfigured just because of this TC upgrade (it wouldn't have needed 
to change).  Also, when I restart tomcat (rather than just reload via 
the manager), the webapp comes up just fine.  It's only on a reload 
that things fail, and they didn't even fail under 5.5.12, but do under 
5.5.17.  It seems very likely this is related to a TC bug when 
contexts are being reloaded with some classpath-related issue 
remaining.  I know that such classpath issues can be tricky when the 
webapp has to be dropped from the running JVM and then later added 
back in.


David



Martin Gainty wrote:
If you check the logs ..more than likely you may be trying to pull a 
class that is not on classpath or maybe an aberrant configuration

abeerant config is servlet-mapping may be munged in web.xml HTH,
Martin --


- Original Message -  
It seems there's something that's gone wrong between TC 5.5.12 and 
TC 5.5.17 as it relates to reloading webapps through the Manager 
app.  I upgraded to get the fix related to webapp reloads for 
listeners, and that seemed to work (on restart with a new web.xml, 
it didn't call the listeners from the previous web.xml anymore).
But I now get an odd error on restart related to decryption via 
JCE.  I've not been able to track down why this is occuring, but it 
seems to be related to some sort of context/classpath issue on the 
reload.  This can be seen in that when I start tomcat, all of my 
webapps load fine.  If I click to reload a webapp via the Manager, 
that webapp will fail.  If I then restart tomcat, that webapp loads 
fine again.


Is this a known issue?  It may be related to other issues I've run 
into with respect to JCE providers on reloads that did not occur in 
5.5.12.


Thanks,
David



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: NetBeans 5.0 and Tomcat 5.5.16 ... Please Help

2006-06-01 Thread vineesh kumar

You can use eclipse with Exadelstudio plugin, which is freely
available. The newest version is 3.2, I think.
The problem may be u may not compiled the project correctly and deployed.
And here u r not specyfying anything like the mechanism u r using, to
connect 2 the remote server.I assume u r uisng jdbc.

On 6/1/06, Vijaya [EMAIL PROTECTED] wrote:

Hi,

I downloaded NetBeans 5,0 and tomcat 5.5.16. I want to connect to a
remote SQL Server. I am using jtds. I am not successful in using both
NB50 and Tomcat 5.5.16 together. NB5.0 comes with bundled tomcat 5.5.9
and if I use this, I get a '404 error' while accessing the remote
sql*server.

Can someone help me on this? Is there a problem with NetBeans 5.0?

Is there any other IDE can I use?

Lastly, is there a tomcat user group in Bangalore, India?

Thanks in advance for your help.

Vijaya





--
Vineesh Kumar
Software Engineer
ISS-RnD Department
HCL infosystems Ltd
Cochin

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



JNDI Datasource in embedded 5.0.28 ?

2006-06-01 Thread John Menke

Does anyone know how to configure JNDI Datasource in 5.0.28

Google GWT uses embedded 5.0.28 in hosted and nobody seems to know how to
configure a datasource on the GWT list.

It would be greatly appreciated if anyone could show me how to configure
this. (GWT is basically useless to me without a connection to my DB -- can't
believe the guys at google don't have docs on this themselves...)


-jm


Re: NetBeans 5.0 and Tomcat 5.5.16 ... Please Help

2006-06-01 Thread Wade Chandler
--- Vijaya [EMAIL PROTECTED] wrote:

 Hi,
  
 I downloaded NetBeans 5,0 and tomcat 5.5.16. I want
 to connect to a
 remote SQL Server. I am using jtds. I am not
 successful in using both
 NB50 and Tomcat 5.5.16 together. NB5.0 comes with
 bundled tomcat 5.5.9
 and if I use this, I get a '404 error' while
 accessing the remote
 sql*server.
  
 Can someone help me on this? Is there a problem with
 NetBeans 5.0? 
  
 Is there any other IDE can I use?
  
 Lastly, is there a tomcat user group in Bangalore,
 India?
  
 Thanks in advance for your help.
  
 Vijaya
 

One, your question is terribly vague.  I get a 404
when  accessing the remote sql server?  Are you trying
to connect to a JSP page under your Tomcat?  Are you
running the web application in Netbeans?  Did NB
launch your external browser and point you to the
running Tomcat instance address and port?  Are you
running a different version of Tomcat then the one
that shipped with it?  Are you actually running it in
Netbeans?  Have you ever used JDBC and jTDS together
and that is working fine?  Have you gotten it working
in other web applications period?  I'm on both this
list and the NB list.  You can ask your question
there, but if it comes down to something with your
configuration and Tomcat you might be directed back
here.  Ask on [EMAIL PROTECTED] (you'll need to
sign up for the list).  You'll need to provide some
common sense basics though to help someone help you.

Wade

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: NetBeans 5.0 and Tomcat 5.5.16 ... Please Help

2006-06-01 Thread Rajeev N. Jha
There are just too many things involved here. A better approach would be 
to get the pieces working separately.

step by step
1) connect to DB using a stand-alone program
2) connect to some example servlet in tomcat
3) now use tomcat bundled with netbeans
4) Then only attempt to put all the pieces together.

Thanks

vineesh kumar wrote:

You can use eclipse with Exadelstudio plugin, which is freely
available. The newest version is 3.2, I think.
The problem may be u may not compiled the project correctly and deployed.
And here u r not specyfying anything like the mechanism u r using, to
connect 2 the remote server.I assume u r uisng jdbc.

On 6/1/06, Vijaya [EMAIL PROTECTED] wrote:

Hi,

I downloaded NetBeans 5,0 and tomcat 5.5.16. I want to connect to a
remote SQL Server. I am using jtds. I am not successful in using both
NB50 and Tomcat 5.5.16 together. NB5.0 comes with bundled tomcat 5.5.9
and if I use this, I get a '404 error' while accessing the remote
sql*server.

Can someone help me on this? Is there a problem with NetBeans 5.0?

Is there any other IDE can I use?

Lastly, is there a tomcat user group in Bangalore, India?

Thanks in advance for your help.

Vijaya








-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: tomcat ssl not working

2006-06-01 Thread Jack

You can have a look here and see if you find any useful tips - this
explains how I got SSL to work on Tomcat:

http://jack.godau.googlepages.com/jbosscertificatesandopenssl

Cheers
Jack...

On 01/06/06, Mike Sabroff [EMAIL PROTECTED] wrote:

I am running 5.5.9 and have no problems with it (except that it is
expired) but it still works if I accept it.

Mike

AJ Jonen wrote:
 My tomcat server is not responding when I type in https://localhost:8443.
 oddly enough it does work when I type in http://localhost:8443

 I'm having a bit of an issue getting Tomcat to work on the secure port
 8443.   What happens is I type https://localhost:8443 and the page
 never loads.  I get no errors (page cannot be found, page cannot be
 displayed etc).  My browser simply looks like it's loading the page,
 it eventually says that it's done, but my browser home page is still
 displayed.

 - The unsecure port (port 8090 in my case, because port 8080 was
 already in use) works fine.
 - I generated my keystore file, presumably correctly (I was prompted
 to enter my name, organization, location, etc), and it is in the
 correct location (C:\Program Files\Apache Software Foundation\Tomcat
 5.5\conf).
 - Kathy O. looked at my server.xml page and says that everything looks
 correct.  Everything looks right to me too.
 - I am using Tomcat 5.5 and I am using the correct java version (1.5,
 not 1.4).

 Any ideas on what might be preventing the page from loading correctly
 on the secure port?

 Rebecca


 -
 To start a new topic, e-mail: users@tomcat.apache.org
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]


--
Mike Sabroff
Web Services Developer
[EMAIL PROTECTED]
920-568-8379


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Cheers
Jack...

The claim natural is not synonymous with safe.

-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: SSL Setup

2006-06-01 Thread Jack

You can have a look here and see if you find any useful tips - this
explains how I got SSL to work on Tomcat:

http://jack.godau.googlepages.com/jbosscertificatesandopenssl

Cheers
Jack...

On 31/05/06, [EMAIL PROTECTED] [EMAIL PROTECTED] wrote:

Hello.  I'm setting up SSL.  I have Tomcat 5.5.16.  The error that I'm getting 
is that it can't locate my keystore file.  I have using the keystorefile 
attribute but its still not working.  Can anyone help?

Ro


-
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]