Tomcat Deploy issue with v 5.0.30

2005-09-06 Thread Aaron Pederson
Hello -

 

I'm running into an autodeploy issue with Tomcat 5.0.30.

 

 

In our tomcat install we are running two applications both of which are
.war archives and reside in $TOMCAT_HOME/webapps/.   The issue I'm
seeing is when I run a fresh install of tomcat and drop in our
application .war files, on the initial startup and before Tomcat is
fully up I try to access the url to either one of the applications,
Tomcat seems to stop deploying the application files at random times
(sometimes WEB-INF files, sometimes .css, or .js files). Even on a
restart Tomcat does not redeploy the missing files.  

 

I've tried not unpacking the .war  by setting unpackWARs=false, in my
server.xml files.  Under this condition, if I starting hitting an
application URL before tomcat is fully started up, Tomcat seems not to
register the welcome-file-list, in the application web.xml and is
displaying the tomcat's directory structure.

 

Setup:

 

OS: Windows

Version 5.0.30

 

Tomcat is installed at C://Program Files/Company/tomcat/ and is
installed each time the our product is.

 

 



 

Has anyone seen this issue and/or found a solution?  

 

Will adding a context.xml files to each of my META-INF solve the issue?

 

 

Any help, suggestions would be much appreciated. 

 

 

Thanks,

~Aaron Pedersen 

 

 



RE: Tomcat Deploy

2005-03-21 Thread Allistair Crossley
Hi Geoff,

The general concensus I believe is to use a combination of Ant and source 
control (CVS, VSS). In our case, we have 4 developers all with Eclipse and 
local workstation Tomcat instances. We all check in to VSS via the VSS Plugin 
in Eclipse.

When we wish to perform a staging or production build, we have written an Ant 
build.xml file to handle deployment. For staging, our Ant script copies JSPs, 
classes and resources only, nothing fancy. The staging server detects the class 
changes and reloads the web app and we can test. For production, our Ant script 
packages everything up as a WAR file which we then deploy by copying into the 
production webapps folder. You can also use the Tomcat deploy manager tool for 
this, adn I believe there are also some Tomcat specific Ant commands. But in 
general, Ant is what you need and some form of source control is a must esp. on 
multi-dev projects.

Allisatir.

 -Original Message-
 From: Geoff Wiggs [mailto:[EMAIL PROTECTED]
 Sent: 21 March 2005 02:41
 To: tomcat-user@jakarta.apache.org
 Subject: Tomcat Deploy
 
 
 Quick question on deploying to Tomcat and Eclipse 
 integration.  If it's too
 far off topic I apologize in advance.
  
 The IDS is stellar for deploying to a single server.  I 
 personally have it
 deploying to Tomcat running on my workstation.  What approach 
 should I take
 for deploying to the production server?  Do I need to get 
 into a CVS of some
 sort?  Or is there a way to set up an alternate installation to allow
 deployment from the IDE to the Production server?
  
 Geoff 
 [EMAIL PROTECTED]
 www.orcastech.com
  
 


FONT SIZE=1 FACE=VERDANA,ARIAL COLOR=BLUE 
---
QAS Ltd.
Developers of QuickAddress Software
a href=http://www.qas.com;www.qas.com/a
Registered in England: No 2582055
Registered in Australia: No 082 851 474
---
/FONT


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Tomcat Deploy

2005-03-20 Thread Geoff Wiggs
Quick question on deploying to Tomcat and Eclipse integration.  If it's too
far off topic I apologize in advance.
 
The IDS is stellar for deploying to a single server.  I personally have it
deploying to Tomcat running on my workstation.  What approach should I take
for deploying to the production server?  Do I need to get into a CVS of some
sort?  Or is there a way to set up an alternate installation to allow
deployment from the IDE to the Production server?
 
Geoff 
[EMAIL PROTECTED]
www.orcastech.com
 


RE: [tomcat] deploy simple HTTP doPost servlet to tomcat 5.0.28

2004-10-01 Thread Ernesto Echeverría
Without examining details in your message I can ask:

Structure should be (maybe it is already?)

Webapp
  WEB-INF
web.xml
classess
lib

Etc. 

Then, shouldn't be you calling

http://localhost:8080/webapp/XML_RPC_Testserveur

Instead?

Regards.


José Ernesto Echeverría
[EMAIL PROTECTED]

 

-Original Message-
From: Christian Ruediger [mailto:[EMAIL PROTECTED] 
Sent: Viernes, 01 de Octubre de 2004 08:56 a.m.
To: Tomcat Users List
Subject: [tomcat] deploy simple HTTP doPost servlet to tomcat 5.0.28

Hi folks,
after trying the complex aproach without any success, I started a lowtech
approach. I simply want a small servlet deployed. Can't be too complicated.

What I have:
Apache Tomcat 5.0.28 Server
Win 2000
j2sdk1.4.2_05

I constructed the following structure in tomcats webapp folder:

webapp -
   - classes
   - testserveur
   - XML_RPC_Servlet.class
   - libs
   - web.xml

(dont bother the name XML_RPC_Servlet.its for future purposes.
currently only text is displayed - see code below)

web.xml is as follows:

!DOCTYPE web-app PUBLIC -//Sun Microsystems, Inc.// DTD WebApplication
2.2//EN
http://java.sun.com/j2ee/dtds/web-app_2.2.dtd;

web-app xmlns=http://java.sun.com/xml/ns/j2ee;
xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance;
xsi:schemaLocation=http://java.sun.com/xml/ns/j2ee
http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd;
version=2.4

display-nameTestservlet/display-name
context-parameter
param-nameLieblingsfarbe/param-name
param-valuerot/param-value
/context-parameter
servlet
  servlet-nameXML_RPC_Testserveur/servlet-name
  servlet-class
testserveur.RPC_XML_Servlet
  /servlet-class
/servlet
servlet-mapping
  servlet-nameXML_RPC_Testserveur/servlet-name
  url-pattern/XML_RPC_Testserveur/url-pattern
/servlet-mapping
/web-app

code is as follows:

public class XML_RPC_Servlet extends HttpServlet{



protected void doGet(HttpServletRequest req,
 HttpServletResponse res)
  throws ServletException, IOException
   {
 res.setContentType(text/html);
 PrintWriter out = res.getWriter();
 out.println(HTMLHEADTITLEHello There!/TITLE+
 /HEADBODYHello There!/BODY/HTML);
 out.close();
   }
   
public String getServletInfo()
   {
 return HelloClientServlet 1.0 by Stefan Zeiger;
   }
}

What i did:
-Started Tomcat (is configured to localhost:8080) -opened Browser -typed
http://localhost:8080/XML_RPC_Testserveur

- got only a message that the resource is unavailable (in french):

*
type Rapport d'état
message /XML_RPC_Testserveur
description La ressource demandée (/XML_RPC_Testserveur) n'est pas
disponible.
**

I am searching for a reason of this for nearly a day.
Is there anyone who can help me?

Thanx Christian

-
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]



Tomcat deploy remote WAR via http

2004-06-15 Thread michael_simpson
I'm running Tomcat 5.0. I'm trying to deploy a remote WAR file to my 
tomcat using the ManagerServlet's html commands. Since the WAR file is not 
on the local disk of the tomat server, I'm sending it a callback http URL 
to download the WAR file but it is not working. (I'm trying to automate 
pushing out builds from a build machine to target servers).

I'm refering to this info:

http://jakarta.apache.org/tomcat/tomcat-4.1-doc/catalina/docs/api/org/apache/catalina/servlets/ManagerServlet.html
Where it explains that I can send arguments to the deploy command:
/install?path=/xxxwar={war-url} 
where {war-url} can be:
jar:http://hostname:port/path/to/a/warfile.war!/ 

Given that, I construct a URL to send to the manager servlet:

http://myhost:8080/manager/html/deploy?deployPath=/bdm2deployWar=jar:http://localhost:8080/bdm/bdm.war!/
And I promptly get the error:
FAIL - Encountered exception java.lang.IllegalArgumentException: Invalid 
URL for web application archive: http://localhost:8080/bdm/bdm.war

In the log, I pull the stack trace:

java.lang.IllegalArgumentException: Invalid URL for web application 
archive: http://localhost:8080/bdm/GetWar?file=bdm.war
at 
org.apache.catalina.core.StandardHostDeployer.install(StandardHostDeployer.java:215)
at 
org.apache.catalina.core.StandardHost.install(StandardHost.java:832)
at 
org.apache.catalina.manager.ManagerServlet.deploy(ManagerServlet.java:922)
at 
org.apache.catalina.manager.HTMLManagerServlet.deployInternal(HTMLManagerServlet.java:273)
at 
org.apache.catalina.manager.HTMLManagerServlet.doGet(HTMLManagerServlet.java:97)
[...]

So I pulled the src distribution for 5.0 and looked at 
StandardHostDeployer.java:215
I see lines 210 to 215:
if (url.startsWith(file://))
docBase = url.substring(7);
else if (url.startsWith(file:))
docBase = url.substring(5);
else
throw new IllegalArgumentException
(sm.getString(standardHost.warURL, url));

This expects the URL to begin with file: instead of http:. So it 
appears to me that, contrary to the documentation, Tomcat does not support 
getting a WAR file via http. 

Is that the case, or am I doing this wrong?

Thanks.


Ant - Tomcat deploy question

2003-02-11 Thread John Ruffin

Hi folks,

I'm running TC 4.1.18, ANT 1.5, J2SDK1.4.0_01 on a W2K server - Tomcat is
running as a service.

When ANT places my appName.war file in the Catalina_Home/webapps directory
it doesn't deploy (i.e. unpack).

I stopped and started the Tomcat service, that didn't deploy appName.war.  

However, if I stop the service - delete the webapps/appName folder - execute
the ANT deploy-app command again - this works.

Why?  What am I missing - better yet what do I need to read?  I've read some
archive threads - do I really need to restart TC  or appName using Manager
after deployment?

Please enlighten the newbie...



The information in this email is confidential and may be 
legally privileged. It is intended solely for the addressee,
and access by anyone else is unauthorized.

If you are not the intended recipient, any disclosure, 
copying, distribution or any action taken or omitted to be
taken in reliance on it, is prohibited and may be unlawful. 

If you believe that you have received this email in error, 
please advise us by calling (901) 385 3688, or emailing
[EMAIL PROTECTED], and then delete this message
and all copies and backups thereof. Thank you.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: Ant - Tomcat deploy question

2003-02-11 Thread Sean Dockery
Follow the development environment recommendation set out in the Tomcat
application developers guide, which you can find at
http://jakarta.apache.org/tomcat/tomcat-4.1-doc/appdev/.

After you install your application into Tomcat, you can reload it on
demand without restarting Tomcat.  I had experienced problems with stale
classes staying in memory in the past, but I have not had any problems since
using this new approach.

Quick tip:  If you use the sample build.xml file provided in the Tomcat
AppDev manual, add the following lines to the section where the classpath is
constructed...

fileset dir=${build.home}/WEB-INF/lib
  include name=*.jar/
/fileset

...This will automatically include any JAR files that you have placed in
${web.home}/WEB-INF/lib (and which are subsequently copied to
${build.home}/WEB-INF/lib) into the classpath for you.

Sean Dockery
[EMAIL PROTECTED]
Certified Java Web Component Developer
Certified Delphi Programmer
SBD Consultants
http://www.sbdconsultants.com

- Original Message -
From: John Ruffin [EMAIL PROTECTED]
To: 'Tomcat Users List' [EMAIL PROTECTED]
Sent: Monday, February 10, 2003 15:21
Subject: Ant - Tomcat deploy question



 Hi folks,

 I'm running TC 4.1.18, ANT 1.5, J2SDK1.4.0_01 on a W2K server - Tomcat is
 running as a service.

 When ANT places my appName.war file in the Catalina_Home/webapps
directory
 it doesn't deploy (i.e. unpack).

 I stopped and started the Tomcat service, that didn't deploy appName.war.

 However, if I stop the service - delete the webapps/appName folder -
execute
 the ANT deploy-app command again - this works.

 Why?  What am I missing - better yet what do I need to read?  I've read
some
 archive threads - do I really need to restart TC  or appName using Manager
 after deployment?

 Please enlighten the newbie...


 
 The information in this email is confidential and may be
 legally privileged. It is intended solely for the addressee,
 and access by anyone else is unauthorized.

 If you are not the intended recipient, any disclosure,
 copying, distribution or any action taken or omitted to be
 taken in reliance on it, is prohibited and may be unlawful.

 If you believe that you have received this email in error,
 please advise us by calling (901) 385 3688, or emailing
 [EMAIL PROTECTED], and then delete this message
 and all copies and backups thereof. Thank you.
 


 -
 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]