System.setProperty failed during Tomcat5 startup

2006-05-09 Thread lee hwaying
Tomcat startup fail with below error log when Springframework tried to call 
System.setProperty.

Can some one help me?
I ran the code succesyfully at windows pc but not on unix server

thanks
hy

java.security.AccessControlException: access denied
(java.util.PropertyPermission webApp.root write)
@4000445f114f374f04fc at
java.security.AccessControlContext.checkPermission
java.security.AccessController.checkPermission(AccessController.java:427)
@4000445f114f374f149c at java.lang.SecurityManager.checkPermission
(SecurityManager.java:532)
@4000445f114f374fa524 at java.lang.System.setProperty
(System.java:698)
@4000445f114f374facf4 at
org.springframework.web.util.WebUtils.setWebAppRootSystemProperty
(WebUtils.java:104)
@4000445f114f374fb4c4 at
org.springframework.web.util.Log4jWebConfigurer.initLogging



From: Tim Lucia [EMAIL PROTECTED]
Reply-To: Tomcat Users List users@tomcat.apache.org
To: 'Tomcat Users List' users@tomcat.apache.org
Subject: RE: Default servlet
Date: Tue, 9 May 2006 07:15:47 -0400

Mark is right (of course)... my bad.

-Original Message-
From: Mark Thomas [mailto:[EMAIL PROTECTED]
Sent: Monday, May 08, 2006 10:14 PM
To: Tomcat Users List
Subject: Re: Default servlet

Tim Lucia wrote:
 Look in conf/web.xml -- it is commented out by default.
Not it isn't. The default servlet is enabled by default.

 It is widely
 considered evil to use the default servlet.  At a minimum, it poses
security
 risks.
Again, no. The default servlet is not considered evil. You are thinking
of the invoker servlet.

Mark

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



_
Get an advanced look at the new version of MSN Messenger. 
http://messenger.msn.com.my/Beta/Default.aspx



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



error during tomcat startup when starting springframework

2006-05-09 Thread lee hwaying

can some one help please



@4000445f116006a73194
org.springframework.beans.factory.BeanCreationException: Error creating bean
with name 'sessionFactory' defined in ServletContext resource [/WEB-
INF/applicationContext-hibernate.xml]: Initialization of bean failed; nested
exception is java.lang.NoClassDefFoundError: null
@4000445f116006a74134 java.lang.NoClassDefFoundError
@4000445f116006a7451c at
net.sf.cglib.core.KeyFactory$Generator.generateClass(KeyFactory.java:167)
@4000445f116006a7d5a4 at
net.sf.cglib.core.DefaultGeneratorStrategy.generate
(DefaultGeneratorStrategy.java:25)
@4000445f116006a7dd74 at
net.sf.cglib.core.AbstractClassGenerator.create
(AbstractClassGenerator.java:215)
@4000445f116006a7e544 at
net.sf.cglib.core.KeyFactory$Generator.create(KeyFactory.java:145)
@4000445f116006a7ed14 at net.sf.cglib.core.KeyFactory.create
(KeyFactory.java:117)
@4000445f116006a80c54 at net.sf.cglib.core.KeyFactory.create
(KeyFactory.java:108)
@4000445f116006a8103c at net.sf.cglib.core.KeyFactory.create
(KeyFactory.java:104)
@4000445f116006a8180c at
org.hibernate.impl.SessionFactoryImpl.clinit(SessionFactoryImpl.java:321)
@4000445f116006a81fdc at
org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1005)
@4000445f116006a852a4 at
org.springframework.orm.hibernate3.LocalSessionFactoryBean.newSessionFactory
(LocalSessionFactoryBean.java:777)
@4000445f116006a85a74 at
org.springframework.orm.hibernate3.LocalSessionFactoryBean.afterPropertiesSet
(LocalSessionFactoryBean.java:703)
@4000445f116006a8662c at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.in
vokeInitMethods(AbstractAutowireCapableBeanFactory.java:1058)
@4000445f116006a8856c at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.cr
eateBean(AbstractAutowireCapableBeanFactory.java:363)
@4000445f116006a89124 at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean
(AbstractBeanFactory.java:226)
@4000445f116006a898f4 at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean
(AbstractBeanFactory.java:147)
@4000445f116006a8b44c at
org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstant
iateSingletons(DefaultListableBeanFactory.java:269)
@4000445f116006a8c004 at
org.springframework.context.support.AbstractApplicationContext.refresh
(AbstractApplicationContext.java:318)
@4000445f116006a8c7d4 at
org.springframework.web.context.support.AbstractRefreshableWebApplicationContex

_
Find just what you are after with the more precise, more powerful new MSN 
Search. http://search.msn.com.my/ Try it now.



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



Re: System.setProperty failed during Tomcat5 startup

2006-05-09 Thread lee hwaying


sorry for that.

THanks for the reply

is there any way round it without having to touch the security manager as I 
am running it from a web hosting package


many thanks


From: Tim Funk [EMAIL PROTECTED]
Reply-To: Tomcat Users List users@tomcat.apache.org
To: Tomcat Users List users@tomcat.apache.org
Subject: Re: System.setProperty failed during Tomcat5 startup
Date: Tue, 09 May 2006 09:02:07 -0400

1) Don't hijack threads - start a new one
2) Your running tomcat in with the security manager turned on. When the 
security manager is enabled - methods System.setProperty() and 
System.exit() are not allowed to be called.


-Tim

lee hwaying wrote:

Tomcat startup fail with below error log when Springframework tried to 
call System.setProperty.

Can some one help me?
I ran the code succesyfully at windows pc but not on unix server

thanks
hy

java.security.AccessControlException: access denied
(java.util.PropertyPermission webApp.root write)
@4000445f114f374f04fc at
java.security.AccessControlContext.checkPermission
java.security.AccessController.checkPermission(AccessController.java:427)
@4000445f114f374f149c at java.lang.SecurityManager.checkPermission
(SecurityManager.java:532)
@4000445f114f374fa524 at java.lang.System.setProperty
(System.java:698)
@4000445f114f374facf4 at
org.springframework.web.util.WebUtils.setWebAppRootSystemProperty
(WebUtils.java:104)
@4000445f114f374fb4c4 at
org.springframework.web.util.Log4jWebConfigurer.initLogging



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



_
Find love online with MSN Personals. 
http://match.msn.com.my/match/mt.cfm?pg=channel



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



error listener start during aplication start up

2006-04-21 Thread lee hwaying
I have the following error message while starting up my application in 
Tomcat.

I am using log4j.xml in my custom application. can someone help

thanks.


INFO: XML validation disabled
log4j:WARN No appenders could be found for logger 
(org.apache.catalina.startup.TldConfig).

log4j:WARN Please initialize the log4j system properly.

_
Find just what you are after with the more precise, more powerful new MSN 
Search. http://search.msn.com.my/ Try it now.



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



SEVERE: Error listenerStart

2006-03-07 Thread lee hwaying

Hi all

I have a program that encounter the below error.
Please Help!


4000440e149115067fec Mar 7, 2006 11:17:27 PM 
org.apache.catalina.core.ApplicationContext log
@4000440e149115068ba4 INFO: HTMLManager: start: Starting web application 
at '/gallery'

@4000440e14921db1dc2c [GC 86464K-78457K(139396K), 0.0099230 secs]
@4000440e1495015ab7c4 Mar 7, 2006 11:17:31 PM 
org.apache.catalina.core.StandardContext start

@4000440e1495015ac37c SEVERE: Error listenerStart
@4000440e149509281bcc Mar 7, 2006 11:17:31 PM 
org.apache.catalina.core.StandardContext start
@4000440e149509282784 SEVERE: Context [/gallery] startup failed due to 
previous errors
@4000440e14950d093244 Mar 7, 2006 11:17:31 PM 
org.apache.catalina.core.ApplicationContext log

@

_
Block pop-up ads with MSN Toolbar. http://toolbar.msn.com.my/


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



RE: SEVERE: Error listenerStart

2006-03-07 Thread lee hwaying

To add to it,
this piece of program runs well in my local tomcat 5.5.12 but fail to run 
with the following error when i upload to server.


regards




From: lee hwaying [EMAIL PROTECTED]
Reply-To: Tomcat Users List users@tomcat.apache.org
To: users@tomcat.apache.org
Subject: SEVERE: Error listenerStart
Date: Wed, 08 Mar 2006 07:38:17 +0800

Hi all

I have a program that encounter the below error.
Please Help!


4000440e149115067fec Mar 7, 2006 11:17:27 PM 
org.apache.catalina.core.ApplicationContext log
@4000440e149115068ba4 INFO: HTMLManager: start: Starting web 
application at '/gallery'

@4000440e14921db1dc2c [GC 86464K-78457K(139396K), 0.0099230 secs]
@4000440e1495015ab7c4 Mar 7, 2006 11:17:31 PM 
org.apache.catalina.core.StandardContext start

@4000440e1495015ac37c SEVERE: Error listenerStart
@4000440e149509281bcc Mar 7, 2006 11:17:31 PM 
org.apache.catalina.core.StandardContext start
@4000440e149509282784 SEVERE: Context [/gallery] startup failed due to 
previous errors
@4000440e14950d093244 Mar 7, 2006 11:17:31 PM 
org.apache.catalina.core.ApplicationContext log

@

_
Block pop-up ads with MSN Toolbar. http://toolbar.msn.com.my/


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



_
Block pop-up ads with MSN Toolbar. http://toolbar.msn.com.my/


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



RE: JNDI Datasource Problem

2006-03-03 Thread lee hwaying


many thanks, it works beautifully now.


what i did

1. META-INF/context.xml

?xml version=1.0 encoding=UTF-8?
Context debug=0 displayName=gallery docBase=gallery path=/gallery 
reloadable=true
 Logger className=org.apache.catalina.logger.FileLogger 
prefix=Gallery. suffix=.log timestamp=true/

 !-- Define a database connection pool for MYSQL --
 Resource auth=Container name=jdbc/galleryDB 
type=javax.sql.DataSource

driverClassName=org.gjt.mm.mysql.Driver
url=jdbc:mysql://localhost/jidienadmin?autoReconnect=true
username=ada
password=erer
maxActive=50
maxIdle=10
maxWait=1
removeAbandoned=true
removeAbandonedTimeout=60
logAbandoned=true/

/Context

2. in WEB-INF/web.xml

web-app
   ...
resource-ref
res-ref-namejdbc/galleryDB/res-ref-name
res-typejavax.sql.DataSource/res-type
res-authContainer/res-auth
res-sharing-scopeShareable/res-sharing-scope
/resource-ref
...
/web-app


3 remove the portion from server.xml (as we don't need it,application 
specific context.xml works)


4 remove the resourcelink from ..\conf\Catalina\localhost\...xml


From: Wang, Hansen [EMAIL PROTECTED]
Reply-To: Tomcat Users List users@tomcat.apache.org
To: Tomcat Users List users@tomcat.apache.org
Subject: RE:  JNDI Datasource Problem
Date: Mon, 27 Feb 2006 11:00:40 -0700

Two problems:

1. In ResourceLink, the value for attribute golbal should be
jdbc/galleryDB instead of galleryDB.

2. The factory classname is wrong if you are using tomcat5's
naming-factory-dbcp.jar. You can just remove that line and the default
is used.


-Original Message-
From: lee hwaying [mailto:[EMAIL PROTECTED]
Sent: Friday, February 24, 2006 3:22 PM
To: users@tomcat.apache.org
Subject: JNDI Datasource Problem

ERROR JDBCExceptionReporter - Cannot create JDBC driver of class '' for
connect URL 'null'

I still get the above error in Tomcat 5.5.15 after doing the below.
Please help

web.xml :
...

resource-ref

res-ref-namejdbc/galleryDB/res-ref-name
res-typejavax.sql.DataSource/res-type
res-authContainer/res-auth
res-sharing-scopeShareable/res-sharing-scope


/resource-ref
...


C:\apache-tomcat-5.5.15\conf\server.xml :
...
!-- Global JNDI resources --
  GlobalNamingResources

!-- Test entry for demonstration purposes --


Environment name=simpleValue type=java.lang.Integer
value=30/

!-- Editable user database that can also be used by
 UserDatabaseRealm to authenticate users --


Resource name=UserDatabase auth=Container
  type=org.apache.catalina.UserDatabase
   description=User database that can be updated and saved


   factory=org.apache.catalina.users.MemoryUserDatabaseFactory
  pathname=conf/tomcat-users.xml /


Resource auth=Container name=jdbc/galleryDB type=

javax.sql.DataSource
factory=org.apache.commons.dbcp.BasicDataSourceFactory
driverClassName=org.gjt.mm.mysql.Driver
url=jdbc:mysql://localhost/Gallery?autoReconnect=true


username=GalleryUser
password=hwaying
maxActive=50
maxIdle=10
maxWait=1
removeAbandoned=true
removeAbandonedTimeout=60


logAbandoned=true/

  /GlobalNamingResources
...

C:\apache-tomcat-5.5.15\conf\Catalina\localhost\root.xml
Context debug=0 displayName=gallery path=/gallery
docbase=C:\apache-

tomcat-5.5.15\webapps\gallery  reloadable=true

  !-- Link to the user database we will get roles from --
  ResourceLink name=jdbc/galleryDB global=galleryDB


type=javax.sql.DataSource/ /Context

Please help

many thansk

_
Find love online with MSN Personals.
http://match.msn.com.my/match/mt.cfm?pg=channel


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



_
Find love online with MSN Personals. 
http://match.msn.com.my/match/mt.cfm?pg=channel



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



Re: JNDI Datasource Problem

2006-02-25 Thread lee hwaying


may i know how to use connetor/J?


From: umesh balasubramaniam [EMAIL PROTECTED]
Reply-To: Tomcat Users List users@tomcat.apache.org
To: Tomcat Users List users@tomcat.apache.org
Subject: Re: JNDI Datasource Problem
Date: Fri, 24 Feb 2006 21:55:15 -0800

Try using connector/J and the configuration below:
  Resource name=jdbc/galleryDB auth=Container type=
javax.sql.DataSource/

ResourceParams name=jdbc/galleryDB
parameter
namefactory/name
valueorg.apache.commons.dbcp.BasicDataSourceFactory
/value
/parameter
parameter
namedriverClassName/name
valuecom.mysql.jdbc.Driver/value
/parameter
parameter
nameurl/name

valuejdbc:mysql://localhost/Gallery?autoReconnect=true/value
/parameter
parameter
nameusername/name
valueGalleryUser/value
/parameter
parameter
namepassword/name
valuehwaying/value
/parameter
parameter
namemaxActive/name
value20/value
/parameter
parameter
namemaxIdle/name
value10/value
/parameter
parameter
namemaxWait/name
value-1/value
/parameter
/ResourceParams
/Context


On 2/24/06, lee hwaying [EMAIL PROTECTED] wrote:

 ERROR JDBCExceptionReporter - Cannot create JDBC driver of class '' for
 connect URL 'null'

 I still get the above error in Tomcat 5.5.15 after doing the below. 
Please

 help

 web.xml :
 ...

 resource-ref

 res-ref-namejdbc/galleryDB/res-ref-name
 res-typejavax.sql.DataSource/res-type
 res-authContainer/res-auth
 res-sharing-scopeShareable/res-sharing-scope


 /resource-ref
 ...


 C:\apache-tomcat-5.5.15\conf\server.xml :
 ...
 !-- Global JNDI resources --
   GlobalNamingResources

 !-- Test entry for demonstration purposes --


 Environment name=simpleValue type=java.lang.Integer 
value=30/


 !-- Editable user database that can also be used by
  UserDatabaseRealm to authenticate users --


 Resource name=UserDatabase auth=Container
   type=org.apache.catalina.UserDatabase
description=User database that can be updated and saved


factory=org.apache.catalina.users.MemoryUserDatabaseFactory
   pathname=conf/tomcat-users.xml /


 Resource auth=Container name=jdbc/galleryDB type=

 javax.sql.DataSource
 factory=org.apache.commons.dbcp.BasicDataSourceFactory
 driverClassName=org.gjt.mm.mysql.Driver
 url=jdbc:mysql://localhost/Gallery?autoReconnect=true


 username=GalleryUser
 password=hwaying
 maxActive=50
 maxIdle=10
 maxWait=1
 removeAbandoned=true
 removeAbandonedTimeout=60


 logAbandoned=true/

   /GlobalNamingResources
 ...

 C:\apache-tomcat-5.5.15\conf\Catalina\localhost\root.xml
 Context debug=0 displayName=gallery path=/gallery
 docbase=C:\apache-

 tomcat-5.5.15\webapps\gallery  reloadable=true

   !-- Link to the user database we will get roles from --
   ResourceLink name=jdbc/galleryDB global=galleryDB


 type=javax.sql.DataSource/
 /Context

 Please help

 many thansk

 _
 Find love online with MSN Personals.
 http://match.msn.com.my/match/mt.cfm?pg=channel


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




_
Find love online with MSN Personals. 
http://match.msn.com.my/match/mt.cfm?pg=channel



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



JNDI Datasource Problem

2006-02-24 Thread lee hwaying
ERROR JDBCExceptionReporter - Cannot create JDBC driver of class '' for 
connect URL 'null'


I still get the above error in Tomcat 5.5.15 after doing the below. Please 
help


web.xml :
...

   resource-ref

res-ref-namejdbc/galleryDB/res-ref-name
res-typejavax.sql.DataSource/res-type
res-authContainer/res-auth
res-sharing-scopeShareable/res-sharing-scope


/resource-ref
...


C:\apache-tomcat-5.5.15\conf\server.xml :
...
!-- Global JNDI resources --
 GlobalNamingResources

   !-- Test entry for demonstration purposes --


   Environment name=simpleValue type=java.lang.Integer value=30/

   !-- Editable user database that can also be used by
UserDatabaseRealm to authenticate users --


   Resource name=UserDatabase auth=Container
 type=org.apache.catalina.UserDatabase
  description=User database that can be updated and saved


  factory=org.apache.catalina.users.MemoryUserDatabaseFactory
 pathname=conf/tomcat-users.xml /


Resource auth=Container name=jdbc/galleryDB type=

javax.sql.DataSource
factory=org.apache.commons.dbcp.BasicDataSourceFactory
driverClassName=org.gjt.mm.mysql.Driver
url=jdbc:mysql://localhost/Gallery?autoReconnect=true


username=GalleryUser
password=hwaying
maxActive=50
maxIdle=10
maxWait=1
removeAbandoned=true
removeAbandonedTimeout=60


logAbandoned=true/

 /GlobalNamingResources
...

C:\apache-tomcat-5.5.15\conf\Catalina\localhost\root.xml
Context debug=0 displayName=gallery path=/gallery docbase=C:\apache-

tomcat-5.5.15\webapps\gallery  reloadable=true

 !-- Link to the user database we will get roles from --
 ResourceLink name=jdbc/galleryDB global=galleryDB


   type=javax.sql.DataSource/
/Context

Please help

many thansk

_
Find love online with MSN Personals. 
http://match.msn.com.my/match/mt.cfm?pg=channel



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