configuring ajp13 worker on tomcat 3.2.3

2001-09-17 Thread David Lee

hi,

i'm using nsapi to configure iPlanet with Tomcat 3.2.3.  they're 
communicating via the ajp13 worker.  the workers.properties file on the 
iPlanet box is configured to setup ajp13, and i know the server.xml file on 
the Tomcat box needs a tag for an ajp13 socket.  i have it setup as follows:









when i start the server up, i get an xml parser error:

At Line 269 /Server/ContextManager/Connector/ 
classname=org.apache.tomcat.service.PoolTcpConnector

FATAL: configuration error
java.lang.NullPointerException
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:120)
at org.apache.tomcat.util.xml.ObjectCreate.start(XmlMapper.java:580)
at 
org.apache.tomcat.util.xml.XmlMapper.matchStart(XmlMapper.java:384)
at 
org.apache.tomcat.util.xml.XmlMapper.startElement(XmlMapper.java:81)
at com.sun.xml.parser.Parser.maybeElement(Parser.java:1391)
at com.sun.xml.parser.Parser.content(Parser.java:1499)
at com.sun.xml.parser.Parser.maybeElement(Parser.java:1400)
at com.sun.xml.parser.Parser.content(Parser.java:1499)
at com.sun.xml.parser.Parser.maybeElement(Parser.java:1400)
at com.sun.xml.parser.Parser.parseInternal(Parser.java:492)
at com.sun.xml.parser.Parser.parse(Parser.java:284)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:155)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:126)
at org.apache.tomcat.util.xml.XmlMapper.readXml(XmlMapper.java:214)
at org.apache.tomcat.startup.Tomcat.execute(Tomcat.java:187)
at org.apache.tomcat.startup.Tomcat.main(Tomcat.java:235)

any help would be greatly appreciated.  i apologize in advance if this is a 
silly question.

thanks,
dave

_
Get your FREE download of MSN Explorer at http://explorer.msn.com/intl.asp




Why mail/session always being set to localhost even Context.xml says otherwise?

2004-10-25 Thread David Lee
Tomcat: 5.0.29
OS:  XP
JAVA: 1.5.0
 
Context.xml: jakarta-tomcat-5.0.29\conf\Catalina\localhost
 


  
mail.smtp.host
company email server
  

 
Java program:
 
Context initCtx = new InitialContext();
Context envCtx = (Context) initCtx.lookup("java:comp/env");
Session session = (Session) envCtx.lookup("mail/Session");
 
Message message = new MimeMessage(session);
message.setFrom(new InternetAddress("from email
 "));
InternetAddress to[] = new InternetAddress[1];
to[0] = new InternetAddress("to email
 ");
message.setRecipients(Message.RecipientType.TO, to);
message.setSubject("test mail session from tomcat");
message.setContent("test mail session from tomcat",
"text/plain");
Transport.send(message);
 
Catalina ERROR: 
 
javax.mail.SendFailedException: Sending failed;
  nested exception is:
javax.mail.MessagingException: Could not connect to SMTP host:
localhost
, port: 25;
  nested exception is:
java.net.ConnectException: Connection refused: connect
at javax.mail.Transport.send0(Transport.java:204)
at javax.mail.Transport.send(Transport.java:73)
at javaxml2.UpdateItemServlet.doPost(Unknown Source)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:237)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:157)


RE: Why mail/session always being set to localhost even Context.xml says otherwise?

2004-10-25 Thread David Lee
 My contents for mail/Session in web.xml:


  
Resource reference to a factory for javax.mail.Session
instances that may be used for sending electronic mail
messages, preconfigured to connect to the appropriate
SMTP server.
  
  
mail/Session
  
  
javax.mail.Session
  
  
Container
  


Thanks for the help!

David Lee

-Original Message-
From: Phillip Qin [mailto:[EMAIL PROTECTED] 
Sent: Monday, October 25, 2004 1:21 PM
To: 'Tomcat Users List'
Subject: RE: Why mail/session always being set to localhost even
Context.xml says otherwise?

What is in your web.xml?

-Original Message-----
From: David Lee [mailto:[EMAIL PROTECTED]
Sent: October 25, 2004 3:51 PM
To: [EMAIL PROTECTED]
Subject: Why mail/session always being set to localhost even Context.xml
says otherwise?


Tomcat: 5.0.29
OS:  XP
JAVA: 1.5.0
 
Context.xml: jakarta-tomcat-5.0.29\conf\Catalina\localhost
 


  
mail.smtp.host
company email server
  

 
Java program:
 
Context initCtx = new InitialContext();
Context envCtx = (Context) initCtx.lookup("java:comp/env");
Session session = (Session) envCtx.lookup("mail/Session");
 
Message message = new MimeMessage(session);
message.setFrom(new InternetAddress("from email
<mailto:[EMAIL PROTECTED]> "));
InternetAddress to[] = new InternetAddress[1];
to[0] = new InternetAddress("to email
<mailto:[EMAIL PROTECTED]> ");
message.setRecipients(Message.RecipientType.TO, to);
message.setSubject("test mail session from tomcat");
message.setContent("test mail session from tomcat",
"text/plain");
Transport.send(message);
 
Catalina ERROR: 
 
javax.mail.SendFailedException: Sending failed;
  nested exception is:
javax.mail.MessagingException: Could not connect to SMTP host:
localhost , port: 25;
  nested exception is:
java.net.ConnectException: Connection refused: connect
at javax.mail.Transport.send0(Transport.java:204)
at javax.mail.Transport.send(Transport.java:73)
at javaxml2.UpdateItemServlet.doPost(Unknown Source)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:237)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:157)


!DSPAM:417d591a211741752920360!

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



RE: Why mail/session always being set to localhost even Context.x ml says otherwise?

2004-10-25 Thread David Lee
 Hi! Phillip,

Thanks for the help.

My questions are:

1. in web.xml

My context definition is: 

UpdateItemServlet
/servlet/chapter6


It works fine

2. I have a context file called javaxml2.xml, in this file: I defined:


...


3. where should this context file reside?
My war file name is javaxml2.war.

4. My practice app probably didn't read this javaxml2 context file!!!
   Because I have a test env variable also didn't get read:


  

  mail.smtp.host
  ismtp.irf.com

  

 

5. error message from catalina:

INFO: Jk running ID=0 time=0/31
config=C:\jakarta-tomcat-5.0.29\conf\jk2.proper
ties
Oct 25, 2004 1:57:36 PM org.apache.catalina.startup.Catalina start
INFO: Server startup in 5467 ms
javax.naming.NameNotFoundException: Name david is not bound in this
Context
at
org.apache.naming.NamingContext.lookup(NamingContext.java:768)
at
org.apache.naming.NamingContext.lookup(NamingContext.java:151)
at javaxml2.UpdateItemServlet.doPost(Unknown Source)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:237)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:157)

Thanks a million

David

-Original Message-
From: Phillip Qin [mailto:[EMAIL PROTECTED] 
Sent: Monday, October 25, 2004 1:36 PM
To: 'Tomcat Users List'
Subject: RE: Why mail/session always being set to localhost even
Context.x ml says otherwise?

Add use plain email address, e.g. [EMAIL PROTECTED]



-Original Message-
From: Phillip Qin [mailto:[EMAIL PROTECTED]
Sent: October 25, 2004 4:34 PM
To: 'Tomcat Users List'
Subject: RE: Why mail/session always being set to localhost even
Context.x ml says otherwise?


Assume your Resource is closed by . Try addRecipient.

-----Original Message-
From: David Lee [mailto:[EMAIL PROTECTED] 
Sent: October 25, 2004 4:26 PM
To: [EMAIL PROTECTED]
Subject: RE: Why mail/session always being set to localhost even
Context.xml
says otherwise?


 My contents for mail/Session in web.xml:


  
Resource reference to a factory for javax.mail.Session
instances that may be used for sending electronic mail
messages, preconfigured to connect to the appropriate
SMTP server.
  
  
mail/Session
  
  
javax.mail.Session
  
  
Container
  
    

Thanks for the help!

David Lee

-Original Message-
From: Phillip Qin [mailto:[EMAIL PROTECTED] 
Sent: Monday, October 25, 2004 1:21 PM
To: 'Tomcat Users List'
Subject: RE: Why mail/session always being set to localhost even
Context.xml
says otherwise?

What is in your web.xml?

-----Original Message-
From: David Lee [mailto:[EMAIL PROTECTED]
Sent: October 25, 2004 3:51 PM
To: [EMAIL PROTECTED]
Subject: Why mail/session always being set to localhost even Context.xml
says otherwise?


Tomcat: 5.0.29
OS:  XP
JAVA: 1.5.0
 
Context.xml: jakarta-tomcat-5.0.29\conf\Catalina\localhost
 


  
mail.smtp.host
company email server
  

 
Java program:
 
Context initCtx = new InitialContext();
Context envCtx = (Context) initCtx.lookup("java:comp/env");
Session session = (Session) envCtx.lookup("mail/Session");
 
Message message = new MimeMessage(session);
message.setFrom(new InternetAddress("from email
<mailto:[EMAIL PROTECTED]> "));
InternetAddress to[] = new InternetAddress[1];
to[0] = new InternetAddress("to email
<mailto:[EMAIL PROTECTED]> ");
message.setRecipients(Message.RecipientType.TO, to);
message.setSubject("test mail session from tomcat");
message.setContent("test mail session from tomcat",
"text/plain");
Transport.send(message);
 
Catalina ERROR: 
 
javax.mail.SendFailedException: Sending failed;
  nested exception is:
javax.mail.MessagingException: Could not connect to SMTP host:
localhost , port: 25;
  nested exception is:
java.net.ConnectException: Connection refused: connect
at javax.mail.Transport.send0(Transport.java:204)
at javax.mail.Transport.send(Transport.java:73)
at javaxml2.UpdateItemServlet.doPost(Unknown Source)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Appl
icationFilterChain.java:237)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationF
ilterChain.java:157)





How to put context.xml into ant war target

2004-10-26 Thread David Lee
I used ant war task to create the deployable war file, I just want to
know how to put the context.xml into the meta-inf directory using war
target.
 
Thanks


Interesting discoveries about catalina GUI manager deploy (5.0.28 and 5.0.29)

2004-10-26 Thread David Lee
Phillip, thanks
the context.xml file works. I finally got the JNDI mail/Session to work.
 
But I found one thing interesting about the GUI manager deploy (upload
the ant generated war file)
 
After I uploaded the war file, I found that this action not only
uppacked war into the myapp directory with the
context.xml in mata-inf directory, ALSO, it generated myapp.xml in
C:\jakarta-tomcat-5.0.29\conf\Catalina\localhost
 
This discovery is inconsistent with the JNDI doc says: either myapp.xml
in C:\jakarta-tomcat-5.0.29\conf\Catalina\localhost 
or in meta-inf/context.xml.
 
Another question is: how do I get the JNDI enviroment variable value
from the java program? still using ctx.lookup or other way.
 
Any idea.
 
Again thanks for the help!!
 
david


RE: Interesting discoveries about catalina GUI manager deploy (5.0.28 and 5.0.29)

2004-10-26 Thread David Lee
The reason I asked that question is because I want to try that
enviroment value as said in JNDI how-to to see if it works. Could be the
global variable? 

David 

-Original Message-
From: Phillip Qin [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, October 26, 2004 1:13 PM
To: 'Tomcat Users List'
Subject: RE: Interesting discoveries about catalina GUI manager deploy
(5.0.28 and 5.0.29)

I personally have never tried environment variables. Do what Yoav
recommends. BTW, why do you need to use environemtn variables?



-Original Message-
From: Shapira, Yoav [mailto:[EMAIL PROTECTED]
Sent: October 26, 2004 3:56 PM
To: Tomcat Users List
Subject: RE: Interesting discoveries about catalina GUI manager deploy
(5.0.28 and 5.0.29)



Hi,

>After I uploaded the war file, I found that this action not only 
>uppacked war into the myapp directory with the context.xml in mata-inf 
>directory, ALSO, it generated myapp.xml in 
>C:\jakarta-tomcat-5.0.29\conf\Catalina\localhost

Funny, this is what I said would happen earlier today on this list on
another thread ;)

>This discovery is inconsistent with the JNDI doc says: either myapp.xml

>in C:\jakarta-tomcat-5.0.29\conf\Catalina\localhost
>or in meta-inf/context.xml.

It's not inconsistent at all.  Your can use either myapp.xml or
META-INF/context.xml to deploy your app.  If you use the latter Tomcat
will
create myapp.xml from context.xml.

>Another question is: how do I get the JNDI enviroment variable value 
>from the java program? still using ctx.lookup or other way.

All JNDI references should be lookup using the naming context.  If
you're
using simple Environment variables, you don't need to use JNDI, you
retrieve
them like normal environment entries in any Java program.

Yoav



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]


!DSPAM:417eabe641391746942718!

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



RE: Interesting discoveries about catalina GUI manager deploy (5.0.28 and 5.0.29)

2004-10-27 Thread David Lee
How do I get this value from within context in java program, thanks
 




From: Igor [mailto:[EMAIL PROTECTED]
Sent: Tue 10/26/2004 9:52 PM
To: [EMAIL PROTECTED]
Subject: Re: Interesting discoveries about catalina GUI manager deploy (5.0.28 and 
5.0.29)



Hello!

>>Another question is: how do I get the JNDI enviroment variable value
>>from the java program? still using ctx.lookup or other way.

>All JNDI references should be lookup using the naming context.  If
>you're using simple Environment variables, you don't need to use JNDI,
>you retrieve them like normal environment entries in any Java program.

Could you please tell me how environment variables can be accessed without
JNDI?
Is there corresponding section in documentation?

Thank you,
Igor


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

How to specify catalina jdbcstore username/password?

2004-10-27 Thread David Lee
I'm trying to use the jdbcstore to save the session data, the only thing I don't know 
is how to specify database
username/password. where should I put it?
 

   
  


Tomcat5.5.3 serious problems!

2004-10-28 Thread David Lee
HI!
 
I tried to use GUI manager to upload war file (war file to deploy, the
message says OK, but nothing happened. no context files deployed.
nothing.
 
then I tried to upload the same war file using "deploy directory or war
file located on server", the upload problem entered into an infinitive
loop, just kept runnin...runing.
 
What happened!
 
The war file I tried to upload works perfect on Tomcat5.0.29.
 
Thanks
 
David Lee


RE: Tomcat5.5.3 serious problems!

2004-10-29 Thread David Lee
I will take a look at this one, BTW, I just uploaded my test war file in
response to Remy's comments.

Thanks

David 

-Original Message-
From: Ben Souther [mailto:[EMAIL PROTECTED] 
Sent: Thursday, October 28, 2004 5:06 PM
To: Tomcat Users List
Subject: Re: Tomcat5.5.3 serious problems!

Check out the directions for the manager app.
There is a specific syntax for war files.

The syntax is explained in detail here:
http://java.sun.com/j2se/1.4.2/docs/api/java/net/JarURLConnection.html

Here's a simple example for a war files named myapp.war on a local unix
box (Note the exclamation point and ending slash):

jar:file:/path/to/myapp.war!/





On Thu, 2004-10-28 at 19:39, David Lee wrote:
> HI!
>  
> I tried to use GUI manager to upload war file (war file to deploy, the

> message says OK, but nothing happened. no context files deployed.
> nothing.
>  
> then I tried to upload the same war file using "deploy directory or 
> war file located on server", the upload problem entered into an 
> infinitive loop, just kept runnin...runing.
>  
> What happened!
>  
> The war file I tried to upload works perfect on Tomcat5.0.29.
>  
> Thanks
>  
> David Lee


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



How to fix the security error like this for tomcat5.5.4 -security

2004-11-08 Thread David Lee
when tc security turned on then errors, if no security, it works fine, tried 
everything, still has errors
 
Thanks for anyone who can help!!! greatly appreciated
 
David Lee
 
1. Errors:
 
access: access allowed (java.util.PropertyPermission line.separator read)
Nov 8, 2004 9:55:25 PM org.apache.naming.NamingContext lookup
WARNING: Unexpected exception resolving reference
java.security.AccessControlException: access denied 
(java.util.PropertyPermission javax.mail.Session.Factory read)
 at 
java.security.AccessControlContext.checkPermission(AccessControlContext.java:264)
 at java.security.AccessController.checkPermission(AccessController.java:427)
 at java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
 at java.lang.SecurityManager.checkPropertyAccess(SecurityManager.java:1285)
 at java.lang.System.getProperty(System.java:661)
 at 
org.apache.naming.factory.ResourceFactory.getObjectInstance(ResourceFactory.java:117)
 at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:304)
 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:152)
 at javaxml2.UpdateItemServlet.doPost(Unknown Source)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
 at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
 at 
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

2. catalina.policy:
 
grant codeBase 
"file:${catalina.home}/webapps/javaxml2/WEB-INF/classes/UpdateItemServlet.class"
 {
permission java.net.SocketPermission "localhost:1521","connect,resolve";
   permission java.util.PropertyPermission "javax.mail.Session.Factory","read";
   permission java.net.SocketPermission "localhost:25","connect,resolve";
};
 
3. context.xml
 

  



 
4. web.xml
 

  Resource reference to a factory for javax.mail.Session 
instances that may be used for sending electronic mail messages, preconfigured 
to connect to the appropriate SMTP server.
  
  
mail/Session
  
  
javax.mail.Session
  
  
Container
  


  
Resource reference to a factory for java.sql.Connection
instances that may be used for talking to a particular
database that is configured in the server.xml file.
  
  
jdbc/EmployeeDB
  
  
javax.sql.DataSource
  
  
Container
  

 


Anyone knows how to deal with mail session -security error for TC5.5.4

2004-11-09 Thread David Lee
if running tomcat5.5.4 without turning on -security, everything works
fine for jndi context mail session and DBCP.
But if -security turned on, I got the following errors.
 
If anyone can point to me what I missed or did wrong, greatly
appreciated.
 
Thanks
 
David
 
1. TC errors
 
access: access allowed (java.util.PropertyPermission line.separator
read) Nov 8, 2004 9:55:25 PM org.apache.naming.NamingContext lookup
WARNING: Unexpected exception resolving reference
java.security.AccessControlException: access denied
(java.util.PropertyPermission javax.mail.Session.Factory read)  at
java.security.AccessControlContext.checkPermission(AccessControlContext.
java:264)
 at
java.security.AccessController.checkPermission(AccessController.java:427
)
 at java.lang.SecurityManager.checkPermission(SecurityManager.java:532)
 

2. catalina.policy:
 
grant codeBase
"file:${catalina.home}/webapps/javaxml2/WEB-INF/classes/UpdateItemServle
t.class" {
permission java.net.SocketPermission
"localhost:1521","connect,resolve";
   permission java.util.PropertyPermission
"javax.mail.Session.Factory","read";
   permission java.net.SocketPermission
"localhost:25","connect,resolve"; };



has anyone tried or run the TC -security with mail session or database connection successfully?

2004-11-12 Thread David Lee
Thanks lot if anyone can point me in the right direction.
 
TC5.5.4 ( it happens to other versions)
Window XP
JAVA 1.5.0
 
My program runs successfully without turning on the -security, but has
the errors when it is turned on.
The errors generated look like not related to access violation because
of active security? Otherwise, I will see 
the access violation security errors.
 
I searched all the internet sources but found no answers.
 
I setup the security as follows:
 
1. catalina.policy
 
grant codeBase
"file:${catalina.home}/webapps/javaxml2/WEB-INF/classes/-" {
   permission java.util.PropertyPermission
"javax.mail.Session.Factory","read";
   permission java.net.SocketPermission "localhost:25",
"connect,resolve";
   permission java.net.SocketPermission
"localhost:1521","connect,resolve";   
};
 
2. mail session errors:
 
INFO: HTMLManager: list: Listing contexts for virtual host 'localhost'
javax.mail.MessagingException: IOException while sending message;
  nested exception is:
 javax.activation.UnsupportedDataTypeException: no object DCH for MIME
type text/plain
 at com.sun.mail.smtp.SMTPTransport.sendMessage(SMTPTransport.java:566)
 at javax.mail.Transport.send0(Transport.java:151)
 at javax.mail.Transport.send(Transport.java:80)
 at javaxml2.UpdateItemServlet.doPost(Unknown Source)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
 
3. DB connection errors:
 
INFO: HTMLManager: list: Listing contexts for virtual host 'localhost'
javax.naming.NamingException: Cannot create resource instance
 at
org.apache.naming.factory.ResourceFactory.getObjectInstance(ResourceFact
ory.java:132)
 at
javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:304)
 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:152)
 at javaxml2.UpdateItemServlet.doPost(Unknown Source)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
 at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
 
4. context.xml
 




 
 


Installing a webmail client such as squirrelmail (PHP) on tomcat?

2004-11-18 Thread David Lee
Hi! Folks,
 
Has anyone run the php application on Tomcat?. I'm trying to install the
squirrelmail on tomcat so I can web access my james email server.
 
What is the best way to integrate the php with tomcat or any
suggesstions or pitfalls to avoid?
 
Any comments welcome.
 
Thanks
 
David Lee


RE: Installing a webmail client such as squirrelmail (PHP) ontomcat?

2004-11-18 Thread David Lee
Thanks, I'll look into it. 

-Original Message-
From: David Boyer [mailto:[EMAIL PROTECTED] 
Sent: Thursday, November 18, 2004 2:47 PM
To: [EMAIL PROTECTED]
Subject: Re: Installing a webmail client such as squirrelmail (PHP)
ontomcat?

I think you'd be better off fronting Tomcat with Apache or IIS
(depending on your platform). mod_php for Apache seems to have a pretty
good track record. For IIS, I'd suggest using php.exe for process
isolation rather than the PHP ISAPI application extension due to known
threading issues.
 
You might also be able to use Tomcat's CGI servlet to execute PHP
scripts with the appropriate binary for your platform, but I can't speak
to that from specific experience.

>>> [EMAIL PROTECTED] 11/18/2004 4:11:37 PM >>>

Hi! Folks,

Has anyone run the php application on Tomcat?. I'm trying to install the
squirrelmail on tomcat so I can web access my james email server.

What is the best way to integrate the php with tomcat or any
suggesstions or pitfalls to avoid?

Any comments welcome.

Thanks

David Lee


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



RE: Installing a webmail client such as squirrelmail (PHP) on tomcat?

2004-11-18 Thread David Lee
Hi! Hassan,

You mean phpservlet to read the php app config file or php files and
then phpservlet to serve the php page?
Your calendar app were written using PHP?

Thanks 

David Lee 

-Original Message-
From: Hassan Schroeder [mailto:[EMAIL PROTECTED] 
Sent: Thursday, November 18, 2004 3:06 PM
To: Tomcat Users List
Subject: Re: Installing a webmail client such as squirrelmail (PHP) on
tomcat?

David Lee wrote:

> Has anyone run the php application on Tomcat?. 

I've tinkered with it -- using the phpservlet to run a calendar app.
Works surprisingly well, but since you're hooking into native code,
beware -- if (when!) it crashes, it takes the whole JVM with it :-)

YMMV!
--
Hassan Schroeder - [EMAIL PROTECTED]
Webtuitive Design ===  (+1) 408-938-0567   === http://webtuitive.com

   dream.  code.



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



RE: Installing a webmail client such as squirrelmail (PHP) on tomcat?

2004-11-18 Thread David Lee
Thanks lot, I will study it.

David Lee 

-Original Message-
From: Hassan Schroeder [mailto:[EMAIL PROTECTED] 
Sent: Thursday, November 18, 2004 3:51 PM
To: Tomcat Users List
Subject: Re: Installing a webmail client such as squirrelmail (PHP) on
tomcat?

David Lee wrote:

> You mean phpservlet to read the php app config file or php files and 
> then phpservlet to serve the php page?

When you build (configure) php with --with-java=$JAVA_HOME (I think, it
was a while ago I built this), you get a 'phpservlet.jar' created.
Put that in $CATALINA_HOME/common/lib, add something like this to your
catalina.sh startup script:

   LD_LIBRARY_PATH="/usr/local/php/lib/php/libphp4.so"

:: and you're set. Oh, yeah, need to add mappings to your web.xml.

> Your calendar app were written using PHP?

It's "phpicalendar" (I'm not the author). As I said, php does seem to
work fine, but I have had it crash. The machine I was using to test with
was woefully underpowered and under-memoried, though. I'll have to try
it on something more robust and see what happens.

HTH!
--
Hassan Schroeder - [EMAIL PROTECTED]
Webtuitive Design ===  (+1) 408-938-0567   === http://webtuitive.com

   dream.  code.



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



RE: Installing a webmail client such as squirrelmail (PHP) on tomcat?

2004-11-19 Thread David Lee
Hi! Yoav,
That's right, because I saw so many mails related to apache connector,
jk2 or mod_jk. Also I got problem with apache 2.0.*
My OS is winXP professional. Somehow, the apache server service looks
like it's running using Window services menu, but 
After I refresh it, the apache service is not running. It was running
like that for more than 3 monthes and 
Finally I gave up, because my focus is Tomcat, I just want to make
everything works first on tomcat and then 
Think other options. It will simplify the application development and
deployment.

David Lee 

-Original Message-
From: Shapira, Yoav [mailto:[EMAIL PROTECTED] 
Sent: Friday, November 19, 2004 5:40 AM
To: Tomcat Users List
Subject: RE: Installing a webmail client such as squirrelmail (PHP) on
tomcat?


Hi,
"easiest" is subjective: some (many IMHO) people find the connector
configuration difficult enough so that anything they can run on Tomcat
standalone is good.

Yoav Shapira http://www.yoavshapira.com
 

>-Original Message-
>From: Andy Savage [mailto:[EMAIL PROTECTED]
>Sent: Friday, November 19, 2004 6:36 AM
>To: Tomcat Users List
>Subject: Re: Installing a webmail client such as squirrelmail (PHP) on 
>tomcat?
>
>Wouldn't the easiest way be to run apache as a front end with mod_jk2?
>It's pretty simple and it saves the hassle of possibly taking down the 
>whole server with a crash, or any security hassles.
>
>Serve php with apache, serve everything else to tomcat.
>
>Kind Regards,
>Andy Savage
>
>--
>Bluewire Solutions
>Position: Partner
>Contact: +64 27 4678 262
>Website: www.bluewire.net.nz
>Email: [EMAIL PROTECTED]
>
>
>David Lee wrote:
>> Hi! Folks,
>>
>> Has anyone run the php application on Tomcat?. I'm trying to install
the
>> squirrelmail on tomcat so I can web access my james email server.
>>
>> What is the best way to integrate the php with tomcat or any 
>> suggesstions or pitfalls to avoid?
>>
>> Any comments welcome.
>>
>> Thanks
>>
>> David Lee
>>
>
>-
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




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]


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



RE: Installing a webmail client such as squirrelmail (PHP) on tomcat?

2004-11-19 Thread David Lee
Thanks for the suggestion.  BTW, what is the OS you are using, mine is
winXP professional, I heard apache is
Not suitable or not tuned for win but UNIX/LINUX, that's why it's not
stable on winXP platform, just an 
Afterthrought.

David 

-Original Message-
From: Andoni [mailto:[EMAIL PROTECTED] 
Sent: Friday, November 19, 2004 9:40 AM
To: Tomcat Users List
Subject: Re: Installing a webmail client such as squirrelmail (PHP) on
tomcat?

Tomcat is fine and all but in this case it is definitely not the right
tool for the job.  I know you've had problems with Apache but I'd go
look at it again. I am running apache 1.3 and I have a 5 line
workers.properties, and one line in server.xml, my connector has never
been a problem. Installing PHP took less time to do than it did to
download the module over DSL!

Just my 2 cents: Go to old Apache, Old JK, and set up simply.

Andoni.

- Original Message -----
From: "David Lee" <[EMAIL PROTECTED]>
Newsgroups: gmane.comp.jakarta.tomcat.user
Sent: Friday, November 19, 2004 4:48 PM
Subject: RE: Installing a webmail client such as squirrelmail (PHP) on
tomcat?


Hi! Yoav,
That's right, because I saw so many mails related to apache connector,
jk2 or mod_jk. Also I got problem with apache 2.0.*
My OS is winXP professional. Somehow, the apache server service looks
like it's running using Window services menu, but
After I refresh it, the apache service is not running. It was running
like that for more than 3 monthes and
Finally I gave up, because my focus is Tomcat, I just want to make
everything works first on tomcat and then
Think other options. It will simplify the application development and
deployment.

David Lee

-Original Message-
From: Shapira, Yoav [mailto:[EMAIL PROTECTED]
Sent: Friday, November 19, 2004 5:40 AM
To: Tomcat Users List
Subject: RE: Installing a webmail client such as squirrelmail (PHP) on
tomcat?


Hi,
"easiest" is subjective: some (many IMHO) people find the connector
configuration difficult enough so that anything they can run on Tomcat
standalone is good.

Yoav Shapira http://www.yoavshapira.com


>-Original Message-
>From: Andy Savage [mailto:[EMAIL PROTECTED]
>Sent: Friday, November 19, 2004 6:36 AM
>To: Tomcat Users List
>Subject: Re: Installing a webmail client such as squirrelmail (PHP) on
>tomcat?
>
>Wouldn't the easiest way be to run apache as a front end with mod_jk2?
>It's pretty simple and it saves the hassle of possibly taking down the
>whole server with a crash, or any security hassles.
>
>Serve php with apache, serve everything else to tomcat.
>
>Kind Regards,
>Andy Savage
>
>--
>Bluewire Solutions
>Position: Partner
>Contact: +64 27 4678 262
>Website: www.bluewire.net.nz
>Email: [EMAIL PROTECTED]
>
>
>David Lee wrote:
>> Hi! Folks,
>>
>> Has anyone run the php application on Tomcat?. I'm trying to install
the
>> squirrelmail on tomcat so I can web access my james email server.
>>
>> What is the best way to integrate the php with tomcat or any
>> suggesstions or pitfalls to avoid?
>>
>> Any comments welcome.
>>
>> Thanks
>>
>> David Lee
>>
>
>-
>To unsubscribe, e-mail: [EMAIL PROTECTED]
>For additional commands, e-mail: [EMAIL PROTECTED]




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]


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



How to add a request filter for TC5.5.3? It was working for TC5.0.29!

2004-11-26 Thread David Lee
Dear Folks,
 
I have a test request filter on TC5.0.29. It is defined in server.xml as
follows and it works:
 
conf\server.xml:
 
 
 
 
 
How do I move this context into TC5.5.3, I tried to put it into
conf\context.xml file and I saw
the errors when I started TC5.5.3. I struggle for a while and still
don't know how to do it?
 
Thanks in advance for any help
 
David Lee


RE: How to add a request filter for TC5.5.3? It was working for TC5.0.29!

2004-11-26 Thread David Lee
Yes, It has been rewritten and recompiled, the last thing is How do I
specify the context, 
I mean move the context to TC5.5.3.

Thanks

David 

-Original Message-
From: news [mailto:[EMAIL PROTECTED] On Behalf Of Bill Barker
Sent: Friday, November 26, 2004 3:25 PM
To: [EMAIL PROTECTED]
Subject: Re: How to add a request filter for TC5.5.3? It was working for
TC5.0.29!

Valves (and other custom components, like Realms) written for TC 5.0.x
will at the very least have to be re-compiled to work for TC 5.5.x.
More likely, there will have to be code changes to make them work.
That's just the price you pay for relying on TC internals ;-).

"David Lee" <[EMAIL PROTECTED]> wrote in message
news:[EMAIL PROTECTED]
m...
Dear Folks,

I have a test request filter on TC5.0.29. It is defined in server.xml as
follows and it works:

conf\server.xml:

   
 

How do I move this context into TC5.5.3, I tried to put it into
conf\context.xml file and I saw the errors when I started TC5.5.3. I
struggle for a while and still don't know how to do it?

Thanks in advance for any help

David Lee




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



RE: How to add a request filter for TC5.5.3? It was working for TC5.0.29!

2004-11-26 Thread David Lee
Hi! Remy,

For TC5.5.3
I put the context in conf\context.xml as follows





WEB-INF/web.xml
META-INF/context.xml









TC5.5.3 starts no errors, but when I accessed it http://localhost:8080, a blank 
page 
Appears. If I take out the above context, I can the page, something wrong with 
how do
I move the conf\server.xml context into the TC5.5.3 file?

David 

-Original Message-
From: Remy Maucherat [mailto:[EMAIL PROTECTED] 
Sent: Friday, November 26, 2004 3:31 PM
To: Tomcat Users List
Subject: Re: How to add a request filter for TC5.5.3? It was working for 
TC5.0.29!

On Fri, 26 Nov 2004 15:14:27 -0800, David Lee <[EMAIL PROTECTED]> wrote:
> Dear Folks,
> 
> I have a test request filter on TC5.0.29. It is defined in server.xml 
> as follows and it works:
> 
> conf\server.xml:
> 
> className="com.oreilly.tomcat.valves.BadInputFilterValve"
>  deny="\x00,\x04,\x08,\x0a,\x0d"/>
>  
> 
> How do I move this context into TC5.5.3, I tried to put it into 
> conf\context.xml file and I saw the errors when I started TC5.5.3. I 
> struggle for a while and still don't know how to do it?

The Valve API was slightly changed in 5.5. This is likely what causes the 
errors you see.

--
x
Rémy Maucherat
Developer & Consultant
JBoss Group (Europe) SàRL
x

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