JNDI Bean problem - Tomcat 5.0.28

2005-06-21 Thread Jimmy Ray
Trying to get a bean through a JNDI context:  My
context.xml in the META-INF directory entry is:

Context path=/apppath
Resource name=bean/properties
type=com.ifx.ric.dwh.bean.PropertiesBean
auth=Container/
ResourceParams name=bean/properties
parameter
namefactory/name

valueorg.apache.naming.factory.BeanFactory/value
/parameter
/ResourceParams
  /Context

My web.xml in META-INF:
resource-env-ref
description
JNDI bean for application properties
/description
resource-env-ref-name
bean/properties
/resource-env-ref-name
resource-env-ref-type
com.ifx.ric.dwh.bean.PropertiesBean
/resource-env-ref-type
/resource-env-ref

My servlet JNDI lookup:
Context initCtx = new InitialContext();
Context envCtx = (Context)
initCtx.lookup(java:comp/env);
PropertiesBean bean = (PropertiesBean)
envCtx.lookup(bean/properties);

But the Exception is:

Cannot create resource instance




__ 
Yahoo! Mail 
Stay connected, organized, and protected. Take the tour: 
http://tour.mail.yahoo.com/mailtour.html 


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



Re: JMX implementation - Tomcat 5.0.28

2005-06-07 Thread Jimmy Ray
I fixed this by adding the jmxri.jar to the
C:\Sun\AppServer\jdk\jre\lib\ext path on my test
box.

Regards,

Jimmy Ray

--- Jon Wingfield [EMAIL PROTECTED] wrote:

 That's because it's hardcoded to look for jmx.jar.
 One jar, singular.
 Sitting on my local dev machine I've got a jmx.jar
 which is a 
 concatenation of mx4j.jar and mx4j-tools.jar. It's a
 bit horrible but it 
 works.
 
 There are other ways to do it:
 
 1)
 Add your jars to the bootstrap classpath by
 modifying setclasspath.bat 
 (assuming you're using the scripts not the service
 to start and stop tc).
 
 2)
 According to the release notes you can also change
 the manifest file in 
 the bootstrap.jar to point to your own jmx
 implementations.
 

http://jakarta.apache.org/tomcat/tomcat-5.0-doc/RELEASE-NOTES.txt
 (just above the Tomcat 5.0 and XML Parsers
 section)
 
 HTH,
 
 Jon
 
 Jimmy Ray wrote:
  I was ruinning 5.0.28 on Windows, but now it wont
  start.  I get this message:
  
  Due to new licensing guidelines mandated by the
 Apache
  Software
  Foundation Board of Directors, a JMX
 implementation
  can no longer
  be distributed with the Apache Tomcat binaries. As
 a
  result, you
  must download a JMX 1.2 implementation (such as
 the
  Sun Reference
  Implementation) and copy the JAR containing the
 API
  and
  implementation of the JMX specification to:
  ${catalina.home}/bin/jmx.jar
  
  I have downlaoded the implementation and placed th
  files in the correct bin directory, but I still
 get
  this error.
  
  Any one else tackled this issue.
  
  Regards,
  
  Jimmy Ray
  
  
  
  __ 
  Discover Yahoo! 
  Stay in touch with email, IM, photo sharing and
 more. Check it out! 
  http://discover.yahoo.com/stayintouch.html
  
 

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


__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

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



OpenEJB JNDI issue -

2005-06-07 Thread Jimmy Ray
I am trying to use openEJB 0.9.2 with Tomcat 5.0.28 on
W2K with the Sun 1.4.2 JDK.

I can
test everything OK with the call to
http://localhost:8080/openejb_loader-0.9.2/;.  I can
even lookup my bean.  Now when I try the JSP or
servlet I seem to be getting a JNDI NamingException,
Naming Exception - Name ejb/hello not found. 

In the past, to get JNDI working for DBCP, I have had
to have a servlet.xml, web.xml and app_nam.xml file
entry for this JNDI resource.  Below is the code I am
trying.

Regards,

Jimmy Ray

THE JSP:
%@ page import=org.acme.HelloObject,
 org.acme.HelloHome,
 javax.naming.InitialContext,
 javax.naming.Context%

html
head
titleOpenEJB -- EJB for Tomcat/title
/head

body
%
Context initCtx = new InitialContext();

Object object =
initCtx.lookup(java:comp/env/ejb/hello);

if (object != null) {
HelloHome helloHome = (HelloHome)
javax.rmi.PortableRemoteObject.narrow(object,
HelloHome.class);
HelloObject bean = helloHome.create();
out.println(bean.sayHello());
}

%
/body
/html

THE SERVER.XML ENTRY:
Context docBase=${catalina.home}/webapps/EJB
path=/EJB

Ejb name=ejb/hello
 type=Session
 home=org.acme.HelloHome
 remote=org.acme.Hello/
ResourceParams name=ejb/hello
parameter
namefactory/name
   
valueorg.openejb.client.TomcatEjbFactory/value
/parameter
parameter
   
nameopenejb.naming.factory.initial/name
   
valueorg.openejb.client.LocalInitialContextFactory/value
/parameter
parameter
   
nameopenejb.naming.security.principal/name
valueAdmin/value
/parameter
parameter
   
nameopenejb.naming.security.credentials/name
valuepass/value
/parameter
parameter
   
nameopenejb.naming.provider.url/name
valuelocalhost:4201/value
/parameter
parameter
nameopenejb.ejb-link/name
valueHello/value
/parameter
/ResourceParams
  
  /Context

The web.xml entry for the EJB webapp:
ejb-ref
  description
  EJB Reference to the bean deployed to
OpenEJB
  /description
  ejb-ref-nameejb/hello/ejb-ref-name
  ejb-ref-typeSession/ejb-ref-type
  homeorg.acme.HelloHome/home
  remoteorg.acme.Hello/remote
  /ejb-ref

The application xml entry in the EJB.xml in
$CATALINA_HOME/conf/catalina/localhost:

?xml version='1.0' encoding='utf-8'?
Context crossContext=true debug=9
displayName=EJB docBase=EJB path=/EJB
workDir=c:/tomcat-5.0.28/work/Catalina/localhost/EJB
  Logger
className=org.apache.catalina.logger.FileLogger
directory=c:/tomcat-5.0.28/webapps/EJB/logs
prefix=EJB_log. suffix=.txt timestamp=true
verbosity=4/
  ResourceLink global=ejb/hello name=ejb/hello
type=org.acme.Hello/
/Context

THE SERVLET:
import java.io.IOException;
import java.io.PrintWriter;
import java.util.Properties;

import javax.naming.InitialContext;
import javax.naming.NamingException;
import javax.rmi.PortableRemoteObject;
import javax.servlet.ServletConfig;
import javax.servlet.ServletException;
import javax.servlet.http.HttpServlet;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import org.acme.HelloHome;
import org.acme.HelloObject;

/*
 * Created on Jun 7, 2005
 */

/**
 * @author rayj
 * @version 1.0
 */
public class TestHelloEJBServlet extends HttpServlet {



/** Processes requests for both HTTP
codeGET/code and codePOST/code methods.
 * All the real work happens here.
 * @param request servlet request
 * @param response servlet response
 * @throws ServletException if an error occurred
 * @throws IOException if an error occurred
 */
protected void processRequest(HttpServletRequest
req,
HttpServletResponse res) throws
ServletException, IOException {

res.setContentType(text/html);
PrintWriter out = res.getWriter();
out.println(html);
out.println(head);
out.println(titleServlet/title);
out.println(/head); 
out.println(body);
   
Properties p = new Properties();

//The JNDI properties you set depend
//on which server you are using.
//These properties are for the Remote Server.
/*p.put(java.naming.factory.initial,
   
org.openejb.client.RemoteInitialContextFactory);
p.put(java.naming.provider.url,
127.0.0.1:4201);
p.put(java.naming.security.principal,
Admin);
p.put(java.naming.security.credentials,
pass);*/

p.put(java.naming.factory.initial,
org.openejb.client.LocalInitialContextFactory);
p.put(openejb.home,
C:\\Programs\\openejb-0.9.2);

try

JMX implementation - Tomcat 5.0.28

2005-06-02 Thread Jimmy Ray
I was ruinning 5.0.28 on Windows, but now it wont
start.  I get this message:

Due to new licensing guidelines mandated by the Apache
Software
Foundation Board of Directors, a JMX implementation
can no longer
be distributed with the Apache Tomcat binaries. As a
result, you
must download a JMX 1.2 implementation (such as the
Sun Reference
Implementation) and copy the JAR containing the API
and
implementation of the JMX specification to:
${catalina.home}/bin/jmx.jar

I have downlaoded the implementation and placed th
files in the correct bin directory, but I still get
this error.

Any one else tackled this issue.

Regards,

Jimmy Ray



__ 
Discover Yahoo! 
Stay in touch with email, IM, photo sharing and more. Check it out! 
http://discover.yahoo.com/stayintouch.html

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



Re: UTF-8 Problem with Tomcat 5.0.27 and POST

2005-05-10 Thread Jimmy Ray
You dont really give enough details for your problem
but...

Maybe you have to decode the UTF-8 data. 
URLDecoder.decode(YOUR_STRING_HERE,UTF-8) should
do the trick.  Most GET requests are decoded before
the request parameters reach the servlet.  POST
requests require the decode process.

Regards,

Jimmy Ray
--- Bernhard v. Fromberg
[EMAIL PROTECTED] wrote:
 Hi all,
 
 I desperatly try to POST UTF-8 data to an
 application using struts.
 GET method works perfectly fine, but post does not.
 I am using CharacterEncodingFilter
 All pages have Content-Type header
 
 java1.5.0 update 2
 Tomcat 5.0.27
 various Un*x systems.
 
 Tia
 Bernhard
 

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



Discover Yahoo! 
Have fun online with music videos, cool games, IM and more. Check it out! 
http://discover.yahoo.com/online.html

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



Re: DBCP monitoring tool

2005-05-09 Thread Jimmy Ray
I usually do this at the database level.  I can give
you an example of the SQL that we run to see how many
connections as well as cursors are being used by our
Thin JDBC clients to Oracle:

To get sessions/connections to oracle:
select sid,username,program from v$session
where program = 'JDBC Thin Client';

To get cursors information:
select b.name,a.* 
from v$sesstat a,v$statname b
where a.statistic# = b.statistic#
and b.name in ('opened cursors current','opened
cursors cumulative',
'session uga memory','session pga memory')
and a.sid in (select sid from v$session
where program = 'JDBC Thin Client')
order by b.name;

To get open cursors:
select * from v$open_cursor
where sid in (select sid from v$session
where program = 'JDBC Thin Client');

Regards,

Jimmy Ray

--- Gabriel Belingueres [EMAIL PROTECTED] wrote:
 Hi,
  Are there any DBCP monitoring tool that allow me to
 monitor how many open 
 connections (and other stats) does DBCP holding?
  TIA,
 Gabriel
 



Yahoo! Mail
Stay connected, organized, and protected. Take the tour:
http://tour.mail.yahoo.com/mailtour.html


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



RE: POST not working

2005-05-05 Thread Jimmy Ray
We had the same issue when we tried to change JCIFS or
disable it.  It went away when the session timed out
or was invalidated.

Regards,

Jimmy Ray

--- Allistair Crossley [EMAIL PROTECTED]
wrote:

 well, i'm not entirely sure, but i remember having
 this problem last year when using jCIFs for
 authentication and IE6. 
 
 we solved it by ensuring we instructed tomcat not to
 attempt authentication, and allowing therefore IIS
 to pass thru the remote user login
 
 this is done on the AJP Connector element with
 tomcatAuthentication=false. however, i think the
 admin tool uses basic authentication. It could be
 this mixed mode that you have causing issues. I am
 not totally sure, but see this ...
 
 http://www.websina.com/bugzero/kb/browser-ie.html
 
  -Original Message-
  From: Christian Dechery
 [mailto:[EMAIL PROTECTED]
  Sent: 05 May 2005 13:25
  To: Tomcat Users List
  Subject: Re: POST not working
  
  
  As a matter of fact I am. Is that the cause?
  
  Ah, I forgot to mention, we have the exact same
 setup (a 
  mirror-development server) here, but running on
 Tomcat 5 and it works 
  fine. Should we upgrade?
  
  Allistair Crossley wrote:
  
  are you running IE6 and NTLM-authenticated
 applications?
  

  
  -Original Message-
  From: Christian Dechery
 [mailto:[EMAIL PROTECTED]
  Sent: 05 May 2005 13:16
  To: Tomcat Users List
  Subject: Re: POST not working
  
  
  It's a regular JSP page with nothing to it. This
 application 
  (SCA) works 
  perfectly, I've been using it for two years on
 several projects.. 
  Suddenly all the POSTs on the server stopped
 working BUT the main 
  application (the huge intranet thing).
  
  It's not any error in MY application (or any
 application, for that 
  matter), proof of that, is that even the /admin
 application 
  that comes 
  with tomcat is not working. I can't login cuz it
 uses POST 
  to process 
  login and password, and I'm 110% sure using the
 correct 
  user/password 
  but it always gives me Invalid login/password,
 for the 
  obvious reason 
  it isn't getting ANY user/password from the
 POSTed form.
  
  It's something with the server, but I don't have
 a clue. :(
  
  Allistair Crossley wrote:
  
  
  
  what are you posting to? what does your html
 form tag look 

  
  like, have you specified multipart?
  
  
   
  

  
  -Original Message-
  From: Christian Dechery
 [mailto:[EMAIL PROTECTED]
  Sent: 05 May 2005 13:02
  To: Tomcat Users List
  Subject: Re: POST not working
  
  
  I don't get any response, no errors presented,
 I just 
  realised that 
  nothing is being POSTed.
  Only GET works.
  
  Mark Thomas wrote:
  
 
  
  
  
  What response do you get when you try to
 POST?
  
  Mark
  
  Christian Dechery wrote:
  
   
  

  
  Hi everyone, hope u can help me solve this
 one. It's at 
 
  
  
  
  least weird.
 
  
  
  
  I have a 4.1.3 installed on a FreeBSD
 machine running a 
 
  
  
  
  huge intranet 
 
  
  
  
  corporate system. It runs smoothly and very
 fast, but for 
 
  
  
  
  some very 
 
  
  
  
  weird reason, that webapp is the only one on
 the server 
 
  
  
  
  wich allows 
 
  
  
  
  POST.
  
  Even the /admin tool won't allow posts,
 therefore I can't 
 
  
  
  
  login to it.
 
  
  
  
  I have another webapp (a little one, for
 access control), 
 
  
  
  
  installed. 
 
  
  
  
  It is the simplest webapp possible, only a
 few JSPs, but 
 
  
  
  
  POST doesn't 
 
  
  
  
 
=== message truncated ===




Discover Yahoo! 
Find restaurants, movies, travel and more fun for the weekend. Check it out! 
http://discover.yahoo.com/weekend.html 


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



force purge of All http sessions

2005-04-22 Thread Jimmy Ray
Is there a way to purge all the sessions on a Tomcat
instance?

Tomcat 5.0.28
JVM 1.4.2..

Regards,

Jimmy Ray



__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

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



Re: DBCP/JDBC Problems with DelegatingResultSet

2005-04-12 Thread Jimmy Ray
Do you mean that perhaps you are trying to access
SYBASE specific JDBC extensions?  If so, then you need
the inner most delegate connection.  I did this with
Oracle:

I also had this parameter in my JNDI declaration in
the server.xml...

parameter
   
nameaccessToUnderlyingConnectionAllowed/name
valuetrue/value
  /parameter

Then I used this static method that I wrote.  Just
pass in the JNDI data source name.  BUT...be careful,
DO NOT close this underlying connection, or your next
call will have the overhead of recreating the
underlying connection object for DBCP:

public static synchronized Connection
getDelegatingConnection(
String dataSource) throws
SQLException,NamingException,Exception {

final String JNDI_LOOKUP = java:comp/env;

Connection conn = null;
OracleConnection oc = null;

Context initCtx = new InitialContext();
Context envCtx = (Context)
initCtx.lookup(JNDI_LOOKUP);

if (envCtx == null) {
throw new Exception(No
EnvironmentContextException);
}

DataSource ds = (DataSource)
envCtx.lookup(dataSource);
if (ds == null) {
throw new Exception(No
DatasourceException);
}

((BasicDataSource)
ds).setAccessToUnderlyingConnectionAllowed(true);

conn = ds.getConnection();
if (conn == null) {
throw new Exception(No
ConnectionException);
} 

Connection dconn = ((DelegatingConnection)
conn).getInnermostDelegate();

if (dconn == null) {
throw new Exception(No
DelegatingConnectionException);
}

conn.close();
conn=null;

return dconn;
}

Regards,

Jimmy Ray
--- [EMAIL PROTECTED] wrote:
 
 
 
 
 Hello,
 
 I need some help accessing low level routines using
 JDNI based connection
 pooling provided by tomcat.
 
 Environment:  J2SE 1.4.2
 Tomcat: 5.5
 JDBC-Driver:  Sybase JConnect 5.5 (TDS)
 
 The Tomcat is configured to provide a small
 connection pool.
 
 Within my servlet i need access to the low-level
 implementation of the
 ResultSet from Sybase.
 The problem is, that the following code:
 
 Connection conn = dataSource.getConnection();
 Statement stmt = conn.getConnection();
 ResultSet result = stmt.executeQuery( ... );
 
 System.out.println( result.getClass().getName() );
 
 prints
 org.apache.tomcat.dbcp.dbcp.DelegatingResultSet.
 
 I couldn't find a api documentation for this class
 nor could i find the jar
 file providing this class
 at all in the tomcat installation directory.
 
 Can anyone give a hint in which JAR archive this
 class can be found ?
 
 
 
 Mit freundlichen Grüßen / Kind regards
 Sebastian Wiemer
 
 
 Sebastian Wiemer
 GfK Group
 Data Services GmbH
 Nordwestring 101
 D-90319 Nürnberg
 Fon: +49 (0) 911 395 3876
 Fax: +49 (0) 911 333 796
 [EMAIL PROTECTED]
 www.gfk.de / www.gfk.com
 
 
 
 
 _
 
 Diese E-Mail (ggf. nebst Anhang) enthält
 vertrauliche und/oder rechtlich
 geschützte Informationen. Wenn Sie nicht der
 richtige Adressat sind, oder
 diese E-Mail irrtümlich erhalten haben, informieren
 Sie bitte sofort den
 Absender und vernichten Sie diese Mail. Das
 unerlaubte Kopieren sowie die
 unbefugte Weitergabe dieser Mail ist nicht
 gestattet.
 
 This e-mail (and any attachment/s) contains
 confidential and/or privileged
 information. If you are not the intended recipient
 (or have received this
 e-mail in error) please notify the sender
 immediately and destroy this
 e-mail. Any unauthorised copying, disclosure or
 distribution of the
 material in this e-mail is strictly forbidden.
 _
 
 

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



__ 
Do you Yahoo!? 
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/

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



Max URL length for 5.0.28

2005-04-08 Thread Jimmy Ray
Tomcat 5.0.28, HPUX

Trying to use a URL that is 266 chars long and it
seems to be truncated.

Is there a max length setting for Tomcat?

Regards,

Jimmy Ray



__ 
Yahoo! Messenger 
Show us what our next emoticon should look like. Join the fun. 
http://www.advision.webevents.yahoo.com/emoticontest

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



Re: Apply single login (NTLM) on Tomcat

2005-04-01 Thread Jimmy Ray
We have been experimenting with JCIFS filters.  It
seems to be working fairly well.

http://jcifs.samba.org/

Regards,

Jimmy Ray


--- Marcus Nugroho [EMAIL PROTECTED] wrote:
 Hi All,
 
 We intend to use single user login using Windows NT
 for the Tomcat.
 so that the user can use the same user-id with his
 NT user to login into 
 our web application.
 Does anyone have experiences on how to apply it ? 
 
 TIA
 



__ 
Do you Yahoo!? 
Yahoo! Personals - Better first dates. More second dates. 
http://personals.yahoo.com


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



Limit catalina.out size

2005-03-29 Thread Jimmy Ray
Running on HPUX...SDK 1.4.2...the standard output is
going to catlaina.out.  Is it possible to change the
logger settings reduce the size of the catalina.out
file and perform circular logging?  If so where are
these settings?

Regards,

Jimmy Ray



__ 
Do you Yahoo!? 
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/ 

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



Re: Limit catalina.out size

2005-03-29 Thread Jimmy Ray
Sorry...Tomcat 5.0.28
--- Jimmy Ray [EMAIL PROTECTED] wrote:
 Running on HPUX...SDK 1.4.2...the standard output is
 going to catlaina.out.  Is it possible to change the
 logger settings reduce the size of the catalina.out
 file and perform circular logging?  If so where are
 these settings?
 
 Regards,
 
 Jimmy Ray
 
 
   
 __ 
 Do you Yahoo!? 
 Yahoo! Small Business - Try our new resources site!
 http://smallbusiness.yahoo.com/resources/ 
 

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



__ 
Do you Yahoo!? 
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/ 

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



Re: Using JDBC with 5.5.x

2005-03-29 Thread Jimmy Ray
This brought up an issue that we are having in 5.0.28.
 We can not get a JNDI data sources to work unless we
have a resource link entry in the application.xml file
in the $tomcat_home/conf/catalina/localhost directory.

If we do not have these entries then we get the error:

ERROR:  SQL Exception...Cannot create JDBC driver of
class '' for connect URL 'null'

Java code:

Connection conn = null;
Context initCtx = new InitialContext();
Context envCtx = (Context)
initCtx.lookup(JNDI_LOOKUP);  //data source name from
properties file

DataSource ds = (DataSource)
envCtx.lookup(dataSource);



Regards,

Jimmy Ray
--- Trond G. Ziarkowski
[EMAIL PROTECTED] wrote:

 Hi,
 
 the way to define JNDI Datasources has changed from
 5.0.x to 5.5.x. 
 Check out the docs 

http://jakarta.apache.org/tomcat/tomcat-5.5-doc/jndi-datasource-examples-howto.html
 
 Trond
 
 Martin Dubuc wrote:
 
 I am having some problems using JDBC with 5.5.x
 releases. I can use JDBC with 5.0.28, but as soon
 as I
 switch to 5.5.x, I get the following errors trying
 to
 connect to database:
 
 Mar 29, 2005 11:26:37 AM
 org.apache.catalina.realm.DataSourceRealm open
 SEVERE: Exception performing authentication
 org.apache.tomcat.dbcp.dbcp.SQLNestedException:
 Cannot
 create PoolableConnectionFactory (Server connection
 failure during transaction. Due to underlying
 exception: 'com.mysql.jdbc.CommunicationsException:
 Communications link failure due to underlying
 exception:
 
 ** BEGIN NESTED EXCEPTION **
 
 java.io.EOFException
 
 STACKTRACE:
 
 java.io.EOFException
 at
 com.mysql.jdbc.MysqlIO.readFully(MysqlIO.java:1842)
 at

com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2288)
 at

com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2784)
 at

com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:750)
 at

com.mysql.jdbc.MysqlIO.secureAuth411(MysqlIO.java:3573)
 at

com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1151)
 at

com.mysql.jdbc.Connection.createNewIO(Connection.java:1889)
 at

com.mysql.jdbc.Connection.init(Connection.java:430)
 at

com.mysql.jdbc.NonRegisteringDriver.connect(NonRegisteringDriver.java:268)
 at

org.apache.tomcat.dbcp.dbcp.DriverConnectionFactory.createConnection(DriverConnectionFactory.java:37)
 at

org.apache.tomcat.dbcp.dbcp.PoolableConnectionFactory.makeObject(PoolableConnectionFactory.java:290)
 at

org.apache.tomcat.dbcp.dbcp.BasicDataSource.validateConnectionFactory(BasicDataSource.java:877)
 at

org.apache.tomcat.dbcp.dbcp.BasicDataSource.createDataSource(BasicDataSource.java:851)
 at

org.apache.tomcat.dbcp.dbcp.BasicDataSource.getConnection(BasicDataSource.java:540)
 at

org.apache.catalina.realm.DataSourceRealm.open(DataSourceRealm.java:402)
 at

org.apache.catalina.realm.DataSourceRealm.authenticate(DataSourceRealm.java:282)
 at

org.apache.catalina.authenticator.FormAuthenticator.authenticate(FormAuthenticator.java:256)
 at

org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:391)
 at

org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
 at

org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
 at

org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:526)
 at

org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
 at

org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
 at

org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
 at

org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
 at

org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
 at

org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
 at

org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
 at java.lang.Thread.run(Thread.java:595)
 
 
 ** END NESTED EXCEPTION **
 
 '.
 
 ** BEGIN NESTED EXCEPTION **
 
 com.mysql.jdbc.CommunicationsException
 MESSAGE: Communications link failure due to
 underlying
 exception:
 
 ** BEGIN NESTED EXCEPTION **
 
 java.io.EOFException
 
 STACKTRACE:
 
 java.io.EOFException
 at
 com.mysql.jdbc.MysqlIO.readFully(MysqlIO.java:1842)
 at

com.mysql.jdbc.MysqlIO.reuseAndReadPacket(MysqlIO.java:2288)
 at

com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:2784)
 at

com.mysql.jdbc.MysqlIO.checkErrorPacket(MysqlIO.java:750)
 at

com.mysql.jdbc.MysqlIO.secureAuth411(MysqlIO.java:3573)
 at

com.mysql.jdbc.MysqlIO.doHandshake(MysqlIO.java:1151)
 at

com.mysql.jdbc.Connection.createNewIO(Connection.java:1889)
 at

com.mysql.jdbc.Connection.init(Connection.java

POST no longer working

2005-03-17 Thread Jimmy Ray
Tomcat 5.0.28 on HP UNIX:  I was using a filter
(jcfifs) in one of my web.xml files.  I have since
removed the filter and all code refering to it.  Now
web forms can not post to servlets in this app.  GET
methods work fine, but POST does not.  I am only using
Tomcat, no Apache front end.  Is there a security
settings that I missed or otherwise boogered up?

Regards,

Jimmy Ray



__ 
Do you Yahoo!? 
Read only the mail you want - Yahoo! Mail SpamGuard. 
http://promotions.yahoo.com/new_mail 

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



Re: POST no longer working

2005-03-17 Thread Jimmy Ray
What wasn't working was the POST was not sending any
parameters to the servlet.  In this servlet, I combine
the doGet and doPost and only a GET was providing the
servlet parameters from the web form.  The issue
seemed to be tied to the NTLM authentication that the
jcifs lib performed.  Once my session timed out, and a
new session was instantiated without the NTLM
authentication, the POST methods started sending
parameters again to the servlets.  

Thanks,

Jimmy Ray
--- QM [EMAIL PROTECTED] wrote:
 On Thu, Mar 17, 2005 at 06:45:56AM -0800, Jimmy Ray
 wrote:
 : Tomcat 5.0.28 on HP UNIX:  I was using a filter
 : (jcfifs) in one of my web.xml files.  I have since
 : removed the filter and all code refering to it. 
 Now
 : web forms can not post to servlets in this app. 
 GET
 : methods work fine, but POST does not.
 
 1/ at the risk of sounding flippant, diff the two
 code bases and see
 what changed
 
 2/ you'll have to elaborate on what doesn't work:
 error messages in the
 browser, log messages, etc.
 
 -QM
 
 -- 
 
 software   -- http://www.brandxdev.net
 tech news  -- http://www.RoarNetworX.com
 

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



__ 
Do you Yahoo!? 
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/ 

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



Mapping JSP

2005-03-17 Thread Jimmy Ray
I have several JSP that I want to be able to forward
to from servlets.  Right now I stick my JSP in
WEB-INF/jsp for security reasons.  I guess I need a
way to include a JSP mapping in the web.xml so that my
request dispatcher call does not include the WEB-INF
directory in its path.  Anyone know the syntax for
this JSP mapping?

Regards,

Jimmy Ray



__ 
Do you Yahoo!? 
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/ 

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



RE: Mapping JSP

2005-03-17 Thread Jimmy Ray
Thank-you, that worked famously.

Regards,
Jimmy Ray
--- Ramu, Vinod [EMAIL PROTECTED] wrote:
 Use jsp-file XML element (under servlet node) in
 your web.xml. Then
 dispatch the request to this resource using

ServletContext.getNamedDispatcher(nameoftheresource).
 If you use this
 method there is no need to use any path. It
 identifies the resources
 based on the name that you pass.
 
 Vinod
 
 -Original Message-
 From: Jimmy Ray [mailto:[EMAIL PROTECTED] 
 Sent: Thursday, March 17, 2005 4:31 PM
 To: tomcat-user@jakarta.apache.org
 Subject: Mapping JSP
 
 
 I have several JSP that I want to be able to forward
 to from servlets.  Right now I stick my JSP in
 WEB-INF/jsp for security reasons.  I guess I need a
 way to include a JSP mapping in the web.xml so that
 my
 request dispatcher call does not include the WEB-INF
 directory in its path.  Anyone know the syntax for
 this JSP mapping?
 
 Regards,
 
 Jimmy Ray
 
 
   
 __ 
 Do you Yahoo!? 
 Yahoo! Small Business - Try our new resources site!
 http://smallbusiness.yahoo.com/resources/ 
 

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



__ 
Do you Yahoo!? 
Yahoo! Small Business - Try our new resources site!
http://smallbusiness.yahoo.com/resources/ 

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



JK2 MX4J Dependancies

2004-05-27 Thread Wilson Jimmy - jiwils
Is there any work being done to support MX4J 2.0.x?  MX4J's 1.1.1 release is
no longer available from the MX4J web site.

Does anyone have any idea how big of a project this would be?  I might be
interested in helping to contribute if it is not too large.

Jimmy


**
The information contained in this communication is
confidential, is intended only for the use of the recipient
named above, and may be legally privileged.
If the reader of this message is not the intended
recipient, you are hereby notified that any dissemination, 
distribution, or copying of this communication is strictly
prohibited.
If you have received this communication in error,
please re-send this communication to the sender and
delete the original message or any copy of it from your
computer system. Thank You.


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



RE: Configuring mod_jk2/jk2 Via The JMX Console

2004-05-26 Thread Wilson Jimmy - jiwils
 the Remote JMX jk2 config is possible with this jk2.properties file
 configuration snipped
 With this configuration all JK2 Beans are reflect to the JMX MBeans 
 (Domain apache).
 Access the MBeans with http://localhost:9000. (Ignore the xsl mx4j error 
 at console)

Tomcat is definitely doing more with your described configuration than it
was (there are MBeanServer lines in catalina.out that were not there before
now), but I do not think that it is working as it should yet.

First, I am a bit confused, because it appears that I am setting up the
connector to listen at port 9050 with the line mx.httpPort=9050 yet you
tell me to use http://localhost:9000/; for MBean access.  Is this just a
typo?  Furthermore, a netstat indicates that nothing is listening on either
port 9000 or port 9050 after Tomcat starts, so is it even working?  Any
ideas what could be going wrong?  Would my log file, netstat output, or
jk2.properties file be of any help in determining what is wrong?  Another
oddity is that something is listening on port 8005 after I start Tomcat with
this configuration, but I can't browse to it with a web browser.

Second, after I get that working, is the 90?0 port number the port number
for the console (a web app of some kind) or is that just an HTTP connector
for the MBean Server?  Is it both?

Thanks for all of your help.

Jimmy


**
The information contained in this communication is
confidential, is intended only for the use of the recipient
named above, and may be legally privileged.
If the reader of this message is not the intended
recipient, you are hereby notified that any dissemination, 
distribution, or copying of this communication is strictly
prohibited.
If you have received this communication in error,
please re-send this communication to the sender and
delete the original message or any copy of it from your
computer system. Thank You.


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



RE: Configuring mod_jk2/jk2 Via The JMX Console

2004-05-26 Thread Wilson Jimmy - jiwils
You have made a copy from mx4j.tools.jar to $catalina.hom/bin and 
changed your setclasspath Skript ?

Please, send your log file output for more analyze steps.

While I was waiting on your response, I found out more information.  My
catalina.out file contains information that indicates that the HTTPAdapter
class could not be loaded even though mx4j-tools.jar is in the classpath.

Apparently, it boils down to the version of MX4J that I have.  I downloaded
MX4J 2.0.1.  The full class name for the HTTPAdapter class is
mx4j.tools.adapter.http.HTTPAdapter in this version.  The full class name
that Tomcat/JK2 is looking for is mx4j.adapter.http.HTTPAdapter.

Which version of MX4J contains the HTTPAdapter class packaged this way?  I
intend to try the 2.0.0 release (and the others after that until it works),
but is there an official version that I should be using with Tomcat/JK2?

Jimmy


**
The information contained in this communication is
confidential, is intended only for the use of the recipient
named above, and may be legally privileged.
If the reader of this message is not the intended
recipient, you are hereby notified that any dissemination, 
distribution, or copying of this communication is strictly
prohibited.
If you have received this communication in error,
please re-send this communication to the sender and
delete the original message or any copy of it from your
computer system. Thank You.


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



RE: Configuring mod_jk2/jk2 Via The JMX Console

2004-05-25 Thread Wilson Jimmy - jiwils
 
Furthermore, what are the interfaces of the JMX bean proxies that are
mentioned?  Are they standard, dynamic/model, or open mbeans?  Is
there a good page out there that details what the interfaces of the
mentioned MBean proxies look like?

Does anyone configure mod_jk2/jk2 in this manner?  If so, can you show me a
sample client?

What I really want to do is update workers2.properties from a remote
location.  Basically, I have some JBoss/Tomcat servers clustered, and as one
comes up/goes down, I would like to be able to programmatically update
mod_jk2's workers and URI mappings.  It seems like the Tomcat JK2 JMX
proxies are the way to go about this.  Is what I want to do even possible?

Jimmy
-- 
James Jimmy Wilson
Software Developer, Acxiom Corporation


**
The information contained in this communication is
confidential, is intended only for the use of the recipient
named above, and may be legally privileged.
If the reader of this message is not the intended
recipient, you are hereby notified that any dissemination, 
distribution, or copying of this communication is strictly
prohibited.
If you have received this communication in error,
please re-send this communication to the sender and
delete the original message or any copy of it from your
computer system. Thank You.


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



Configuring mod_jk2/jk2 Via The JMX Console

2004-05-24 Thread Wilson Jimmy - jiwils
The mod_jk2/jk2 web page indicates that a JMX console can be utilized for
runtime configuration changes:

On tomcat side, you must enable the JMX proxy. This is done by setting
modjk.webServerHost and modjk.webServerPort in jk2.properties to point
to the web server port that contains /jkstatus. ( recent versions of jk and
mod_jk are required ). You can also add mx4j-tools.jar to server/lib and set
mx.enable=true in jk2.properties to enable the console, or use your
favorite JMX console or tools. You could also select http and/or jrmp
protocol, with mx.httpPort, mx.httpHost, mxjrmpPort and mx.jrmpPort.

I have completed the configuration changes mentioned above, but I can not
find the mentioned JMX console.  Is it a web console?  Is it a GUI console?
Is something used from a shell?  If it is a web console, what is the context
for the URL?

Furthermore, what are the interfaces of the JMX bean proxies that are
mentioned?  Are they standard, dynamic/model, or open mbeans?  Is
there a good page out there that details what the interfaces of the
mentioned MBean proxies look like?

Does anyone configure mod_jk2/jk2 in this manner?  If so, can you show me a
sample client?

Any pointers/help would be greatly appreciated!

Jimmy
-- 
James Jimmy Wilson
Software Developer, Acxiom Corporation



**
The information contained in this communication is
confidential, is intended only for the use of the recipient
named above, and may be legally privileged.
If the reader of this message is not the intended
recipient, you are hereby notified that any dissemination, 
distribution, or copying of this communication is strictly
prohibited.
If you have received this communication in error,
please re-send this communication to the sender and
delete the original message or any copy of it from your
computer system. Thank You.


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



Tomcat 3.2 and 4.1 coexist?

2002-11-25 Thread jimmy
Hello Folks,

Is it possible to install Tomcat 3.2 and 4.1 on the
same server? Are there any side effects? Which path
needs to be followed to install 4.1 on a system that
has 3.2 installed?

The build list is rather long and complicated along
with references and dependancies to many packages.
Therefore any assistance would be appreciated from
someone who has already accomplished a similiar task.

Thanks for your time!

Tom Jerry

__
Do you Yahoo!?
Yahoo! Mail Plus – Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com

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




Latin2 code page

2001-06-25 Thread Rousseau, Jimmy



Hi,

I am using Czech 
characters (charset=windows-1250 ; that is Latin2 code page) in my .jsp pages, 
and the accented characters get transformed into question marks. How can I solve 
this?

Cheers,
Jimmy.