RE: Servlet Deployment Problem

2003-10-29 Thread Shapira, Yoav

Howdy,

>I've spent 6-8 hours trying to figure out why Tomcat (ver 4.1.27) could
not
>find servlet classes using a standard
>http://localhost:8080/%CATALINA_HOME%/appdir/servlet/ServletName url.

Your first mistake is assuming the above URL is a "standard."  It's not,
and the servlet specification does not mandate that a servlet container
support such URLs.

>The solution was finally found in a devshed forum -- the invoker
servlet
>mapping has been commented out of the conf/web.xml file in the binary
>distribution.
>
>Why

The invoker servlet was disabled for security reasons.  This is in the
release notes for every tomcat version since 4.1.18.  It's also in the
tomcat FAQ (http://jakarta.apache.org/tomcat/faq), and has been
discussed many times on this list (so searching the list archives would
have revealed this information).  Many books, as is nearly always the
case for this field, are out of date.

Yoav Shapira



This e-mail, including any attachments, is a confidential business communication, and 
may contain information that is confidential, proprietary and/or privileged.  This 
e-mail is intended only for the individual(s) to whom it is addressed, and may not be 
saved, copied, printed, disclosed or used by anyone else.  If you are not the(an) 
intended recipient, please immediately delete this e-mail from your computer system 
and notify the sender.  Thank you.


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



RE: Servlet Deployment Problem

2003-10-29 Thread Bodycombe, Andrew
http://jakarta.apache.org/tomcat/faq/misc.html#invoker

-Original Message-
From: Miles, Fiske III [NTWK SVCS] [mailto:[EMAIL PROTECTED] 
Sent: 28 October 2003 20:10
To: [EMAIL PROTECTED]
Subject: Servlet Deployment Problem


I've spent 6-8 hours trying to figure out why Tomcat (ver 4.1.27) could not
find servlet classes using a standard
http://localhost:8080/%CATALINA_HOME%/appdir/servlet/ServletName url.

While trying to run this down I used a stack of JSP development manuals, the
WROX Apache Tomcat manual, and the Jakarta website to no avail. I tried
every conceivable permutation of deployment web.xml file, server.xml file
and app directory structure (carefully following directions from multiple
books).

The solution was finally found in a devshed forum -- the invoker servlet
mapping has been commented out of the conf/web.xml file in the binary
distribution.

Why

My second question is where would documentation for this issue reasonably be
found?

Fiske
(frustrated JSP developer)

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



RE: Servlet deployment problems (Apache 2.0.44 / Jakarta-Tomcat 4.1.18)

2003-02-24 Thread John Trollinger
Are you using jdk 1.4, in 1.4 you can no longer have non packaged
classes.. Also you might need to setup the default servlet as it is
disabled by default for security reasons.  If you do not want to enable
the default servlet you could also create a servlet mapping.

John

> -Original Message-
> From: Lars Nielsen Lind [mailto:[EMAIL PROTECTED] 
> Sent: Monday, February 24, 2003 6:56 AM
> To: Tomcat Users List
> Subject: Servlet deployment problems (Apache 2.0.44 / 
> Jakarta-Tomcat 4.1.18)
> 
> 
> Hi.
> 
> I have some problems with the deployment of servlets with 
> Apahce / Jakarta-Tomcat.
> 
> 1.) I have placed the servlet class in:
> 
> .../webapps//WEB-INF/classes/
> 
> 2.) I have added a web.xml file in:
> 
> .../webapps//WEB-INF/web.xml
> 
> 3.) I have added the following lines to the web.xml file:
> 
> - 
> -Testing
> -Testing
> - 
> 
> 4.) I have then tried to execute the servlet with this:
> 
> - Testing servlet
> 
> and
> 
> - Testing servlet
> 
> but I am always getting a HTTP Status 404 ERR:
> 
> - The requested resource () is not available.
> 
> Any help is appriciated.
> 
> 
> Best regards,
> 
> Lars Nielsen Lind
> 
> 


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



RE: Servlet deployment problems (Apache 2.0.44 / Jakarta-Tomcat 4.1.18)

2003-02-24 Thread Turner, John

Add


  Testing
  /servlet/MyServlet (change this as needed)


to your web.xml below the entry you already made.  The entry you have is
incomplete, there is no URL map.  That's the reason for the 404.

John

-Original Message-
From: Lars Nielsen Lind [mailto:[EMAIL PROTECTED] 
Sent: Monday, February 24, 2003 6:56 AM
To: Tomcat Users List
Subject: Servlet deployment problems (Apache 2.0.44 / Jakarta-Tomcat 4.1.18)


Hi.

I have some problems with the deployment of servlets with Apahce /
Jakarta-Tomcat.

1.) I have placed the servlet class in:

.../webapps//WEB-INF/classes/

2.) I have added a web.xml file in:

.../webapps//WEB-INF/web.xml

3.) I have added the following lines to the web.xml file:

- 
-Testing
-Testing
- 

4.) I have then tried to execute the servlet with this:

- Testing servlet

and

- Testing servlet

but I am always getting a HTTP Status 404 ERR:

- The requested resource () is not available.

Any help is appriciated.


Best regards,

Lars Nielsen Lind


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



SOLVING...seems ok so far. Re: Servlet deployment.

2002-11-20 Thread Triptpal Singh Lamba
Thanks.
The link provides exactly what I wanted.

Tript Singh
- Original Message -
From: <[EMAIL PROTECTED]>
To: "Tomcat Users List" <[EMAIL PROTECTED]>; "Triptpal Singh
Lamba" <[EMAIL PROTECTED]>
Sent: Wednesday, November 20, 2002 4:06 PM
Subject: Re: Servlet deployment.


> See the article,"Deploying Web Applications to Tomcat" at
> http://www.onjava.com/pub/a/onjava/2001/04/19/tomcat.html
> > Hi all.
> > I have worked with iPlanet and other servers but havent really
> > deployed/coded for Tomcat much.
> >
> > I want some expert advise on structure of tomcat applications.
> > I have the current structure :-
> >
> > webapps/examples/jsp has default examples.
> >
> > I started my project say  projectA like this
> >
> > webapps/examples/projectA
> >
> >  I want to ideally take it 1 level up to webapps/projectA. This would
make
> > me do some context settings in some xml files. Which all and how ?
> >
> > The jsp page came up instantly on
> > http://localhost:8080/examples/ProjectA/index.jsp
> >
> > ==
> >
> > Now I have written a servlet  Router.java, how do I get the  jsp above
to
> > submit to this java program. Where do I put the java program in a
project
> > structure in Tomcat and what changes do I make. I tried changing the
> > web.xml  (url patterm etc) in webapps\examples\WEB-INF\web.xml but I
didnt
> > know  how tomcat does this.
> > So coudl someone tell me where I would get an example of how to
configure
> > the xml files to MAP the servlet I write for tomcat.
> >
> > Thanks all
> >
> > Tript Singh
> >
> >
> >
> >
> > --
> > To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
> > For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
> >
>
> --
> To unsubscribe, e-mail:
<mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
<mailto:[EMAIL PROTECTED]>
>
>
>



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




Re: Servlet deployment.

2002-11-20 Thread billfly3
See the article,"Deploying Web Applications to Tomcat" at
http://www.onjava.com/pub/a/onjava/2001/04/19/tomcat.html
> Hi all.
> I have worked with iPlanet and other servers but havent really
> deployed/coded for Tomcat much.
> 
> I want some expert advise on structure of tomcat applications.
> I have the current structure :-
> 
> webapps/examples/jsp has default examples.
> 
> I started my project say  projectA like this
> 
> webapps/examples/projectA
> 
>  I want to ideally take it 1 level up to webapps/projectA. This would  make
> me do some context settings in some xml files. Which all and how ?
> 
> The jsp page came up instantly on
> http://localhost:8080/examples/ProjectA/index.jsp
> 
> ==
> 
> Now I have written a servlet  Router.java, how do I get the  jsp above to
> submit to this java program. Where do I put the java program in a project
> structure in Tomcat and what changes do I make. I tried changing the
> web.xml  (url patterm etc) in webapps\examples\WEB-INF\web.xml but I didnt
> know  how tomcat does this.
> So coudl someone tell me where I would get an example of how to configure
> the xml files to MAP the servlet I write for tomcat.
> 
> Thanks all
> 
> Tript Singh
> 
> 
> 
> 
> --
> To unsubscribe, e-mail:   
> For additional commands, e-mail: 
> 

--
To unsubscribe, e-mail:   
For additional commands, e-mail: 




Re: Servlet deployment without using web.xml?!

2002-01-18 Thread Thomas Åhlen


> Have you considered having your controller servlet dispatch
>to regular old Java code instead of to other servlets? That
>way you can have full control and still stay within the
>servlet spec.

Yes that is an option but it would require something like this

http://mydomain.com/Controller?module=Auth&action=Login

and I want to use

http://mydomain.com/Auth?action=Login


> Otherwise, you're going to have to dig into Tomcat's
>internals. Which is nonportable but fun. Assuming you want
>to mess with Tomcat 4 and haven't already got the source,
>go online and browse the code through CVS. Take a look at
>org.apache.catalina.servlets.InvokerServlet and org.apache
>catalina.core.StandardContext. That's what your up against.

Thanks will take a look :). Sounds fun!

Thomas




--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




Re: Servlet deployment without using web.xml?!

2002-01-18 Thread Christopher K. St. John

"Thomas Åhlen" wrote:
> 
> 1. First I define one servlet(Controller) in the web.xml file
> 2. I want my Controller servlet to be able to add and remove
> servlets(modules) from the application context.
> ...
> Is this possible? I would see no reason to why there couldn't be some
> interface between Tomcat and my servlet that could do this.
> 

 Have you considered having your controller servlet dispatch
to regular old Java code instead of to other servlets? That
way you can have full control and still stay within the
servlet spec.

 Otherwise, you're going to have to dig into Tomcat's 
internals. Which is nonportable but fun. Assuming you want
to mess with Tomcat 4 and haven't already got the source,
go online and browse the code through CVS. Take a look at
org.apache.catalina.servlets.InvokerServlet and org.apache
catalina.core.StandardContext. That's what your up against.

-- 
Christopher St. John [EMAIL PROTECTED]
DistribuTopia http://www.distributopia.com

--
To unsubscribe:   
For additional commands: 
Troubles with the list: 




RE: servlet deployment

2001-05-22 Thread Pernica, Jan

you have to modify web.xml
and add:

HelloWorld
dummy.HelloWorld


HelloWorld
/servlet/dummy/HelloWorld


then you can reference it using the URL you have written

On Tuesday, May 22, 2001 3:43 PM, Montgomery, Kendal L
[SMTP:[EMAIL PROTECTED]] wrote:
> Hello all,
> 
> I am just wandering how I deploy a servlet that is part of a package, and
> how to reference it.  For example.. say you take the HelloWorldExample
> servlet that comes with and modify it.  Rename the source to
> HelloWorld.java, and change the file appropriately, including adding a
line
> at the top:
> 
> package dummy;
> 
> so, it is in the dummy class.
> 
> When I deploy this "new" HelloWorld servlet, I put it in
> ...webapps/examples/WEB-INF/classes/dummy/HelloWorld.class.  Now, to
> reference this, I expected to be able to go to my browser and hit
> http://myserver/examples/servlet/dummy/HelloWorld
>  .  That did not work.
> So, what do I have to do to make this work?
> 
> By the way, I am running Apache 1.3.19 and Tomcat 3.2.1.fasdf
> 
> Thanks..
> 
> Kendal L. Montgomery
> Qwest - eFlow Development Team
> 614-215-4937


__
Tato komunikace je urcena vyhradne pro adresata a je duverna. 
This communication is intended solely for the addressee and is confidential.






RE: servlet deployment

2001-05-22 Thread Montgomery, Kendal L

Thank you... that worked... for some reason I didn't even think to use the
full class name.



Kendal L. Montgomery
Qwest - eFlow Development Team
614-215-4937


-Original Message-
From:   William Kaufman [mailto:[EMAIL PROTECTED]]
Sent:   Tuesday, May 22, 2001 10:04 AM
To: '[EMAIL PROTECTED]'
Subject:    RE: servlet deployment

Try

http://myserver:8080/servlet/dummy.HelloWorld

1) 8080 is the default port for Tomcat: you can change it in
server.xml.
2) All servlets (by default--settable in web.xml) appear
under /servlet.
3) After that comes the full class name.


-- Bill K.


> -Original Message-
> From: Montgomery, Kendal L
[mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, May 22, 2001 6:43 AM
> To: Tomcat-User (E-mail)
> Cc: Sharma, Puneet
> Subject: servlet deployment
> 
> 
> Hello all,
> 
> I am just wandering how I deploy a servlet that is part of
a 
> package, and
> how to reference it.  For example.. say you take the
HelloWorldExample
> servlet that comes with and modify it.  Rename the source
to
> HelloWorld.java, and change the file appropriately,
including 
> adding a line
> at the top:
> 
> package dummy;
> 
> so, it is in the dummy class.
> 
> When I deploy this "new" HelloWorld servlet, I put it in
>
...webapps/examples/WEB-INF/classes/dummy/HelloWorld.class.  Now, to
> reference this, I expected to be able to go to my browser
and hit
> http://myserver/examples/servlet/dummy/HelloWorld
> <http://myserver/examples/servlet/dummy/HelloWorld> .
That 
> did not work.
> So, what do I have to do to make this work?
> 
> By the way, I am running Apache 1.3.19 and Tomcat
3.2.1.fasdf
> 
> Thanks..
> 
> Kendal L. Montgomery
> Qwest - eFlow Development Team
> 614-215-4937
> 



Re: servlet deployment

2001-05-22 Thread Manuel Melle Ocariz

You have to create a web.xml file in your Web-inf folder. This file should lokk like 
this:

http://java.sun.com/j2ee/dtds/web-app_2_2.dtd";>


HelloWorld
dummy.HelloWorld


HelloWorld
/HelloWorld/*



index.html




As you can see, this file specifies the servlet name and maps it to an url pattern. In 
your html you just have to write i.e:



This should work.

Manuel Melle Ocáriz
Software AG - E-Business Competence Center
[EMAIL PROTECTED]





RE: servlet deployment

2001-05-22 Thread William Kaufman

Try

http://myserver:8080/servlet/dummy.HelloWorld

1) 8080 is the default port for Tomcat: you can change it in server.xml.
2) All servlets (by default--settable in web.xml) appear under /servlet.
3) After that comes the full class name.

-- Bill K.


> -Original Message-
> From: Montgomery, Kendal L [mailto:[EMAIL PROTECTED]]
> Sent: Tuesday, May 22, 2001 6:43 AM
> To: Tomcat-User (E-mail)
> Cc: Sharma, Puneet
> Subject: servlet deployment
> 
> 
> Hello all,
> 
> I am just wandering how I deploy a servlet that is part of a 
> package, and
> how to reference it.  For example.. say you take the HelloWorldExample
> servlet that comes with and modify it.  Rename the source to
> HelloWorld.java, and change the file appropriately, including 
> adding a line
> at the top:
> 
> package dummy;
> 
> so, it is in the dummy class.
> 
> When I deploy this "new" HelloWorld servlet, I put it in
> ...webapps/examples/WEB-INF/classes/dummy/HelloWorld.class.  Now, to
> reference this, I expected to be able to go to my browser and hit
> http://myserver/examples/servlet/dummy/HelloWorld
>  .  That 
> did not work.
> So, what do I have to do to make this work?
> 
> By the way, I am running Apache 1.3.19 and Tomcat 3.2.1.fasdf
> 
> Thanks..
> 
> Kendal L. Montgomery
> Qwest - eFlow Development Team
> 614-215-4937
> 



RE: Servlet deployment

2001-04-11 Thread Chris Andreou

http://java.sun.com/docs/books/tutorial/servlets/servletrunner/tomcat-start.
html


-Original Message-
From: Harkishin Nachnani [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 11, 2001 1:15 PM
To: [EMAIL PROTECTED]
Subject: Servlet deployment


Hi all:
For a customer demo, I had written a small servlet and deployed it on Java
Web Server 2.0.
But we have an evaluation version of Java Web Server so we have to
re-install it every 30/45 days.
So I just thought of switching over to Tomcat.
Basically, I just have a couple of html and gif files, 1 webcallback.class
(servlet) and Libm2w32.dll (since servlet uses native methods)

I have successfully installed Tomcat 3.2.1 and the sample jsps work fine.
Can anyone tell me where I should place all the files (.html, .gif, .class,
.dll) of my application ??? Do I need to change the server.xml and add a new
context path ???
Can someone kindly tell me the easiest and fastest way to get the servlet
working since its just a demo machine ???

Thanks
Harry

-Original Message-
From: Tim O'Neil [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 11, 2001 2:04 PM
To: [EMAIL PROTECTED]
Subject: RE: /examples/servlet


At 11:33 PM 4/11/2001 -0400, you wrote:
> > I wouldn't know how to get mod_jk.so for linux. If you're using 
> modjserv then
> > you're in luck because the user guidelines are for mod_jserv only.

Actually, there are complete instructions for using
mod_jk on the sun site, and you can get the so right
'ere:
http://jakarta.apache.org/builds/jakarta-tomcat/release/v3.2.1/bin/linux/i38
6/