Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX: BasicDataSourceFactory

2005-02-05 Thread Mario Winterer
Hi Greg, hi David!
Sure, there is anoter factory you could use: The tomcat-built-in 
datasource factory. Unfortunately I do not know the classname of this 
factory, but I think it is somewhere in the library 
naming-factory-dbcp.jar which is located in common/lib.
(The Tomcat-guys didn't want to add the complete jakarta-commons-pool 
and jakarta-commons-dbcp libraries because most of the classes inside 
these libraries are not needed by tomcat. So they extracted the required 
classes only and repacked them thogether with some other classes into 
naming-factory-dbcp.jar. To avoid confusions and errors, they also 
modified the package names - thats why you get a ClassNotFoundException 
when you configure the JNDI-context to use the 
org.apache.commons.dbcp.BasicDataSourceFactory).
But I'm not sure if it is a good idea to extend one of those 
tomcat-internal datasource factories! This would REALLY tie your code 
close to tomcat!
Apart from that: If you implement/extend an existing DataSource factory, 
you have to put your implementation inside the common/classes directory 
- otherwise tomcat won't find it when it initializes the JNDI-context! 
So why not put the commons-pool and commons-dbcp jars into common/lib too?
So my suggestion: Extend BasicDataSourceFactory from commons-dbcp and 
put the two jars mentioned above into common/lib.

Best regards,
 Tex
Greg Guerin schrieb:
Hi David, Mario,
We actually specify the factory parameter because we extend the
BasicDataSourceFactory so we can encrypt passwords in the resource
definition.  My question is: Is there already a way to do that using another
factory I'm unaware of? It works fine, but we have to include the jars that
Mario mentioned and it'd be nice to not have to tie our code that close to
the container.
Greg
-Original Message-
From: Mario Winterer [mailto:[EMAIL PROTECTED] 
Sent: Thursday, February 03, 2005 4:37 PM
To: Tomcat Users List
Subject: Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX:
BasicDataSourceFactory

Hi David!
I think, you do not need to explicitely define a bean factory because Tomcat
5 automatically uses dbcp for JNDI-DataSources (I think tomcat looks at the
type of resource - in your case a javax.sql.DataSource - and uses the
tomcat-internal dbcp-factory). In my project, I've configured a
JNDI-DataSource using the Oracle thin driver and it works perfectly without
specifying a bean factory and without adding any special libraries to my
tomcat installation (apart from the oracle database driver which is in
commons/lib).
So try the following configuration:
Resource name=jdbc/as400 auth=Container
	type=javax.sql.DataSource
	maxActive=20 maxIdle=10 maxWait=-1
	removeAbandoned=true 
   removeAbandonedTimeout=60
   logAbandoned=true
   driverClassName=com.ibm.as400.access.AS400JDBCDriver

url=jdbc:as400://a53pb3;naming=system;libraries=,pgmdbt,caelib;errors=full
   username=userid 
   password=password
/

Again: You do not need any additional commons-libraries!
Best regards,
 Tex
 

Hi Mario,
Thanks for getting back to me.  Below is the context I set up.
After doing my own digging, I realized I was missing some jakarta 
commons jar files.  After getting these jars and restarting Tomcat the 
ClassNotFoundExceptions went away.

What I find really puzzling though is why I didn't get the same 
ClassNotFoundException on my local machine that was running the same 
version of Tomcat but on Windows XP profession.

Context debug=0 privileged=true
!-- the jdbc driver's jar needs to go into $CATALINA_HOME/common/lib
--
Resource name=jdbc/as400 auth=Container
  type=javax.sql.DataSource 
  factory=org.apache.commons.dbcp.BasicDataSourceFactory
  maxActive=20 
  maxIdle=10
  maxWait=-1
  removeAbandoned=true 
  removeAbandonedTimeout=60
  logAbandoned=true
  driverClassName=com.ibm.as400.access.AS400JDBCDriver

url=jdbc:as400://a53pb3;naming=system;libraries=,pgmdbt,caelib;errors=full
   


 

  username=userid 
  password=password/

/Context




Mario Winterer [EMAIL PROTECTED]
02/02/2005 07:19 PM
Please respond to
Tomcat Users List tomcat-user@jakarta.apache.org
To
Tomcat Users List tomcat-user@jakarta.apache.org cc
Subject
Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX: 
BasicDataSourceFactory



Hi!
How did you define your JDBC DataSource?
As far as I know, the original jakarta-commons-dbcp and 
jakarta-commons-pool-libraries are not included with Tomcat. Instead, 
just a subset of the required classes with modified package names 
(starting with 'org.apache.tomcat.dbcp') are packed in 
'naming-factory-dbcp.jar' that can be found in commons/lib.
But if you configure your JDBC DataSource correctly, this should not 
bother. Please post your resource-configuration!

Best regards,
Tex

   

I'm running Tomcat 5.5.4 on Windows 2000 Server and encountered

RE: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX: BasicDataSourceFactory

2005-02-04 Thread DAVID TURNER

Hi all,

Most of the examples I've come across
specify the factory parameter. And, after rereading the Tomcat docs,
those additional three commons jar files are needed.

I too, have gotten the datasource to
work when I didn't specify the factory parameter, but my impression right
now is that it's not pooling the datasources/connections when you don't
specify it.

Is there a way to see that Tomcat is
actually pooling these connections/datasources?








Greg Guerin
[EMAIL PROTECTED] 
02/03/2005 04:51 PM



Please respond to
Tomcat Users List tomcat-user@jakarta.apache.org





To
'Tomcat Users List'
tomcat-user@jakarta.apache.org


cc



Subject
RE: Tomcat 5.5.4/Windows
2000 server - Failed to register in JMX: BasicDataSourceFactory








Hi David, Mario,

We actually specify the factory parameter because we extend the
BasicDataSourceFactory so we can encrypt passwords in the resource
definition. My question is: Is there already a way to do that using
another
factory I'm unaware of? It works fine, but we have to include the jars
that
Mario mentioned and it'd be nice to not have to tie our code that close
to
the container.

Greg

-Original Message-
From: Mario Winterer [mailto:[EMAIL PROTECTED] 
Sent: Thursday, February 03, 2005 4:37 PM
To: Tomcat Users List
Subject: Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX:
BasicDataSourceFactory

Hi David!

I think, you do not need to explicitely define a bean factory because Tomcat
5 automatically uses dbcp for JNDI-DataSources (I think tomcat looks at
the
type of resource - in your case a javax.sql.DataSource - and uses the
tomcat-internal dbcp-factory). In my project, I've configured a
JNDI-DataSource using the Oracle thin driver and it works perfectly without
specifying a bean factory and without adding any special libraries to my
tomcat installation (apart from the oracle database driver which is in
commons/lib).

So try the following configuration:

Resource name=jdbc/as400 auth=Container

type=javax.sql.DataSource

maxActive=20 maxIdle=10 maxWait=-1

removeAbandoned=true 
removeAbandonedTimeout=60
logAbandoned=true
driverClassName=com.ibm.as400.access.AS400JDBCDriver
 
url="">
username=userid 
password=password
/

Again: You do not need any additional commons-libraries!

Best regards,
 Tex

Hi Mario,

Thanks for getting back to me. Below is the context I set up.

After doing my own digging, I realized I was missing some jakarta 
commons jar files. After getting these jars and restarting Tomcat
the 
ClassNotFoundExceptions went away.

What I find really puzzling though is why I didn't get the same 
ClassNotFoundException on my local machine that was running the same

version of Tomcat but on Windows XP profession.


Context debug=0 privileged=true

 !-- the jdbc driver's jar needs to go into $CATALINA_HOME/common/lib
--
 Resource name=jdbc/as400 auth=Container
type=javax.sql.DataSource

factory=org.apache.commons.dbcp.BasicDataSourceFactory
maxActive=20

maxIdle=10
maxWait=-1
removeAbandoned=true

removeAbandonedTimeout=60
logAbandoned=true
driverClassName=com.ibm.as400.access.AS400JDBCDriver
 
url="">

username=userid

password=password/
 
/Context









Mario Winterer [EMAIL PROTECTED]
02/02/2005 07:19 PM
Please respond to
Tomcat Users List tomcat-user@jakarta.apache.org


To
Tomcat Users List tomcat-user@jakarta.apache.org cc

Subject
Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX: 
BasicDataSourceFactory






Hi!

How did you define your JDBC DataSource?
As far as I know, the original jakarta-commons-dbcp and 
jakarta-commons-pool-libraries are not included with Tomcat. Instead,

just a subset of the required classes with modified package names 
(starting with 'org.apache.tomcat.dbcp') are packed in 
'naming-factory-dbcp.jar' that can be found in commons/lib.
But if you configure your JDBC DataSource correctly, this should not

bother. Please post your resource-configuration!

Best regards,
 Tex

 

I'm running Tomcat 5.5.4 on Windows 2000 Server and encountered
the 
below
  


 

error on Tomcat startup: 

Feb 2, 2005 10:50:49 AM org.apache.catalina.core.NamingContextListener
addResource
WARNING: Failed to register in JMX: javax.naming.NamingException:

Could not create resource factory, 
ClassNotFoundException:org.apache.commons.dbcp.BasicDataSourceFactory


My webapp uses JDBC DataSource's and the BasicDataSourceFactory
for 
pooling so this problem of ClassNotFoundException is
causing my 
webapp to not work properly.

I have Tomcat 5.5.4 also installed on my local maching which has

Windows XP on it, and there is absolutely no problem on startup
and 
and my
  

webapp.
 

Does anyone no what's happening here? Why does Tomcat register
the 
BasicDataSourceFactory with no problems in Tomcat 5.5.4 on Windows
XP 
and
  


 


Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX: BasicDataSourceFactory

2005-02-04 Thread Parsons Technical Services
Look at your database. There should be at least the pool size of connections 
open when there is no activity.

Whether or not you specify the factory depends on the factory being used. If 
it is a standard factory in Tomcat that Tomcat is already aware of, it is 
not needed. But if you use a set of drivers that use a different or special 
factory you will need to call it out. This information is in the docs but is 
a little scattered. Read all the pages on jndi, jdbc and global resources.
Including:

http://jakarta.apache.org/tomcat/tomcat-5.0-doc/jndi-resources-howto.html
The other simple answer is what code are you using? If you are calling the 
DriverManager then no, but if you are calling
DataSource ds = (DataSource) ctx.lookup(java:comp/env/jdbc/myDB); or 
similar then you are using Tomcats built in pooling. Otherwise you would get 
an error.


Doug

- Original Message - 
From: DAVID TURNER [EMAIL PROTECTED]
To: Tomcat Users List tomcat-user@jakarta.apache.org
Sent: Friday, February 04, 2005 8:19 AM
Subject: RE: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX: 
BasicDataSourceFactory


Hi all,
Most of the examples I've come across specify the factory parameter.  And,
after rereading the Tomcat docs, those additional three commons jar files
are needed.
I too, have gotten the datasource to work when I didn't specify the
factory parameter, but my impression right now is that it's not pooling
the datasources/connections when you don't specify it.
Is there a way to see that Tomcat is actually pooling these
connections/datasources?


Greg Guerin [EMAIL PROTECTED]
02/03/2005 04:51 PM
Please respond to
Tomcat Users List tomcat-user@jakarta.apache.org
To
'Tomcat Users List' tomcat-user@jakarta.apache.org
cc
Subject
RE: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX:
BasicDataSourceFactory


Hi David, Mario,
We actually specify the factory parameter because we extend the
BasicDataSourceFactory so we can encrypt passwords in the resource
definition.  My question is: Is there already a way to do that using
another
factory I'm unaware of? It works fine, but we have to include the jars
that
Mario mentioned and it'd be nice to not have to tie our code that close to
the container.
Greg
-Original Message-
From: Mario Winterer [mailto:[EMAIL PROTECTED]
Sent: Thursday, February 03, 2005 4:37 PM
To: Tomcat Users List
Subject: Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX:
BasicDataSourceFactory
Hi David!
I think, you do not need to explicitely define a bean factory because
Tomcat
5 automatically uses dbcp for JNDI-DataSources (I think tomcat looks at
the
type of resource - in your case a javax.sql.DataSource - and uses the
tomcat-internal dbcp-factory). In my project, I've configured a
JNDI-DataSource using the Oracle thin driver and it works perfectly
without
specifying a bean factory and without adding any special libraries to my
tomcat installation (apart from the oracle database driver which is in
commons/lib).
So try the following configuration:
Resource name=jdbc/as400 auth=Container
type=javax.sql.DataSource
maxActive=20 maxIdle=10 maxWait=-1
removeAbandoned=true
   removeAbandonedTimeout=60
   logAbandoned=true
   driverClassName=com.ibm.as400.access.AS400JDBCDriver
url=jdbc:as400://a53pb3;naming=system;libraries=,pgmdbt,caelib;errors=full
   username=userid
   password=password
/
Again: You do not need any additional commons-libraries!
Best regards,
 Tex
Hi Mario,
Thanks for getting back to me.  Below is the context I set up.
After doing my own digging, I realized I was missing some jakarta
commons jar files.  After getting these jars and restarting Tomcat the
ClassNotFoundExceptions went away.
What I find really puzzling though is why I didn't get the same
ClassNotFoundException on my local machine that was running the same
version of Tomcat but on Windows XP profession.
Context debug=0 privileged=true
 !-- the jdbc driver's jar needs to go into $CATALINA_HOME/common/lib
--
 Resource name=jdbc/as400 auth=Container
   type=javax.sql.DataSource
   factory=org.apache.commons.dbcp.BasicDataSourceFactory
   maxActive=20
   maxIdle=10
   maxWait=-1
   removeAbandoned=true
   removeAbandonedTimeout=60
   logAbandoned=true
   driverClassName=com.ibm.as400.access.AS400JDBCDriver
url=jdbc:as400://a53pb3;naming=system;libraries=,pgmdbt,caelib;errors=full

   username=userid
   password=password/
/Context




Mario Winterer [EMAIL PROTECTED]
02/02/2005 07:19 PM
Please respond to
Tomcat Users List tomcat-user@jakarta.apache.org
To
Tomcat Users List tomcat-user@jakarta.apache.org cc
Subject
Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX:
BasicDataSourceFactory


Hi!
How did you define your JDBC DataSource?
As far as I know, the original jakarta

Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX: BasicDataSourceFactory

2005-02-03 Thread DAVID TURNER
Hi Mario,

Thanks for getting back to me.  Below is the context I set up.

After doing my own digging, I realized I was missing some jakarta commons 
jar files.  After getting these jars and restarting Tomcat the 
ClassNotFoundExceptions went away.

What I find really puzzling though is why I didn't get the same 
ClassNotFoundException on my local machine that was running the same 
version of Tomcat but on Windows XP profession.


Context debug=0 privileged=true

  !-- the jdbc driver's jar needs to go into $CATALINA_HOME/common/lib 
--
  Resource name=jdbc/as400 auth=Container
type=javax.sql.DataSource 
factory=org.apache.commons.dbcp.BasicDataSourceFactory
maxActive=20 
maxIdle=10
maxWait=-1
removeAbandoned=true 
removeAbandonedTimeout=60
logAbandoned=true
driverClassName=com.ibm.as400.access.AS400JDBCDriver
 
url=jdbc:as400://a53pb3;naming=system;libraries=,pgmdbt,caelib;errors=full
username=userid 
password=password/ 
 
/Context









Mario Winterer [EMAIL PROTECTED] 
02/02/2005 07:19 PM
Please respond to
Tomcat Users List tomcat-user@jakarta.apache.org


To
Tomcat Users List tomcat-user@jakarta.apache.org
cc

Subject
Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX: 
BasicDataSourceFactory






Hi!

How did you define your JDBC DataSource?
As far as I know, the original jakarta-commons-dbcp and 
jakarta-commons-pool-libraries are not included with Tomcat. Instead, 
just a subset of the required classes with modified package names 
(starting with 'org.apache.tomcat.dbcp') are packed in 
'naming-factory-dbcp.jar' that can be found in commons/lib.
But if you configure your JDBC DataSource correctly, this should not 
bother. Please post your resource-configuration!

Best regards,
  Tex

I'm running Tomcat 5.5.4 on Windows 2000 Server and encountered the below 

error on Tomcat startup: 

Feb 2, 2005 10:50:49 AM org.apache.catalina.core.NamingContextListener 
addResource
WARNING: Failed to register in JMX: javax.naming.NamingException: Could 
not create resource factory, 
ClassNotFoundException:org.apache.commons.dbcp.BasicDataSourceFactory


My webapp uses JDBC DataSource's and the BasicDataSourceFactory for 
pooling so this problem of ClassNotFoundException is causing my webapp 
to not work properly.

I have Tomcat 5.5.4 also installed on my local maching which has Windows 
XP on it, and there is absolutely no problem on startup and and my 
webapp.

Does anyone no what's happening here?  Why does Tomcat register the 
BasicDataSourceFactory with no problems in Tomcat 5.5.4 on Windows XP and 

not on Windows 2000 Server?


 



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




Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX: BasicDataSourceFactory

2005-02-03 Thread Mario Winterer
Hi David!
I think, you do not need to explicitely define a bean factory because 
Tomcat 5 automatically uses dbcp for JNDI-DataSources (I think tomcat 
looks at the type of resource - in your case a javax.sql.DataSource - 
and uses the tomcat-internal dbcp-factory). In my project, I've 
configured a JNDI-DataSource using the Oracle thin driver and it works 
perfectly without specifying a bean factory and without adding any 
special libraries to my tomcat installation (apart from the oracle 
database driver which is in commons/lib).

So try the following configuration:
Resource name=jdbc/as400 auth=Container
	type=javax.sql.DataSource
	maxActive=20 maxIdle=10 maxWait=-1
	removeAbandoned=true 
   removeAbandonedTimeout=60
   logAbandoned=true
   driverClassName=com.ibm.as400.access.AS400JDBCDriver
   url=jdbc:as400://a53pb3;naming=system;libraries=,pgmdbt,caelib;errors=full
   username=userid 
   password=password
/

Again: You do not need any additional commons-libraries!
Best regards,
 Tex
Hi Mario,
Thanks for getting back to me.  Below is the context I set up.
After doing my own digging, I realized I was missing some jakarta commons 
jar files.  After getting these jars and restarting Tomcat the 
ClassNotFoundExceptions went away.

What I find really puzzling though is why I didn't get the same 
ClassNotFoundException on my local machine that was running the same 
version of Tomcat but on Windows XP profession.

Context debug=0 privileged=true
 !-- the jdbc driver's jar needs to go into $CATALINA_HOME/common/lib 
--
 Resource name=jdbc/as400 auth=Container
   type=javax.sql.DataSource 
   factory=org.apache.commons.dbcp.BasicDataSourceFactory
   maxActive=20 
   maxIdle=10
   maxWait=-1
   removeAbandoned=true 
   removeAbandonedTimeout=60
   logAbandoned=true
   driverClassName=com.ibm.as400.access.AS400JDBCDriver

url=jdbc:as400://a53pb3;naming=system;libraries=,pgmdbt,caelib;errors=full
   username=userid 
   password=password/ 

/Context




Mario Winterer [EMAIL PROTECTED] 
02/02/2005 07:19 PM
Please respond to
Tomcat Users List tomcat-user@jakarta.apache.org

To
Tomcat Users List tomcat-user@jakarta.apache.org
cc
Subject
Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX: 
BasicDataSourceFactory



Hi!
How did you define your JDBC DataSource?
As far as I know, the original jakarta-commons-dbcp and 
jakarta-commons-pool-libraries are not included with Tomcat. Instead, 
just a subset of the required classes with modified package names 
(starting with 'org.apache.tomcat.dbcp') are packed in 
'naming-factory-dbcp.jar' that can be found in commons/lib.
But if you configure your JDBC DataSource correctly, this should not 
bother. Please post your resource-configuration!

Best regards,
 Tex
 

I'm running Tomcat 5.5.4 on Windows 2000 Server and encountered the below 
   

 

error on Tomcat startup: 

Feb 2, 2005 10:50:49 AM org.apache.catalina.core.NamingContextListener 
addResource
WARNING: Failed to register in JMX: javax.naming.NamingException: Could 
not create resource factory, 
ClassNotFoundException:org.apache.commons.dbcp.BasicDataSourceFactory

My webapp uses JDBC DataSource's and the BasicDataSourceFactory for 
pooling so this problem of ClassNotFoundException is causing my webapp 
to not work properly.

I have Tomcat 5.5.4 also installed on my local maching which has Windows 
XP on it, and there is absolutely no problem on startup and and my 
   

webapp.
 

Does anyone no what's happening here?  Why does Tomcat register the 
BasicDataSourceFactory with no problems in Tomcat 5.5.4 on Windows XP and 
   

 

not on Windows 2000 Server?

   


-
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: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX: BasicDataSourceFactory

2005-02-03 Thread Greg Guerin
Hi David, Mario,

We actually specify the factory parameter because we extend the
BasicDataSourceFactory so we can encrypt passwords in the resource
definition.  My question is: Is there already a way to do that using another
factory I'm unaware of? It works fine, but we have to include the jars that
Mario mentioned and it'd be nice to not have to tie our code that close to
the container.

Greg

-Original Message-
From: Mario Winterer [mailto:[EMAIL PROTECTED] 
Sent: Thursday, February 03, 2005 4:37 PM
To: Tomcat Users List
Subject: Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX:
BasicDataSourceFactory

Hi David!

I think, you do not need to explicitely define a bean factory because Tomcat
5 automatically uses dbcp for JNDI-DataSources (I think tomcat looks at the
type of resource - in your case a javax.sql.DataSource - and uses the
tomcat-internal dbcp-factory). In my project, I've configured a
JNDI-DataSource using the Oracle thin driver and it works perfectly without
specifying a bean factory and without adding any special libraries to my
tomcat installation (apart from the oracle database driver which is in
commons/lib).

So try the following configuration:

Resource name=jdbc/as400 auth=Container
type=javax.sql.DataSource
maxActive=20 maxIdle=10 maxWait=-1
removeAbandoned=true 
removeAbandonedTimeout=60
logAbandoned=true
driverClassName=com.ibm.as400.access.AS400JDBCDriver
 
url=jdbc:as400://a53pb3;naming=system;libraries=,pgmdbt,caelib;errors=full
username=userid 
password=password
/

Again: You do not need any additional commons-libraries!

Best regards,
  Tex

Hi Mario,

Thanks for getting back to me.  Below is the context I set up.

After doing my own digging, I realized I was missing some jakarta 
commons jar files.  After getting these jars and restarting Tomcat the 
ClassNotFoundExceptions went away.

What I find really puzzling though is why I didn't get the same 
ClassNotFoundException on my local machine that was running the same 
version of Tomcat but on Windows XP profession.


Context debug=0 privileged=true

  !-- the jdbc driver's jar needs to go into $CATALINA_HOME/common/lib
--
  Resource name=jdbc/as400 auth=Container
type=javax.sql.DataSource 
factory=org.apache.commons.dbcp.BasicDataSourceFactory
maxActive=20 
maxIdle=10
maxWait=-1
removeAbandoned=true 
removeAbandonedTimeout=60
logAbandoned=true
driverClassName=com.ibm.as400.access.AS400JDBCDriver
 
url=jdbc:as400://a53pb3;naming=system;libraries=,pgmdbt,caelib;errors=full

username=userid 
password=password/
 
/Context









Mario Winterer [EMAIL PROTECTED]
02/02/2005 07:19 PM
Please respond to
Tomcat Users List tomcat-user@jakarta.apache.org


To
Tomcat Users List tomcat-user@jakarta.apache.org cc

Subject
Re: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX: 
BasicDataSourceFactory






Hi!

How did you define your JDBC DataSource?
As far as I know, the original jakarta-commons-dbcp and 
jakarta-commons-pool-libraries are not included with Tomcat. Instead, 
just a subset of the required classes with modified package names 
(starting with 'org.apache.tomcat.dbcp') are packed in 
'naming-factory-dbcp.jar' that can be found in commons/lib.
But if you configure your JDBC DataSource correctly, this should not 
bother. Please post your resource-configuration!

Best regards,
  Tex

  

I'm running Tomcat 5.5.4 on Windows 2000 Server and encountered the 
below



  

error on Tomcat startup: 

Feb 2, 2005 10:50:49 AM org.apache.catalina.core.NamingContextListener
addResource
WARNING: Failed to register in JMX: javax.naming.NamingException: 
Could not create resource factory, 
ClassNotFoundException:org.apache.commons.dbcp.BasicDataSourceFactory


My webapp uses JDBC DataSource's and the BasicDataSourceFactory for 
pooling so this problem of ClassNotFoundException is causing my 
webapp to not work properly.

I have Tomcat 5.5.4 also installed on my local maching which has 
Windows XP on it, and there is absolutely no problem on startup and 
and my


webapp.
  

Does anyone no what's happening here?  Why does Tomcat register the 
BasicDataSourceFactory with no problems in Tomcat 5.5.4 on Windows XP 
and



  

not on Windows 2000 Server?








-
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: Tomcat 5.5.4/Windows 2000 server - Failed to register in JMX: BasicDataSourceFactory

2005-02-02 Thread Mario Winterer
Hi!
How did you define your JDBC DataSource?
As far as I know, the original jakarta-commons-dbcp and 
jakarta-commons-pool-libraries are not included with Tomcat. Instead, 
just a subset of the required classes with modified package names 
(starting with 'org.apache.tomcat.dbcp') are packed in 
'naming-factory-dbcp.jar' that can be found in commons/lib.
But if you configure your JDBC DataSource correctly, this should not 
bother. Please post your resource-configuration!

Best regards,
 Tex
I'm running Tomcat 5.5.4 on Windows 2000 Server and encountered the below 
error on Tomcat startup: 

Feb 2, 2005 10:50:49 AM org.apache.catalina.core.NamingContextListener 
addResource
WARNING: Failed to register in JMX: javax.naming.NamingException: Could 
not create resource factory, 
ClassNotFoundException:org.apache.commons.dbcp.BasicDataSourceFactory

My webapp uses JDBC DataSource's and the BasicDataSourceFactory for 
pooling so this problem of ClassNotFoundException is causing my webapp 
to not work properly.

I have Tomcat 5.5.4 also installed on my local maching which has Windows 
XP on it, and there is absolutely no problem on startup and and my webapp.

Does anyone no what's happening here?  Why does Tomcat register the 
BasicDataSourceFactory with no problems in Tomcat 5.5.4 on Windows XP and 
not on Windows 2000 Server?

 


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


RE: Tomcat at Windows 2000

2001-04-17 Thread Chelkowski, Tadeusz

try to run this from cmd

 -Original Message-
 From: Chris Andreou [SMTP:[EMAIL PROTECTED]]
 Sent: 16 kwietnia 2001 20:28
 To:   '[EMAIL PROTECTED]'
 Subject:  RE: Tomcat at Windows 2000
 
 Set the Http Server on Tomcat and it will show the error (standalone) and
 the window will not close
 
 
 -Original Message-
 From: Daniel de Almeida Alvares [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 11, 2001 8:16 AM
 To: [EMAIL PROTECTED]
 Subject: Tomcat at Windows 2000
 
 
 Hi,
 I am trying to run Jakarta at Windows 2000, but I am having my jakarta
 window closed as soon as it starts !!!
 What kind of problem is that ?
 at Win98 I wasnt having any problem and it was working well 
 Can anybody helps me ???
 
 Regards
 Daniel
 
 Daniel Alvares
 Santos - SP - Brazil



RE: Tomcat at Windows 2000

2001-04-16 Thread Chris Andreou

Set the Http Server on Tomcat and it will show the error (standalone) and
the window will not close


-Original Message-
From: Daniel de Almeida Alvares [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, April 11, 2001 8:16 AM
To: [EMAIL PROTECTED]
Subject: Tomcat at Windows 2000


Hi,
I am trying to run Jakarta at Windows 2000, but I am having my jakarta
window closed as soon as it starts !!!
What kind of problem is that ?
at Win98 I wasnt having any problem and it was working well 
Can anybody helps me ???

Regards
Daniel

Daniel Alvares
Santos - SP - Brazil



RE: Tomcat at Windows 2000

2001-04-11 Thread Randy Layman


Instead of running startup.bat, try running tomcat.bat run - this
will start Tomcat in the same DOS prompts as its launched from.  You problem
is most likely one of two things:
1.  Something is already using the ports Tomcat is trying to use
(8080 and 8007).  Microsoft has included netstat with 2000 so that you can
tell what addresses are in use
2.  Something with the JVM/jar files is wrong and Tomcat can't find
one of its critical JARs (this would include having two XML parsers for
Tomcat 3.2).

In either case, the error message will tell you what the problem is
and the solution should be straight forward.

Randy


 -Original Message-
 From: Daniel de Almeida Alvares [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 11, 2001 9:16 AM
 To: [EMAIL PROTECTED]
 Subject: Tomcat at Windows 2000
 
 
 Hi,
 I am trying to run Jakarta at Windows 2000, but I am having my jakarta
 window closed as soon as it starts !!!
 What kind of problem is that ?
 at Win98 I wasnt having any problem and it was working well 
 Can anybody helps me ???
 
 Regards
 Daniel
 
 Daniel Alvares
 Santos - SP - Brazil
 



Re: Tomcat at Windows 2000

2001-04-11 Thread Daniel de Almeida Alvares

But I can run JSWDK's startserver command with no problems  it s using
8080 port.
[]
Daniel
___
Daniel de Almeida Alvares
Santos - SP - Brasil
[EMAIL PROTECTED]

- Original Message -
From: "Randy Layman" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, April 11, 2001 9:54 AM
Subject: RE: Tomcat at Windows 2000



Instead of running startup.bat, try running tomcat.bat run - this
will start Tomcat in the same DOS prompts as its launched from.  You problem
is most likely one of two things:
1.  Something is already using the ports Tomcat is trying to use
(8080 and 8007).  Microsoft has included netstat with 2000 so that you can
tell what addresses are in use
2.  Something with the JVM/jar files is wrong and Tomcat can't find
one of its critical JARs (this would include having two XML parsers for
Tomcat 3.2).

In either case, the error message will tell you what the problem is
and the solution should be straight forward.

Randy


 -Original Message-
 From: Daniel de Almeida Alvares [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 11, 2001 9:16 AM
 To: [EMAIL PROTECTED]
 Subject: Tomcat at Windows 2000


 Hi,
 I am trying to run Jakarta at Windows 2000, but I am having my jakarta
 window closed as soon as it starts !!!
 What kind of problem is that ?
 at Win98 I wasnt having any problem and it was working well 
 Can anybody helps me ???

 Regards
 Daniel

 Daniel Alvares
 Santos - SP - Brazil





RE: Tomcat at Windows 2000

2001-04-11 Thread Randy Layman


The server.xml file that you have is misconfigured - the class name
is org.request.SimpleMapper1.  (Anyone know why the server.xml configuration
on recent downloads is wrong?)

Randy

 -Original Message-
 From: Daniel de Almeida Alvares [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 11, 2001 9:26 AM
 To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
 Subject: Re: Tomcat at Windows 2000
 
 
 Ok... thanks !!!
 I did that and had this:
 
 C:\jakarta-tomcat\bintomcat run
 Including all jars in c:\jakarta-tomcat\lib in your CLASSPATH.
 
 Using CLASSPATH: c:\jakarta-tomcat\classes;c:\jakarta-tomcat\lib\ant
 rta-tomcat\lib\jasper.jar;c:\jakarta-tomcat\lib\jaxp.jar;c:\jakarta-
 arser.jar;c:\jakarta-tomcat\lib\servlet.jar;c:\jakarta-tomcat\lib\we
 .;c:\jdk13\lib;c:\jdk13\lib\tools.jar;c:\jswdk101\lib\servlet.jar;c:
 omp.jar;c:\jdk13\lib\tools.jar
 
 ERROR reading c:\jakarta-tomcat\conf\server.xml
 At Line 48 /Server/ContextManager/RequestInterceptor/ className=org.
 t.request.SimpleMapper debug=0
 
 FATAL: configuration error
 java.lang.ClassNotFoundException: org.apache.tomcat.request.SimpleMa
 at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
 at java.security.AccessController.doPrivileged(Native Method
 at java.net.URLClassLoader.findClass(URLClassLoader.java:188
 at java.lang.ClassLoader.loadClass(ClassLoader.java:297)
 at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:
 at java.lang.ClassLoader.loadClass(ClassLoader.java:253)
 at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:
 at java.lang.Class.forName0(Native Method)
 at java.lang.Class.forName(Class.java:120)
 at org.apache.tomcat.util.xml.ObjectCreate.start(XmlMapper.j
 at org.apache.tomcat.util.xml.XmlMapper.matchStart(XmlMapper
 at org.apache.tomcat.util.xml.XmlMapper.startElement(XmlMapp
 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.ja
 at org.apache.tomcat.startup.Tomcat.execute(Tomcat.java:187)
 at org.apache.tomcat.startup.Tomcat.main(Tomcat.java:235)
 
 
 
 
 any sugestions  (yesterday I spent all morning and didnt find a
 solution !!)
 
 Regards
 Daniel
 ___
 Daniel Alvares
 Santos - SP - Brasil
 [EMAIL PROTECTED]
 
 
 - Original Message -
 From: "Benot Jacquemont" [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]; "'Daniel de Almeida Alvares'"
 [EMAIL PROTECTED]
 Sent: Wednesday, April 11, 2001 10:24 AM
 Subject: RE: Tomcat at Windows 2000
 
 
  I use Tomcat on W2K Pro, and it works fine. Anyway, the 
 reason why your
  window closes, is because an error occurs. You should try to open a
 command
  line window, go to the TOMCAT_HOME\bin directory and try tomcat run
 instead
  of startup. You will see the error.
 
  Benot
   Hi,
   I am trying to run Jakarta at Windows 2000, but I am 
 having my jakarta
   window closed as soon as it starts !!!
   What kind of problem is that ?
   at Win98 I wasnt having any problem and it was working well 
   Can anybody helps me ???
  
   Regards
   Daniel
  
   Daniel Alvares
   Santos - SP - Brazil
 
 



Re: Tomcat at Windows 2000

2001-04-11 Thread Daniel de Almeida Alvares

I changed thatbut now I am having


FATAL: configuration error
java.lang.ClassNotFoundException: org.apache.tomcat.request.SecurityCheck

and dont have this class (SecurityCheck) here 

[]
Daniel


- Original Message -
From: "Randy Layman" [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Wednesday, April 11, 2001 10:04 AM
Subject: RE: Tomcat at Windows 2000



The server.xml file that you have is misconfigured - the class name
is org.request.SimpleMapper1.  (Anyone know why the server.xml configuration
on recent downloads is wrong?)

Randy

 -Original Message-
 From: Daniel de Almeida Alvares [mailto:[EMAIL PROTECTED]]
 Sent: Wednesday, April 11, 2001 9:26 AM
 To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
 Subject: Re: Tomcat at Windows 2000


 Ok... thanks !!!
 I did that and had this:

 C:\jakarta-tomcat\bintomcat run
 Including all jars in c:\jakarta-tomcat\lib in your CLASSPATH.

 Using CLASSPATH: c:\jakarta-tomcat\classes;c:\jakarta-tomcat\lib\ant
 rta-tomcat\lib\jasper.jar;c:\jakarta-tomcat\lib\jaxp.jar;c:\jakarta-
 arser.jar;c:\jakarta-tomcat\lib\servlet.jar;c:\jakarta-tomcat\lib\we
 .;c:\jdk13\lib;c:\jdk13\lib\tools.jar;c:\jswdk101\lib\servlet.jar;c:
 omp.jar;c:\jdk13\lib\tools.jar

 ERROR reading c:\jakarta-tomcat\conf\server.xml
 At Line 48 /Server/ContextManager/RequestInterceptor/ className=org.
 t.request.SimpleMapper debug=0

 FATAL: configuration error
 java.lang.ClassNotFoundException: org.apache.tomcat.request.SimpleMa
 at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
 at java.security.AccessController.doPrivileged(Native Method
 at java.net.URLClassLoader.findClass(URLClassLoader.java:188
 at java.lang.ClassLoader.loadClass(ClassLoader.java:297)
 at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:
 at java.lang.ClassLoader.loadClass(ClassLoader.java:253)
 at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:
 at java.lang.Class.forName0(Native Method)
 at java.lang.Class.forName(Class.java:120)
 at org.apache.tomcat.util.xml.ObjectCreate.start(XmlMapper.j
 at org.apache.tomcat.util.xml.XmlMapper.matchStart(XmlMapper
 at org.apache.tomcat.util.xml.XmlMapper.startElement(XmlMapp
 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.ja
 at org.apache.tomcat.startup.Tomcat.execute(Tomcat.java:187)
 at org.apache.tomcat.startup.Tomcat.main(Tomcat.java:235)




 any sugestions  (yesterday I spent all morning and didnt find a
 solution !!)

 Regards
 Daniel
 ___
 Daniel Alvares
 Santos - SP - Brasil
 [EMAIL PROTECTED]


 - Original Message -
 From: "Benot Jacquemont" [EMAIL PROTECTED]
 To: [EMAIL PROTECTED]; "'Daniel de Almeida Alvares'"
 [EMAIL PROTECTED]
 Sent: Wednesday, April 11, 2001 10:24 AM
 Subject: RE: Tomcat at Windows 2000


  I use Tomcat on W2K Pro, and it works fine. Anyway, the
 reason why your
  window closes, is because an error occurs. You should try to open a
 command
  line window, go to the TOMCAT_HOME\bin directory and try tomcat run
 instead
  of startup. You will see the error.
 
  Benot
   Hi,
   I am trying to run Jakarta at Windows 2000, but I am
 having my jakarta
   window closed as soon as it starts !!!
   What kind of problem is that ?
   at Win98 I wasnt having any problem and it was working well 
   Can anybody helps me ???
  
   Regards
   Daniel
  
   Daniel Alvares
   Santos - SP - Brazil