You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Alexandr Khlystov <al...@gmail.com> on 2009/03/27 09:55:58 UTC

SEVERE: Null component Catalina:type=DataSource

Guys I've broken my head with this error, google gives nothing.

I tried to follow
http://tomcat.apache.org/tomcat-6.0-doc/jndi-datasource-examples-howto.html.

Tomcat 6.0.
Oracle 9.0.
driver: oracle_jdbc13-9.0.2.0.0.jar is added to "E:\Program Files\Apache
Software Foundation\Tomcat 6.0\lib\"

I see at catalina.2009-03-27.log:

*SEVERE:* Null component
Catalina:type=DataSource,path=/com.km.integration.service.web,host=localhost,class=javax.sql.DataSource,name="jdbc/isDS"


*web.xml*:
<web-app>

    <resource-ref>
        <description>Oracle Datasource example</description>
        <res-ref-name>jdbc/isDS</res-ref-name>
        <res-type>javax.sql.DataSource</res-type>
        <res-auth>Container</res-auth>
    </resource-ref>
....


context.xml is placed to META-INF/context.xml :
<?xml version='1.0' encoding='utf-8'?>
<Context>
    <Resource name="jdbc/isDS" auth="Container"
        type="javax.sql.DataSource"
        driverClassName="oracle.jdbc.OracleDriver"
        url="jdbc:oracle:thin:@172.16.4.4:1523:schema"
        username="test" password="test"/>
</Context>

This connection works I've tested it.

*How can I fix this exception??*
I've even don't try to call the interested JNDI DataSource.

When Tomcat starts it even check the connection, screenshot at
http://ovservice.org/trouble.PNG


-- 
________________________
Best regards,
Alexandr Khlystov

Re: SEVERE: Null component Catalina:type=DataSource

Posted by Alexandr Khlystov <al...@gmail.com>.
I'm not the person added this jar to project, I'll answer this later. As I
understand problem is in duplicated 'tomcat' classes, Maybe I'll try to just
remove them. Anyway I'll report the result here.


On Tue, Mar 31, 2009 at 2:31 PM, Yassine <el...@users.sourceforge.net>wrote:

> hi Alexandr,
>
> listing the arrserv-rt.jar classes shows the following:
>
> http://rafb.net/p/FPcEW459.html
>
> which was a surprise to me ( i did not knew that appserv-rt.jar) is
> bundeling this much
> org.apache.catalina.* classes
>
> in theory this should not matter, since each application's classloader
> is isolated
> but since these(classes inside the jar) are the same classes the
> container it self
> is using i have a doubt here if that will ever work fine.
> Is there any other version of appserv-rt which does not contains these
> classes from
>  catalina?
>
> Yassine
>
>
>
> On Tue, Mar 31, 2009 at 7:29 AM, Alexandr Khlystov
> <al...@gmail.com> wrote:
> > I was wrong, deployment method matters but it is not the root cause, root
> > cause is the Sun Application Server *.jar:
> >
> > appserv-rt.jar; if it is included into mywebapp/WEB-INF/lib directory
> cause
> > the JNDI to fail, I don't why yet. But problem definetely in this *.jar.
> We
> > use it because customer installation will be on Sun App Server, but for
> > deployment I want to use Tomcat.
> >
> > Our security logic is made on Acegi, which uses WebPrincipal from
> > appserv-rt.jar.
> >
> > So I don't know how to resolve it now.
> >
> > 2009/3/30 Alexandr Khlystov <al...@gmail.com>
> >
> >> Hi, Yassine.
> >>
> >> As you can see at http://ovservice.org/tomcatConf.PNG - There are no
> any
> >> folders in /conf/ directory.
> >>
> >>
> >> I've followed your instructions, and this error doesn't appear.
> >>
> >> The difference was in the way of deploying, before the *.war deployment,
> I
> >> just copied the /war/ content via file manager to the Tomcat/webapps
> >> directory. Strange but there is a difference!
> >>
> >>
> >> Now I can say Yassine - thanks a lot!
> >>
> >>
> >>
> >> On Mon, Mar 30, 2009 at 4:25 PM, Yassine <elassad@users.sourceforge.net
> >wrote:
> >>
> >>> Hi Alexandr,
> >>>
> >>> this may not solve your problem but could help to identify it, please
> >>> do the following:
> >>>
> >>> - shutdown tomcat
> >>> - remove any previously created "youApplicationName".xml file in the
> >>> $CATALINA_HOME/conf/Catalina/localhost/"youApplicationName".xml
> >>> it seems to me that when tomcat starts it does find an old instance
> >>> there see the log:
> >>> (
> >>> > INFO: The listener
> >>> "org.springframework.web.context.ContextLoaderListener"
> >>> > is already configured for this context. The duplicate definition has
> >>> been
> >>> > ignored.
> >>> )
> >>> and in addition to that, tomcat does not logs the information that it
> >>> starts deploying "yourApplicationName".xml
> >>>
> >>> - remove the $CATALINA_HOME/work/localhost/yourApplicationName
> directory.
> >>> - package  /war your application
> >>> - start tomcat and let it cleanly starts until it says that the start
> >>> up is success full
> >>> - deploy your "yourApplicationName".war into the webapps directory
> >>> - send the logs again
> >>>
> >>> good luck!
> >>>
> >>>
> >>>
> >>>
> >>>
> >>>
> >>> On Mon, Mar 30, 2009 at 6:22 AM, Alexandr Khlystov
> >>> <al...@gmail.com> wrote:
> >>> > *META-INF/context.xml*:
> >>> >
> >>> > <?xml version='1.0' encoding='utf-8'?>
> >>> > <Context>
> >>> >    <WatchedResource>WEB-INF/web.xml</WatchedResource>
> >>> >
> >>> >    <Resource name="jdbc/isDS" auth="Container"
> >>> >        type="javax.sql.DataSource"
> >>> >        driverClassName="oracle.jdbc.OracleDriver"
> >>> >        url="jdbc:oracle:thin:@172.16.4.4:1523:kiptest"
> >>> >        username="test" password="test"
> >>> >        maxActive="20" maxIdle="10" maxWait="-1" />
> >>> >
> >>> >    <Resource name="jdbc/TestDB" auth="Container"
> >>> >        type="javax.sql.DataSource" maxActive="100" maxIdle="30"
> >>> >        maxWait="10000" username="root" password="root"
> >>> >        driverClassName="com.mysql.jdbc.Driver"
> >>> >        url="jdbc:mysql://localhost:3306/mysql?autoReconnect=true" />
> >>> >
> >>> > </Context>
> >>> >
> >>> > *WEB-INF/web.xml, modified a bit to hide private data:*
> >>> >
> >>> > <?xml version="1.0" encoding="UTF-8"?>
> >>> > <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web
> Application
> >>> > 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
> >>> >
> >>> > <web-app id="WebAppUM">
> >>> >
> >>> >    <resource-ref>
> >>> >        <description>Oracle Datasource example</description>
> >>> >        <res-ref-name>jdbc/isDS</res-ref-name>
> >>> >        <res-type>javax.sql.DataSource</res-type>
> >>> >        <res-auth>Container</res-auth>
> >>> >    </resource-ref>
> >>> >
> >>> >  <resource-ref>
> >>> >      <description>DB Connection</description>
> >>> >      <res-ref-name>jdbc/TestDB</res-ref-name>
> >>> >      <res-type>javax.sql.DataSource</res-type>
> >>> >      <res-auth>Container</res-auth>
> >>> >  </resource-ref>
> >>> >
> >>> >    <context-param >
> >>> >        <param-name>contextConfigLocation</param-name>
> >>> >        <param-value>
> >>> >            /WEB-INF/applicationContext-security.xml
> >>> >            /WEB-INF/schedulers-context.xml
> >>> >        </param-value>
> >>> >    </context-param>
> >>> >
> >>> >    <context-param >
> >>> >        <param-name>log4jConfigLocation</param-name>
> >>> >        <param-value>/WEB-INF/classes/log4j.properties</param-value>
> >>> >    </context-param>
> >>> >
> >>> >    <filter >
> >>> >        <filter-name>springSecurityFilterChain</filter-name>
> >>> >
> >>> >
> >>>
> <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
> >>> >    </filter>
> >>> >
> >>> >    <filter-mapping >
> >>> >        <filter-name>springSecurityFilterChain</filter-name>
> >>> >        <url-pattern>/*</url-pattern>
> >>> >    </filter-mapping>
> >>> >
> >>> >    <listener >
> >>> >
> >>> >
> >>>
> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
> >>> >    </listener>
> >>> >
> >>> >    <listener >
> >>> >
> >>> >
> >>>
> <listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
> >>> >    </listener>
> >>> >
> >>> >    <listener >
> >>> >
> >>> >
> >>>
> <listener-class>org.springframework.security.ui.session.HttpSessionEventPublisher</listener-class>
> >>> >    </listener>
> >>> >
> >>> >    <servlet id="com.company.application" >
> >>> >        <servlet-name>com.company.application</servlet-name>
> >>> >
> >>> >
> >>>
> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
> >>> >        <load-on-startup>1</load-on-startup>
> >>> >    </servlet>
> >>> >
> >>> >    <servlet-mapping >
> >>> >        <servlet-name>com.company.application</servlet-name>
> >>> >        <url-pattern>*.form</url-pattern>
> >>> >    </servlet-mapping>
> >>> >
> >>> > </web-app>
> >>> >
> >>> >
> >>> > *catalina.2009-03-30.log:*
> >>> > Mar 30, 2009 11:09:11 AM
> org.apache.catalina.core.AprLifecycleListener
> >>> init
> >>> > INFO: The APR based Apache Tomcat Native library which allows optimal
> >>> > performance in production environments was not found on the
> >>> > java.library.path: E:\Program Files\Apache Software Foundation\Tomcat
> >>> >
> >>>
> 6.0\bin;.;E:\WINDOWS\Sun\Java\bin;E:\WINDOWS\system32;E:\WINDOWS;E:\Program
> >>> > Files\Windows Resource Kits\Tools\;E:\Program
> >>> >
> >>>
> Files\PHP\;F:\home3\bin;F:\OraHome_1\bin;E:\WINDOWS\system32;E:\WINDOWS;E:\WINDOWS\System32\Wbem;E:\Program
> >>> > Files\Intel\DMIX;E:\Program Files\Diskeeper
> >>> > Corporation\Diskeeper\;E:\Program Files\7-Zip;E:\Program
> Files\WinRAR;
> >>> > Mar 30, 2009 11:09:11 AM org.apache.coyote.http11.Http11Protocol init
> >>> > INFO: Initializing Coyote HTTP/1.1 on http-9080
> >>> > Mar 30, 2009 11:09:11 AM org.apache.catalina.startup.Catalina load
> >>> > INFO: Initialization processed in 274 ms
> >>> > Mar 30, 2009 11:09:11 AM org.apache.catalina.core.StandardService
> start
> >>> > INFO: Starting service Catalina
> >>> > Mar 30, 2009 11:09:11 AM org.apache.catalina.core.StandardEngine
> start
> >>> > INFO: Starting Servlet Engine: Apache Tomcat/6.0.16
> >>> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
> >>> > addApplicationListener
> >>> > INFO: The listener
> >>> "org.springframework.web.context.ContextLoaderListener"
> >>> > is already configured for this context. The duplicate definition has
> >>> been
> >>> > ignored.
> >>> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
> >>> > addApplicationListener
> >>> > INFO: The listener "org.springframework.web.util.Log4jConfigListener"
> is
> >>> > already configured for this context. The duplicate definition has
> been
> >>> > ignored.
> >>> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
> >>> > addApplicationListener
> >>> > INFO: The listener
> >>> > "org.springframework.security.ui.session.HttpSessionEventPublisher"
> is
> >>> > already configured for this context. The duplicate definition has
> been
> >>> > ignored.
> >>> >
> >>> > Mar 30, 2009 11:09:12 AM org.apache.tomcat.util.modeler.Registry
> >>> > registerComponent
> >>> > SEVERE: Null component
> >>> >
> >>>
> Catalina:type=DataSource,path=/com.company.application,host=localhost,class=javax.sql.DataSource,name="jdbc/isDS"
> >>> >
> >>> > Mar 30, 2009 11:09:12 AM org.apache.tomcat.util.modeler.Registry
> >>> > registerComponent
> >>> > SEVERE: Null component
> >>> >
> >>>
> Catalina:type=DataSource,path=/com.company.application,host=localhost,class=javax.sql.DataSource,name="jdbc/TestDB"
> >>> >
> >>> > Mar 30, 2009 11:09:16 AM org.apache.coyote.http11.Http11Protocol
> start
> >>> > INFO: Starting Coyote HTTP/1.1 on http-9080
> >>> > Mar 30, 2009 11:09:16 AM org.apache.jk.common.ChannelSocket init
> >>> > INFO: JK: ajp13 listening on /0.0.0.0:8009
> >>> > Mar 30, 2009 11:09:16 AM org.apache.jk.server.JkMain start
> >>> > INFO: Jk running ID=0 time=0/32  config=null
> >>> > Mar 30, 2009 11:09:16 AM org.apache.catalina.startup.Catalina start
> >>> > INFO: Server startup in 4910 ms
> >>> > Mar 30, 2009 11:11:11 AM org.apache.coyote.http11.Http11Protocol
> pause
> >>> > INFO: Pausing Coyote HTTP/1.1 on http-9080
> >>> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.StandardService
> stop
> >>> > INFO: Stopping service Catalina
> >>> > Mar 30, 2009 11:11:12 AM org.apache.coyote.http11.Http11Protocol
> destroy
> >>> > INFO: Stopping Coyote HTTP/1.1 on http-9080
> >>> >
> >>> > *localhost.2009-03-30.log *
> >>> >
> >>> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.ApplicationContext
> log
> >>> > INFO: Initializing Spring root WebApplicationContext
> >>> > Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext
> log
> >>> > INFO: Set web app root system property: 'webapp.root' = [E:\Program
> >>> > Files\Apache Software Foundation\Tomcat
> >>> > 6.0\webapps\com.company.application\]
> >>> > Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext
> log
> >>> > INFO: Initializing Log4J from [E:\Program Files\Apache Software
> >>> > Foundation\Tomcat
> >>> > 6.0\webapps\com.company.application\WEB-INF\classes\log4j.properties]
> >>> > Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext
> log
> >>> > INFO: Initializing Spring FrameworkServlet 'com.company.application'
> >>> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext
> log
> >>> > INFO: Destroying Spring FrameworkServlet 'com.company.application'
> >>> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext
> log
> >>> > INFO: Shutting down Log4J
> >>> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext
> log
> >>> > INFO: Closing Spring root WebApplicationContext
> >>> >
> >>> > That is all :).
> >>> >
> >>> > Waiting your solutions.
> >>> >
> >>> >
> >>> >
> >>> > On Fri, Mar 27, 2009 at 6:21 PM, Gregor Schneider <
> >>> rc46fi@googlemail.com>wrote:
> >>> >
> >>> >> 1st: I Agree to Yassine that it would be helpful if you could
> provide
> >>> some
> >>> >> logs.
> >>> >>
> >>> >> 2nd: If I'm not mistaken, you're using the Tomcat5-syntax which has
> >>> >> changed since Tomcat 6.
> >>> >>
> >>> >> Have l look here:
> >>> >> http://tomcat.apache.org/tomcat-6.0-doc/config/realm.html
> >>> >>
> >>> >> I.e., the username-attribute becomes connectionName-attribute etc.
> >>> >>
> >>> >> Please look it up, change your settings and let us know if it works
> >>> now.
> >>> >>
> >>> >> If not, please provide
> >>> >>
> >>> >> - your complete context-definition
> >>> >> - your complete deplyment-descriptor
> >>> >> - the logs
> >>> >>
> >>> >> Rgds
> >>> >>
> >>> >> Gregor
> >>> >> --
> >>> >> just because your paranoid, doesn't mean they're not after you...
> >>> >> gpgp-fp: 79A84FA526807026795E4209D3B3FE028B3170B2
> >>> >> gpgp-key available
> >>> >> @ http://pgpkeys.pca.dfn.de:11371
> >>> >> @ http://pgp.mit.edu:11371/
> >>> >>
> >>> >>
> ---------------------------------------------------------------------
> >>> >> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> >>> >> For additional commands, e-mail: users-help@tomcat.apache.org
> >>> >>
> >>> >>
> >>> >
> >>> >
> >>> > --
> >>> > ________________________
> >>> > Best regards,
> >>> > Alexandr Khlystov
> >>> >
> >>>
> >>>
> >>>
> >>> --
> >>> --
> >>> Yassine Elassad
> >>> Bonn, Germany.
> >>> Fon : +49 228 97629355
> >>> Mobile : +49 157 74519666
> >>>
> >>> PEACE :
> >>> ( P ) Positive ( E ) Energy ( A ) Always ( C ) Correct ( E ) Errors.
> >>>
> >>> ---------------------------------------------------------------------
> >>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> >>> For additional commands, e-mail: users-help@tomcat.apache.org
> >>>
> >>>
> >>
> >>
> >> --
> >> ________________________
> >> Best regards,
> >> Alexandr Khlystov
> >>
> >
> >
> >
> > --
> > ________________________
> > Best regards,
> > Alexandr Khlystov
> >
>
>
>
> --
> --
> Yassine Elassad
> Bonn, Germany.
> Fon : +49 228 97629355
> Mobile : +49 157 74519666
>
> PEACE :
> ( P ) Positive ( E ) Energy ( A ) Always ( C ) Correct ( E ) Errors.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>


-- 
________________________
Best regards,
Alexandr Khlystov

Re: SEVERE: Null component Catalina:type=DataSource

Posted by Yassine <el...@users.sourceforge.net>.
hi Alexandr,

listing the arrserv-rt.jar classes shows the following:

http://rafb.net/p/FPcEW459.html

which was a surprise to me ( i did not knew that appserv-rt.jar) is
bundeling this much
org.apache.catalina.* classes

in theory this should not matter, since each application's classloader
is isolated
but since these(classes inside the jar) are the same classes the
container it self
is using i have a doubt here if that will ever work fine.
Is there any other version of appserv-rt which does not contains these
classes from
 catalina?

Yassine



On Tue, Mar 31, 2009 at 7:29 AM, Alexandr Khlystov
<al...@gmail.com> wrote:
> I was wrong, deployment method matters but it is not the root cause, root
> cause is the Sun Application Server *.jar:
>
> appserv-rt.jar; if it is included into mywebapp/WEB-INF/lib directory cause
> the JNDI to fail, I don't why yet. But problem definetely in this *.jar. We
> use it because customer installation will be on Sun App Server, but for
> deployment I want to use Tomcat.
>
> Our security logic is made on Acegi, which uses WebPrincipal from
> appserv-rt.jar.
>
> So I don't know how to resolve it now.
>
> 2009/3/30 Alexandr Khlystov <al...@gmail.com>
>
>> Hi, Yassine.
>>
>> As you can see at http://ovservice.org/tomcatConf.PNG - There are no any
>> folders in /conf/ directory.
>>
>>
>> I've followed your instructions, and this error doesn't appear.
>>
>> The difference was in the way of deploying, before the *.war deployment, I
>> just copied the /war/ content via file manager to the Tomcat/webapps
>> directory. Strange but there is a difference!
>>
>>
>> Now I can say Yassine - thanks a lot!
>>
>>
>>
>> On Mon, Mar 30, 2009 at 4:25 PM, Yassine <el...@users.sourceforge.net>wrote:
>>
>>> Hi Alexandr,
>>>
>>> this may not solve your problem but could help to identify it, please
>>> do the following:
>>>
>>> - shutdown tomcat
>>> - remove any previously created "youApplicationName".xml file in the
>>> $CATALINA_HOME/conf/Catalina/localhost/"youApplicationName".xml
>>> it seems to me that when tomcat starts it does find an old instance
>>> there see the log:
>>> (
>>> > INFO: The listener
>>> "org.springframework.web.context.ContextLoaderListener"
>>> > is already configured for this context. The duplicate definition has
>>> been
>>> > ignored.
>>> )
>>> and in addition to that, tomcat does not logs the information that it
>>> starts deploying "yourApplicationName".xml
>>>
>>> - remove the $CATALINA_HOME/work/localhost/yourApplicationName directory.
>>> - package  /war your application
>>> - start tomcat and let it cleanly starts until it says that the start
>>> up is success full
>>> - deploy your "yourApplicationName".war into the webapps directory
>>> - send the logs again
>>>
>>> good luck!
>>>
>>>
>>>
>>>
>>>
>>>
>>> On Mon, Mar 30, 2009 at 6:22 AM, Alexandr Khlystov
>>> <al...@gmail.com> wrote:
>>> > *META-INF/context.xml*:
>>> >
>>> > <?xml version='1.0' encoding='utf-8'?>
>>> > <Context>
>>> >    <WatchedResource>WEB-INF/web.xml</WatchedResource>
>>> >
>>> >    <Resource name="jdbc/isDS" auth="Container"
>>> >        type="javax.sql.DataSource"
>>> >        driverClassName="oracle.jdbc.OracleDriver"
>>> >        url="jdbc:oracle:thin:@172.16.4.4:1523:kiptest"
>>> >        username="test" password="test"
>>> >        maxActive="20" maxIdle="10" maxWait="-1" />
>>> >
>>> >    <Resource name="jdbc/TestDB" auth="Container"
>>> >        type="javax.sql.DataSource" maxActive="100" maxIdle="30"
>>> >        maxWait="10000" username="root" password="root"
>>> >        driverClassName="com.mysql.jdbc.Driver"
>>> >        url="jdbc:mysql://localhost:3306/mysql?autoReconnect=true" />
>>> >
>>> > </Context>
>>> >
>>> > *WEB-INF/web.xml, modified a bit to hide private data:*
>>> >
>>> > <?xml version="1.0" encoding="UTF-8"?>
>>> > <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application
>>> > 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
>>> >
>>> > <web-app id="WebAppUM">
>>> >
>>> >    <resource-ref>
>>> >        <description>Oracle Datasource example</description>
>>> >        <res-ref-name>jdbc/isDS</res-ref-name>
>>> >        <res-type>javax.sql.DataSource</res-type>
>>> >        <res-auth>Container</res-auth>
>>> >    </resource-ref>
>>> >
>>> >  <resource-ref>
>>> >      <description>DB Connection</description>
>>> >      <res-ref-name>jdbc/TestDB</res-ref-name>
>>> >      <res-type>javax.sql.DataSource</res-type>
>>> >      <res-auth>Container</res-auth>
>>> >  </resource-ref>
>>> >
>>> >    <context-param >
>>> >        <param-name>contextConfigLocation</param-name>
>>> >        <param-value>
>>> >            /WEB-INF/applicationContext-security.xml
>>> >            /WEB-INF/schedulers-context.xml
>>> >        </param-value>
>>> >    </context-param>
>>> >
>>> >    <context-param >
>>> >        <param-name>log4jConfigLocation</param-name>
>>> >        <param-value>/WEB-INF/classes/log4j.properties</param-value>
>>> >    </context-param>
>>> >
>>> >    <filter >
>>> >        <filter-name>springSecurityFilterChain</filter-name>
>>> >
>>> >
>>> <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
>>> >    </filter>
>>> >
>>> >    <filter-mapping >
>>> >        <filter-name>springSecurityFilterChain</filter-name>
>>> >        <url-pattern>/*</url-pattern>
>>> >    </filter-mapping>
>>> >
>>> >    <listener >
>>> >
>>> >
>>> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
>>> >    </listener>
>>> >
>>> >    <listener >
>>> >
>>> >
>>> <listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
>>> >    </listener>
>>> >
>>> >    <listener >
>>> >
>>> >
>>> <listener-class>org.springframework.security.ui.session.HttpSessionEventPublisher</listener-class>
>>> >    </listener>
>>> >
>>> >    <servlet id="com.company.application" >
>>> >        <servlet-name>com.company.application</servlet-name>
>>> >
>>> >
>>> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
>>> >        <load-on-startup>1</load-on-startup>
>>> >    </servlet>
>>> >
>>> >    <servlet-mapping >
>>> >        <servlet-name>com.company.application</servlet-name>
>>> >        <url-pattern>*.form</url-pattern>
>>> >    </servlet-mapping>
>>> >
>>> > </web-app>
>>> >
>>> >
>>> > *catalina.2009-03-30.log:*
>>> > Mar 30, 2009 11:09:11 AM org.apache.catalina.core.AprLifecycleListener
>>> init
>>> > INFO: The APR based Apache Tomcat Native library which allows optimal
>>> > performance in production environments was not found on the
>>> > java.library.path: E:\Program Files\Apache Software Foundation\Tomcat
>>> >
>>> 6.0\bin;.;E:\WINDOWS\Sun\Java\bin;E:\WINDOWS\system32;E:\WINDOWS;E:\Program
>>> > Files\Windows Resource Kits\Tools\;E:\Program
>>> >
>>> Files\PHP\;F:\home3\bin;F:\OraHome_1\bin;E:\WINDOWS\system32;E:\WINDOWS;E:\WINDOWS\System32\Wbem;E:\Program
>>> > Files\Intel\DMIX;E:\Program Files\Diskeeper
>>> > Corporation\Diskeeper\;E:\Program Files\7-Zip;E:\Program Files\WinRAR;
>>> > Mar 30, 2009 11:09:11 AM org.apache.coyote.http11.Http11Protocol init
>>> > INFO: Initializing Coyote HTTP/1.1 on http-9080
>>> > Mar 30, 2009 11:09:11 AM org.apache.catalina.startup.Catalina load
>>> > INFO: Initialization processed in 274 ms
>>> > Mar 30, 2009 11:09:11 AM org.apache.catalina.core.StandardService start
>>> > INFO: Starting service Catalina
>>> > Mar 30, 2009 11:09:11 AM org.apache.catalina.core.StandardEngine start
>>> > INFO: Starting Servlet Engine: Apache Tomcat/6.0.16
>>> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
>>> > addApplicationListener
>>> > INFO: The listener
>>> "org.springframework.web.context.ContextLoaderListener"
>>> > is already configured for this context. The duplicate definition has
>>> been
>>> > ignored.
>>> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
>>> > addApplicationListener
>>> > INFO: The listener "org.springframework.web.util.Log4jConfigListener" is
>>> > already configured for this context. The duplicate definition has been
>>> > ignored.
>>> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
>>> > addApplicationListener
>>> > INFO: The listener
>>> > "org.springframework.security.ui.session.HttpSessionEventPublisher" is
>>> > already configured for this context. The duplicate definition has been
>>> > ignored.
>>> >
>>> > Mar 30, 2009 11:09:12 AM org.apache.tomcat.util.modeler.Registry
>>> > registerComponent
>>> > SEVERE: Null component
>>> >
>>> Catalina:type=DataSource,path=/com.company.application,host=localhost,class=javax.sql.DataSource,name="jdbc/isDS"
>>> >
>>> > Mar 30, 2009 11:09:12 AM org.apache.tomcat.util.modeler.Registry
>>> > registerComponent
>>> > SEVERE: Null component
>>> >
>>> Catalina:type=DataSource,path=/com.company.application,host=localhost,class=javax.sql.DataSource,name="jdbc/TestDB"
>>> >
>>> > Mar 30, 2009 11:09:16 AM org.apache.coyote.http11.Http11Protocol start
>>> > INFO: Starting Coyote HTTP/1.1 on http-9080
>>> > Mar 30, 2009 11:09:16 AM org.apache.jk.common.ChannelSocket init
>>> > INFO: JK: ajp13 listening on /0.0.0.0:8009
>>> > Mar 30, 2009 11:09:16 AM org.apache.jk.server.JkMain start
>>> > INFO: Jk running ID=0 time=0/32  config=null
>>> > Mar 30, 2009 11:09:16 AM org.apache.catalina.startup.Catalina start
>>> > INFO: Server startup in 4910 ms
>>> > Mar 30, 2009 11:11:11 AM org.apache.coyote.http11.Http11Protocol pause
>>> > INFO: Pausing Coyote HTTP/1.1 on http-9080
>>> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.StandardService stop
>>> > INFO: Stopping service Catalina
>>> > Mar 30, 2009 11:11:12 AM org.apache.coyote.http11.Http11Protocol destroy
>>> > INFO: Stopping Coyote HTTP/1.1 on http-9080
>>> >
>>> > *localhost.2009-03-30.log *
>>> >
>>> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.ApplicationContext log
>>> > INFO: Initializing Spring root WebApplicationContext
>>> > Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
>>> > INFO: Set web app root system property: 'webapp.root' = [E:\Program
>>> > Files\Apache Software Foundation\Tomcat
>>> > 6.0\webapps\com.company.application\]
>>> > Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
>>> > INFO: Initializing Log4J from [E:\Program Files\Apache Software
>>> > Foundation\Tomcat
>>> > 6.0\webapps\com.company.application\WEB-INF\classes\log4j.properties]
>>> > Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
>>> > INFO: Initializing Spring FrameworkServlet 'com.company.application'
>>> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
>>> > INFO: Destroying Spring FrameworkServlet 'com.company.application'
>>> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
>>> > INFO: Shutting down Log4J
>>> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
>>> > INFO: Closing Spring root WebApplicationContext
>>> >
>>> > That is all :).
>>> >
>>> > Waiting your solutions.
>>> >
>>> >
>>> >
>>> > On Fri, Mar 27, 2009 at 6:21 PM, Gregor Schneider <
>>> rc46fi@googlemail.com>wrote:
>>> >
>>> >> 1st: I Agree to Yassine that it would be helpful if you could provide
>>> some
>>> >> logs.
>>> >>
>>> >> 2nd: If I'm not mistaken, you're using the Tomcat5-syntax which has
>>> >> changed since Tomcat 6.
>>> >>
>>> >> Have l look here:
>>> >> http://tomcat.apache.org/tomcat-6.0-doc/config/realm.html
>>> >>
>>> >> I.e., the username-attribute becomes connectionName-attribute etc.
>>> >>
>>> >> Please look it up, change your settings and let us know if it works
>>> now.
>>> >>
>>> >> If not, please provide
>>> >>
>>> >> - your complete context-definition
>>> >> - your complete deplyment-descriptor
>>> >> - the logs
>>> >>
>>> >> Rgds
>>> >>
>>> >> Gregor
>>> >> --
>>> >> just because your paranoid, doesn't mean they're not after you...
>>> >> gpgp-fp: 79A84FA526807026795E4209D3B3FE028B3170B2
>>> >> gpgp-key available
>>> >> @ http://pgpkeys.pca.dfn.de:11371
>>> >> @ http://pgp.mit.edu:11371/
>>> >>
>>> >> ---------------------------------------------------------------------
>>> >> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>>> >> For additional commands, e-mail: users-help@tomcat.apache.org
>>> >>
>>> >>
>>> >
>>> >
>>> > --
>>> > ________________________
>>> > Best regards,
>>> > Alexandr Khlystov
>>> >
>>>
>>>
>>>
>>> --
>>> --
>>> Yassine Elassad
>>> Bonn, Germany.
>>> Fon : +49 228 97629355
>>> Mobile : +49 157 74519666
>>>
>>> PEACE :
>>> ( P ) Positive ( E ) Energy ( A ) Always ( C ) Correct ( E ) Errors.
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>>> For additional commands, e-mail: users-help@tomcat.apache.org
>>>
>>>
>>
>>
>> --
>> ________________________
>> Best regards,
>> Alexandr Khlystov
>>
>
>
>
> --
> ________________________
> Best regards,
> Alexandr Khlystov
>



-- 
--
Yassine Elassad
Bonn, Germany.
Fon : +49 228 97629355
Mobile : +49 157 74519666

PEACE :
( P ) Positive ( E ) Energy ( A ) Always ( C ) Correct ( E ) Errors.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: SEVERE: Null component Catalina:type=DataSource

Posted by Alexandr Khlystov <al...@gmail.com>.
I was wrong, deployment method matters but it is not the root cause, root
cause is the Sun Application Server *.jar:

appserv-rt.jar; if it is included into mywebapp/WEB-INF/lib directory cause
the JNDI to fail, I don't why yet. But problem definetely in this *.jar. We
use it because customer installation will be on Sun App Server, but for
deployment I want to use Tomcat.

Our security logic is made on Acegi, which uses WebPrincipal from
appserv-rt.jar.

So I don't know how to resolve it now.

2009/3/30 Alexandr Khlystov <al...@gmail.com>

> Hi, Yassine.
>
> As you can see at http://ovservice.org/tomcatConf.PNG - There are no any
> folders in /conf/ directory.
>
>
> I've followed your instructions, and this error doesn't appear.
>
> The difference was in the way of deploying, before the *.war deployment, I
> just copied the /war/ content via file manager to the Tomcat/webapps
> directory. Strange but there is a difference!
>
>
> Now I can say Yassine - thanks a lot!
>
>
>
> On Mon, Mar 30, 2009 at 4:25 PM, Yassine <el...@users.sourceforge.net>wrote:
>
>> Hi Alexandr,
>>
>> this may not solve your problem but could help to identify it, please
>> do the following:
>>
>> - shutdown tomcat
>> - remove any previously created "youApplicationName".xml file in the
>> $CATALINA_HOME/conf/Catalina/localhost/"youApplicationName".xml
>> it seems to me that when tomcat starts it does find an old instance
>> there see the log:
>> (
>> > INFO: The listener
>> "org.springframework.web.context.ContextLoaderListener"
>> > is already configured for this context. The duplicate definition has
>> been
>> > ignored.
>> )
>> and in addition to that, tomcat does not logs the information that it
>> starts deploying "yourApplicationName".xml
>>
>> - remove the $CATALINA_HOME/work/localhost/yourApplicationName directory.
>> - package  /war your application
>> - start tomcat and let it cleanly starts until it says that the start
>> up is success full
>> - deploy your "yourApplicationName".war into the webapps directory
>> - send the logs again
>>
>> good luck!
>>
>>
>>
>>
>>
>>
>> On Mon, Mar 30, 2009 at 6:22 AM, Alexandr Khlystov
>> <al...@gmail.com> wrote:
>> > *META-INF/context.xml*:
>> >
>> > <?xml version='1.0' encoding='utf-8'?>
>> > <Context>
>> >    <WatchedResource>WEB-INF/web.xml</WatchedResource>
>> >
>> >    <Resource name="jdbc/isDS" auth="Container"
>> >        type="javax.sql.DataSource"
>> >        driverClassName="oracle.jdbc.OracleDriver"
>> >        url="jdbc:oracle:thin:@172.16.4.4:1523:kiptest"
>> >        username="test" password="test"
>> >        maxActive="20" maxIdle="10" maxWait="-1" />
>> >
>> >    <Resource name="jdbc/TestDB" auth="Container"
>> >        type="javax.sql.DataSource" maxActive="100" maxIdle="30"
>> >        maxWait="10000" username="root" password="root"
>> >        driverClassName="com.mysql.jdbc.Driver"
>> >        url="jdbc:mysql://localhost:3306/mysql?autoReconnect=true" />
>> >
>> > </Context>
>> >
>> > *WEB-INF/web.xml, modified a bit to hide private data:*
>> >
>> > <?xml version="1.0" encoding="UTF-8"?>
>> > <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application
>> > 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
>> >
>> > <web-app id="WebAppUM">
>> >
>> >    <resource-ref>
>> >        <description>Oracle Datasource example</description>
>> >        <res-ref-name>jdbc/isDS</res-ref-name>
>> >        <res-type>javax.sql.DataSource</res-type>
>> >        <res-auth>Container</res-auth>
>> >    </resource-ref>
>> >
>> >  <resource-ref>
>> >      <description>DB Connection</description>
>> >      <res-ref-name>jdbc/TestDB</res-ref-name>
>> >      <res-type>javax.sql.DataSource</res-type>
>> >      <res-auth>Container</res-auth>
>> >  </resource-ref>
>> >
>> >    <context-param >
>> >        <param-name>contextConfigLocation</param-name>
>> >        <param-value>
>> >            /WEB-INF/applicationContext-security.xml
>> >            /WEB-INF/schedulers-context.xml
>> >        </param-value>
>> >    </context-param>
>> >
>> >    <context-param >
>> >        <param-name>log4jConfigLocation</param-name>
>> >        <param-value>/WEB-INF/classes/log4j.properties</param-value>
>> >    </context-param>
>> >
>> >    <filter >
>> >        <filter-name>springSecurityFilterChain</filter-name>
>> >
>> >
>> <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
>> >    </filter>
>> >
>> >    <filter-mapping >
>> >        <filter-name>springSecurityFilterChain</filter-name>
>> >        <url-pattern>/*</url-pattern>
>> >    </filter-mapping>
>> >
>> >    <listener >
>> >
>> >
>> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
>> >    </listener>
>> >
>> >    <listener >
>> >
>> >
>> <listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
>> >    </listener>
>> >
>> >    <listener >
>> >
>> >
>> <listener-class>org.springframework.security.ui.session.HttpSessionEventPublisher</listener-class>
>> >    </listener>
>> >
>> >    <servlet id="com.company.application" >
>> >        <servlet-name>com.company.application</servlet-name>
>> >
>> >
>> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
>> >        <load-on-startup>1</load-on-startup>
>> >    </servlet>
>> >
>> >    <servlet-mapping >
>> >        <servlet-name>com.company.application</servlet-name>
>> >        <url-pattern>*.form</url-pattern>
>> >    </servlet-mapping>
>> >
>> > </web-app>
>> >
>> >
>> > *catalina.2009-03-30.log:*
>> > Mar 30, 2009 11:09:11 AM org.apache.catalina.core.AprLifecycleListener
>> init
>> > INFO: The APR based Apache Tomcat Native library which allows optimal
>> > performance in production environments was not found on the
>> > java.library.path: E:\Program Files\Apache Software Foundation\Tomcat
>> >
>> 6.0\bin;.;E:\WINDOWS\Sun\Java\bin;E:\WINDOWS\system32;E:\WINDOWS;E:\Program
>> > Files\Windows Resource Kits\Tools\;E:\Program
>> >
>> Files\PHP\;F:\home3\bin;F:\OraHome_1\bin;E:\WINDOWS\system32;E:\WINDOWS;E:\WINDOWS\System32\Wbem;E:\Program
>> > Files\Intel\DMIX;E:\Program Files\Diskeeper
>> > Corporation\Diskeeper\;E:\Program Files\7-Zip;E:\Program Files\WinRAR;
>> > Mar 30, 2009 11:09:11 AM org.apache.coyote.http11.Http11Protocol init
>> > INFO: Initializing Coyote HTTP/1.1 on http-9080
>> > Mar 30, 2009 11:09:11 AM org.apache.catalina.startup.Catalina load
>> > INFO: Initialization processed in 274 ms
>> > Mar 30, 2009 11:09:11 AM org.apache.catalina.core.StandardService start
>> > INFO: Starting service Catalina
>> > Mar 30, 2009 11:09:11 AM org.apache.catalina.core.StandardEngine start
>> > INFO: Starting Servlet Engine: Apache Tomcat/6.0.16
>> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
>> > addApplicationListener
>> > INFO: The listener
>> "org.springframework.web.context.ContextLoaderListener"
>> > is already configured for this context. The duplicate definition has
>> been
>> > ignored.
>> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
>> > addApplicationListener
>> > INFO: The listener "org.springframework.web.util.Log4jConfigListener" is
>> > already configured for this context. The duplicate definition has been
>> > ignored.
>> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
>> > addApplicationListener
>> > INFO: The listener
>> > "org.springframework.security.ui.session.HttpSessionEventPublisher" is
>> > already configured for this context. The duplicate definition has been
>> > ignored.
>> >
>> > Mar 30, 2009 11:09:12 AM org.apache.tomcat.util.modeler.Registry
>> > registerComponent
>> > SEVERE: Null component
>> >
>> Catalina:type=DataSource,path=/com.company.application,host=localhost,class=javax.sql.DataSource,name="jdbc/isDS"
>> >
>> > Mar 30, 2009 11:09:12 AM org.apache.tomcat.util.modeler.Registry
>> > registerComponent
>> > SEVERE: Null component
>> >
>> Catalina:type=DataSource,path=/com.company.application,host=localhost,class=javax.sql.DataSource,name="jdbc/TestDB"
>> >
>> > Mar 30, 2009 11:09:16 AM org.apache.coyote.http11.Http11Protocol start
>> > INFO: Starting Coyote HTTP/1.1 on http-9080
>> > Mar 30, 2009 11:09:16 AM org.apache.jk.common.ChannelSocket init
>> > INFO: JK: ajp13 listening on /0.0.0.0:8009
>> > Mar 30, 2009 11:09:16 AM org.apache.jk.server.JkMain start
>> > INFO: Jk running ID=0 time=0/32  config=null
>> > Mar 30, 2009 11:09:16 AM org.apache.catalina.startup.Catalina start
>> > INFO: Server startup in 4910 ms
>> > Mar 30, 2009 11:11:11 AM org.apache.coyote.http11.Http11Protocol pause
>> > INFO: Pausing Coyote HTTP/1.1 on http-9080
>> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.StandardService stop
>> > INFO: Stopping service Catalina
>> > Mar 30, 2009 11:11:12 AM org.apache.coyote.http11.Http11Protocol destroy
>> > INFO: Stopping Coyote HTTP/1.1 on http-9080
>> >
>> > *localhost.2009-03-30.log *
>> >
>> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.ApplicationContext log
>> > INFO: Initializing Spring root WebApplicationContext
>> > Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
>> > INFO: Set web app root system property: 'webapp.root' = [E:\Program
>> > Files\Apache Software Foundation\Tomcat
>> > 6.0\webapps\com.company.application\]
>> > Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
>> > INFO: Initializing Log4J from [E:\Program Files\Apache Software
>> > Foundation\Tomcat
>> > 6.0\webapps\com.company.application\WEB-INF\classes\log4j.properties]
>> > Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
>> > INFO: Initializing Spring FrameworkServlet 'com.company.application'
>> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
>> > INFO: Destroying Spring FrameworkServlet 'com.company.application'
>> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
>> > INFO: Shutting down Log4J
>> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
>> > INFO: Closing Spring root WebApplicationContext
>> >
>> > That is all :).
>> >
>> > Waiting your solutions.
>> >
>> >
>> >
>> > On Fri, Mar 27, 2009 at 6:21 PM, Gregor Schneider <
>> rc46fi@googlemail.com>wrote:
>> >
>> >> 1st: I Agree to Yassine that it would be helpful if you could provide
>> some
>> >> logs.
>> >>
>> >> 2nd: If I'm not mistaken, you're using the Tomcat5-syntax which has
>> >> changed since Tomcat 6.
>> >>
>> >> Have l look here:
>> >> http://tomcat.apache.org/tomcat-6.0-doc/config/realm.html
>> >>
>> >> I.e., the username-attribute becomes connectionName-attribute etc.
>> >>
>> >> Please look it up, change your settings and let us know if it works
>> now.
>> >>
>> >> If not, please provide
>> >>
>> >> - your complete context-definition
>> >> - your complete deplyment-descriptor
>> >> - the logs
>> >>
>> >> Rgds
>> >>
>> >> Gregor
>> >> --
>> >> just because your paranoid, doesn't mean they're not after you...
>> >> gpgp-fp: 79A84FA526807026795E4209D3B3FE028B3170B2
>> >> gpgp-key available
>> >> @ http://pgpkeys.pca.dfn.de:11371
>> >> @ http://pgp.mit.edu:11371/
>> >>
>> >> ---------------------------------------------------------------------
>> >> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> >> For additional commands, e-mail: users-help@tomcat.apache.org
>> >>
>> >>
>> >
>> >
>> > --
>> > ________________________
>> > Best regards,
>> > Alexandr Khlystov
>> >
>>
>>
>>
>> --
>> --
>> Yassine Elassad
>> Bonn, Germany.
>> Fon : +49 228 97629355
>> Mobile : +49 157 74519666
>>
>> PEACE :
>> ( P ) Positive ( E ) Energy ( A ) Always ( C ) Correct ( E ) Errors.
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
>
>
> --
> ________________________
> Best regards,
> Alexandr Khlystov
>



-- 
________________________
Best regards,
Alexandr Khlystov

Re: SEVERE: Null component Catalina:type=DataSource

Posted by Alexandr Khlystov <al...@gmail.com>.
Hi, Yassine.

As you can see at http://ovservice.org/tomcatConf.PNG - There are no any
folders in /conf/ directory.


I've followed your instructions, and this error doesn't appear.

The difference was in the way of deploying, before the *.war deployment, I
just copied the /war/ content via file manager to the Tomcat/webapps
directory. Strange but there is a difference!


Now I can say Yassine - thanks a lot!


On Mon, Mar 30, 2009 at 4:25 PM, Yassine <el...@users.sourceforge.net>wrote:

> Hi Alexandr,
>
> this may not solve your problem but could help to identify it, please
> do the following:
>
> - shutdown tomcat
> - remove any previously created "youApplicationName".xml file in the
> $CATALINA_HOME/conf/Catalina/localhost/"youApplicationName".xml
> it seems to me that when tomcat starts it does find an old instance
> there see the log:
> (
> > INFO: The listener
> "org.springframework.web.context.ContextLoaderListener"
> > is already configured for this context. The duplicate definition has been
> > ignored.
> )
> and in addition to that, tomcat does not logs the information that it
> starts deploying "yourApplicationName".xml
>
> - remove the $CATALINA_HOME/work/localhost/yourApplicationName directory.
> - package  /war your application
> - start tomcat and let it cleanly starts until it says that the start
> up is success full
> - deploy your "yourApplicationName".war into the webapps directory
> - send the logs again
>
> good luck!
>
>
>
>
>
>
> On Mon, Mar 30, 2009 at 6:22 AM, Alexandr Khlystov
> <al...@gmail.com> wrote:
> > *META-INF/context.xml*:
> >
> > <?xml version='1.0' encoding='utf-8'?>
> > <Context>
> >    <WatchedResource>WEB-INF/web.xml</WatchedResource>
> >
> >    <Resource name="jdbc/isDS" auth="Container"
> >        type="javax.sql.DataSource"
> >        driverClassName="oracle.jdbc.OracleDriver"
> >        url="jdbc:oracle:thin:@172.16.4.4:1523:kiptest"
> >        username="test" password="test"
> >        maxActive="20" maxIdle="10" maxWait="-1" />
> >
> >    <Resource name="jdbc/TestDB" auth="Container"
> >        type="javax.sql.DataSource" maxActive="100" maxIdle="30"
> >        maxWait="10000" username="root" password="root"
> >        driverClassName="com.mysql.jdbc.Driver"
> >        url="jdbc:mysql://localhost:3306/mysql?autoReconnect=true" />
> >
> > </Context>
> >
> > *WEB-INF/web.xml, modified a bit to hide private data:*
> >
> > <?xml version="1.0" encoding="UTF-8"?>
> > <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application
> > 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
> >
> > <web-app id="WebAppUM">
> >
> >    <resource-ref>
> >        <description>Oracle Datasource example</description>
> >        <res-ref-name>jdbc/isDS</res-ref-name>
> >        <res-type>javax.sql.DataSource</res-type>
> >        <res-auth>Container</res-auth>
> >    </resource-ref>
> >
> >  <resource-ref>
> >      <description>DB Connection</description>
> >      <res-ref-name>jdbc/TestDB</res-ref-name>
> >      <res-type>javax.sql.DataSource</res-type>
> >      <res-auth>Container</res-auth>
> >  </resource-ref>
> >
> >    <context-param >
> >        <param-name>contextConfigLocation</param-name>
> >        <param-value>
> >            /WEB-INF/applicationContext-security.xml
> >            /WEB-INF/schedulers-context.xml
> >        </param-value>
> >    </context-param>
> >
> >    <context-param >
> >        <param-name>log4jConfigLocation</param-name>
> >        <param-value>/WEB-INF/classes/log4j.properties</param-value>
> >    </context-param>
> >
> >    <filter >
> >        <filter-name>springSecurityFilterChain</filter-name>
> >
> >
> <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
> >    </filter>
> >
> >    <filter-mapping >
> >        <filter-name>springSecurityFilterChain</filter-name>
> >        <url-pattern>/*</url-pattern>
> >    </filter-mapping>
> >
> >    <listener >
> >
> >
> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
> >    </listener>
> >
> >    <listener >
> >
> >
> <listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
> >    </listener>
> >
> >    <listener >
> >
> >
> <listener-class>org.springframework.security.ui.session.HttpSessionEventPublisher</listener-class>
> >    </listener>
> >
> >    <servlet id="com.company.application" >
> >        <servlet-name>com.company.application</servlet-name>
> >
> >
> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
> >        <load-on-startup>1</load-on-startup>
> >    </servlet>
> >
> >    <servlet-mapping >
> >        <servlet-name>com.company.application</servlet-name>
> >        <url-pattern>*.form</url-pattern>
> >    </servlet-mapping>
> >
> > </web-app>
> >
> >
> > *catalina.2009-03-30.log:*
> > Mar 30, 2009 11:09:11 AM org.apache.catalina.core.AprLifecycleListener
> init
> > INFO: The APR based Apache Tomcat Native library which allows optimal
> > performance in production environments was not found on the
> > java.library.path: E:\Program Files\Apache Software Foundation\Tomcat
> >
> 6.0\bin;.;E:\WINDOWS\Sun\Java\bin;E:\WINDOWS\system32;E:\WINDOWS;E:\Program
> > Files\Windows Resource Kits\Tools\;E:\Program
> >
> Files\PHP\;F:\home3\bin;F:\OraHome_1\bin;E:\WINDOWS\system32;E:\WINDOWS;E:\WINDOWS\System32\Wbem;E:\Program
> > Files\Intel\DMIX;E:\Program Files\Diskeeper
> > Corporation\Diskeeper\;E:\Program Files\7-Zip;E:\Program Files\WinRAR;
> > Mar 30, 2009 11:09:11 AM org.apache.coyote.http11.Http11Protocol init
> > INFO: Initializing Coyote HTTP/1.1 on http-9080
> > Mar 30, 2009 11:09:11 AM org.apache.catalina.startup.Catalina load
> > INFO: Initialization processed in 274 ms
> > Mar 30, 2009 11:09:11 AM org.apache.catalina.core.StandardService start
> > INFO: Starting service Catalina
> > Mar 30, 2009 11:09:11 AM org.apache.catalina.core.StandardEngine start
> > INFO: Starting Servlet Engine: Apache Tomcat/6.0.16
> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
> > addApplicationListener
> > INFO: The listener
> "org.springframework.web.context.ContextLoaderListener"
> > is already configured for this context. The duplicate definition has been
> > ignored.
> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
> > addApplicationListener
> > INFO: The listener "org.springframework.web.util.Log4jConfigListener" is
> > already configured for this context. The duplicate definition has been
> > ignored.
> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
> > addApplicationListener
> > INFO: The listener
> > "org.springframework.security.ui.session.HttpSessionEventPublisher" is
> > already configured for this context. The duplicate definition has been
> > ignored.
> >
> > Mar 30, 2009 11:09:12 AM org.apache.tomcat.util.modeler.Registry
> > registerComponent
> > SEVERE: Null component
> >
> Catalina:type=DataSource,path=/com.company.application,host=localhost,class=javax.sql.DataSource,name="jdbc/isDS"
> >
> > Mar 30, 2009 11:09:12 AM org.apache.tomcat.util.modeler.Registry
> > registerComponent
> > SEVERE: Null component
> >
> Catalina:type=DataSource,path=/com.company.application,host=localhost,class=javax.sql.DataSource,name="jdbc/TestDB"
> >
> > Mar 30, 2009 11:09:16 AM org.apache.coyote.http11.Http11Protocol start
> > INFO: Starting Coyote HTTP/1.1 on http-9080
> > Mar 30, 2009 11:09:16 AM org.apache.jk.common.ChannelSocket init
> > INFO: JK: ajp13 listening on /0.0.0.0:8009
> > Mar 30, 2009 11:09:16 AM org.apache.jk.server.JkMain start
> > INFO: Jk running ID=0 time=0/32  config=null
> > Mar 30, 2009 11:09:16 AM org.apache.catalina.startup.Catalina start
> > INFO: Server startup in 4910 ms
> > Mar 30, 2009 11:11:11 AM org.apache.coyote.http11.Http11Protocol pause
> > INFO: Pausing Coyote HTTP/1.1 on http-9080
> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.StandardService stop
> > INFO: Stopping service Catalina
> > Mar 30, 2009 11:11:12 AM org.apache.coyote.http11.Http11Protocol destroy
> > INFO: Stopping Coyote HTTP/1.1 on http-9080
> >
> > *localhost.2009-03-30.log *
> >
> > Mar 30, 2009 11:09:12 AM org.apache.catalina.core.ApplicationContext log
> > INFO: Initializing Spring root WebApplicationContext
> > Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
> > INFO: Set web app root system property: 'webapp.root' = [E:\Program
> > Files\Apache Software Foundation\Tomcat
> > 6.0\webapps\com.company.application\]
> > Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
> > INFO: Initializing Log4J from [E:\Program Files\Apache Software
> > Foundation\Tomcat
> > 6.0\webapps\com.company.application\WEB-INF\classes\log4j.properties]
> > Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
> > INFO: Initializing Spring FrameworkServlet 'com.company.application'
> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
> > INFO: Destroying Spring FrameworkServlet 'com.company.application'
> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
> > INFO: Shutting down Log4J
> > Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
> > INFO: Closing Spring root WebApplicationContext
> >
> > That is all :).
> >
> > Waiting your solutions.
> >
> >
> >
> > On Fri, Mar 27, 2009 at 6:21 PM, Gregor Schneider <rc46fi@googlemail.com
> >wrote:
> >
> >> 1st: I Agree to Yassine that it would be helpful if you could provide
> some
> >> logs.
> >>
> >> 2nd: If I'm not mistaken, you're using the Tomcat5-syntax which has
> >> changed since Tomcat 6.
> >>
> >> Have l look here:
> >> http://tomcat.apache.org/tomcat-6.0-doc/config/realm.html
> >>
> >> I.e., the username-attribute becomes connectionName-attribute etc.
> >>
> >> Please look it up, change your settings and let us know if it works now.
> >>
> >> If not, please provide
> >>
> >> - your complete context-definition
> >> - your complete deplyment-descriptor
> >> - the logs
> >>
> >> Rgds
> >>
> >> Gregor
> >> --
> >> just because your paranoid, doesn't mean they're not after you...
> >> gpgp-fp: 79A84FA526807026795E4209D3B3FE028B3170B2
> >> gpgp-key available
> >> @ http://pgpkeys.pca.dfn.de:11371
> >> @ http://pgp.mit.edu:11371/
> >>
> >> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> >> For additional commands, e-mail: users-help@tomcat.apache.org
> >>
> >>
> >
> >
> > --
> > ________________________
> > Best regards,
> > Alexandr Khlystov
> >
>
>
>
> --
> --
> Yassine Elassad
> Bonn, Germany.
> Fon : +49 228 97629355
> Mobile : +49 157 74519666
>
> PEACE :
> ( P ) Positive ( E ) Energy ( A ) Always ( C ) Correct ( E ) Errors.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>


-- 
________________________
Best regards,
Alexandr Khlystov

Re: SEVERE: Null component Catalina:type=DataSource

Posted by Yassine <el...@users.sourceforge.net>.
Hi Alexandr,

this may not solve your problem but could help to identify it, please
do the following:

- shutdown tomcat
- remove any previously created "youApplicationName".xml file in the
$CATALINA_HOME/conf/Catalina/localhost/"youApplicationName".xml
it seems to me that when tomcat starts it does find an old instance
there see the log:
(
> INFO: The listener "org.springframework.web.context.ContextLoaderListener"
> is already configured for this context. The duplicate definition has been
> ignored.
)
and in addition to that, tomcat does not logs the information that it
starts deploying "yourApplicationName".xml

- remove the $CATALINA_HOME/work/localhost/yourApplicationName directory.
- package  /war your application
- start tomcat and let it cleanly starts until it says that the start
up is success full
- deploy your "yourApplicationName".war into the webapps directory
- send the logs again

good luck!






On Mon, Mar 30, 2009 at 6:22 AM, Alexandr Khlystov
<al...@gmail.com> wrote:
> *META-INF/context.xml*:
>
> <?xml version='1.0' encoding='utf-8'?>
> <Context>
>    <WatchedResource>WEB-INF/web.xml</WatchedResource>
>
>    <Resource name="jdbc/isDS" auth="Container"
>        type="javax.sql.DataSource"
>        driverClassName="oracle.jdbc.OracleDriver"
>        url="jdbc:oracle:thin:@172.16.4.4:1523:kiptest"
>        username="test" password="test"
>        maxActive="20" maxIdle="10" maxWait="-1" />
>
>    <Resource name="jdbc/TestDB" auth="Container"
>        type="javax.sql.DataSource" maxActive="100" maxIdle="30"
>        maxWait="10000" username="root" password="root"
>        driverClassName="com.mysql.jdbc.Driver"
>        url="jdbc:mysql://localhost:3306/mysql?autoReconnect=true" />
>
> </Context>
>
> *WEB-INF/web.xml, modified a bit to hide private data:*
>
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application
> 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
>
> <web-app id="WebAppUM">
>
>    <resource-ref>
>        <description>Oracle Datasource example</description>
>        <res-ref-name>jdbc/isDS</res-ref-name>
>        <res-type>javax.sql.DataSource</res-type>
>        <res-auth>Container</res-auth>
>    </resource-ref>
>
>  <resource-ref>
>      <description>DB Connection</description>
>      <res-ref-name>jdbc/TestDB</res-ref-name>
>      <res-type>javax.sql.DataSource</res-type>
>      <res-auth>Container</res-auth>
>  </resource-ref>
>
>    <context-param >
>        <param-name>contextConfigLocation</param-name>
>        <param-value>
>            /WEB-INF/applicationContext-security.xml
>            /WEB-INF/schedulers-context.xml
>        </param-value>
>    </context-param>
>
>    <context-param >
>        <param-name>log4jConfigLocation</param-name>
>        <param-value>/WEB-INF/classes/log4j.properties</param-value>
>    </context-param>
>
>    <filter >
>        <filter-name>springSecurityFilterChain</filter-name>
>
> <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
>    </filter>
>
>    <filter-mapping >
>        <filter-name>springSecurityFilterChain</filter-name>
>        <url-pattern>/*</url-pattern>
>    </filter-mapping>
>
>    <listener >
>
> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
>    </listener>
>
>    <listener >
>
> <listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
>    </listener>
>
>    <listener >
>
> <listener-class>org.springframework.security.ui.session.HttpSessionEventPublisher</listener-class>
>    </listener>
>
>    <servlet id="com.company.application" >
>        <servlet-name>com.company.application</servlet-name>
>
> <servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
>        <load-on-startup>1</load-on-startup>
>    </servlet>
>
>    <servlet-mapping >
>        <servlet-name>com.company.application</servlet-name>
>        <url-pattern>*.form</url-pattern>
>    </servlet-mapping>
>
> </web-app>
>
>
> *catalina.2009-03-30.log:*
> Mar 30, 2009 11:09:11 AM org.apache.catalina.core.AprLifecycleListener init
> INFO: The APR based Apache Tomcat Native library which allows optimal
> performance in production environments was not found on the
> java.library.path: E:\Program Files\Apache Software Foundation\Tomcat
> 6.0\bin;.;E:\WINDOWS\Sun\Java\bin;E:\WINDOWS\system32;E:\WINDOWS;E:\Program
> Files\Windows Resource Kits\Tools\;E:\Program
> Files\PHP\;F:\home3\bin;F:\OraHome_1\bin;E:\WINDOWS\system32;E:\WINDOWS;E:\WINDOWS\System32\Wbem;E:\Program
> Files\Intel\DMIX;E:\Program Files\Diskeeper
> Corporation\Diskeeper\;E:\Program Files\7-Zip;E:\Program Files\WinRAR;
> Mar 30, 2009 11:09:11 AM org.apache.coyote.http11.Http11Protocol init
> INFO: Initializing Coyote HTTP/1.1 on http-9080
> Mar 30, 2009 11:09:11 AM org.apache.catalina.startup.Catalina load
> INFO: Initialization processed in 274 ms
> Mar 30, 2009 11:09:11 AM org.apache.catalina.core.StandardService start
> INFO: Starting service Catalina
> Mar 30, 2009 11:09:11 AM org.apache.catalina.core.StandardEngine start
> INFO: Starting Servlet Engine: Apache Tomcat/6.0.16
> Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
> addApplicationListener
> INFO: The listener "org.springframework.web.context.ContextLoaderListener"
> is already configured for this context. The duplicate definition has been
> ignored.
> Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
> addApplicationListener
> INFO: The listener "org.springframework.web.util.Log4jConfigListener" is
> already configured for this context. The duplicate definition has been
> ignored.
> Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
> addApplicationListener
> INFO: The listener
> "org.springframework.security.ui.session.HttpSessionEventPublisher" is
> already configured for this context. The duplicate definition has been
> ignored.
>
> Mar 30, 2009 11:09:12 AM org.apache.tomcat.util.modeler.Registry
> registerComponent
> SEVERE: Null component
> Catalina:type=DataSource,path=/com.company.application,host=localhost,class=javax.sql.DataSource,name="jdbc/isDS"
>
> Mar 30, 2009 11:09:12 AM org.apache.tomcat.util.modeler.Registry
> registerComponent
> SEVERE: Null component
> Catalina:type=DataSource,path=/com.company.application,host=localhost,class=javax.sql.DataSource,name="jdbc/TestDB"
>
> Mar 30, 2009 11:09:16 AM org.apache.coyote.http11.Http11Protocol start
> INFO: Starting Coyote HTTP/1.1 on http-9080
> Mar 30, 2009 11:09:16 AM org.apache.jk.common.ChannelSocket init
> INFO: JK: ajp13 listening on /0.0.0.0:8009
> Mar 30, 2009 11:09:16 AM org.apache.jk.server.JkMain start
> INFO: Jk running ID=0 time=0/32  config=null
> Mar 30, 2009 11:09:16 AM org.apache.catalina.startup.Catalina start
> INFO: Server startup in 4910 ms
> Mar 30, 2009 11:11:11 AM org.apache.coyote.http11.Http11Protocol pause
> INFO: Pausing Coyote HTTP/1.1 on http-9080
> Mar 30, 2009 11:11:12 AM org.apache.catalina.core.StandardService stop
> INFO: Stopping service Catalina
> Mar 30, 2009 11:11:12 AM org.apache.coyote.http11.Http11Protocol destroy
> INFO: Stopping Coyote HTTP/1.1 on http-9080
>
> *localhost.2009-03-30.log *
>
> Mar 30, 2009 11:09:12 AM org.apache.catalina.core.ApplicationContext log
> INFO: Initializing Spring root WebApplicationContext
> Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
> INFO: Set web app root system property: 'webapp.root' = [E:\Program
> Files\Apache Software Foundation\Tomcat
> 6.0\webapps\com.company.application\]
> Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
> INFO: Initializing Log4J from [E:\Program Files\Apache Software
> Foundation\Tomcat
> 6.0\webapps\com.company.application\WEB-INF\classes\log4j.properties]
> Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
> INFO: Initializing Spring FrameworkServlet 'com.company.application'
> Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
> INFO: Destroying Spring FrameworkServlet 'com.company.application'
> Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
> INFO: Shutting down Log4J
> Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
> INFO: Closing Spring root WebApplicationContext
>
> That is all :).
>
> Waiting your solutions.
>
>
>
> On Fri, Mar 27, 2009 at 6:21 PM, Gregor Schneider <rc...@googlemail.com>wrote:
>
>> 1st: I Agree to Yassine that it would be helpful if you could provide some
>> logs.
>>
>> 2nd: If I'm not mistaken, you're using the Tomcat5-syntax which has
>> changed since Tomcat 6.
>>
>> Have l look here:
>> http://tomcat.apache.org/tomcat-6.0-doc/config/realm.html
>>
>> I.e., the username-attribute becomes connectionName-attribute etc.
>>
>> Please look it up, change your settings and let us know if it works now.
>>
>> If not, please provide
>>
>> - your complete context-definition
>> - your complete deplyment-descriptor
>> - the logs
>>
>> Rgds
>>
>> Gregor
>> --
>> just because your paranoid, doesn't mean they're not after you...
>> gpgp-fp: 79A84FA526807026795E4209D3B3FE028B3170B2
>> gpgp-key available
>> @ http://pgpkeys.pca.dfn.de:11371
>> @ http://pgp.mit.edu:11371/
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
>
>
> --
> ________________________
> Best regards,
> Alexandr Khlystov
>



-- 
--
Yassine Elassad
Bonn, Germany.
Fon : +49 228 97629355
Mobile : +49 157 74519666

PEACE :
( P ) Positive ( E ) Energy ( A ) Always ( C ) Correct ( E ) Errors.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: SEVERE: Null component Catalina:type=DataSource

Posted by Alexandr Khlystov <al...@gmail.com>.
*META-INF/context.xml*:

<?xml version='1.0' encoding='utf-8'?>
<Context>
    <WatchedResource>WEB-INF/web.xml</WatchedResource>

    <Resource name="jdbc/isDS" auth="Container"
        type="javax.sql.DataSource"
        driverClassName="oracle.jdbc.OracleDriver"
        url="jdbc:oracle:thin:@172.16.4.4:1523:kiptest"
        username="test" password="test"
        maxActive="20" maxIdle="10" maxWait="-1" />

    <Resource name="jdbc/TestDB" auth="Container"
        type="javax.sql.DataSource" maxActive="100" maxIdle="30"
        maxWait="10000" username="root" password="root"
        driverClassName="com.mysql.jdbc.Driver"
        url="jdbc:mysql://localhost:3306/mysql?autoReconnect=true" />

</Context>

*WEB-INF/web.xml, modified a bit to hide private data:*

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application
2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">

<web-app id="WebAppUM">

    <resource-ref>
        <description>Oracle Datasource example</description>
        <res-ref-name>jdbc/isDS</res-ref-name>
        <res-type>javax.sql.DataSource</res-type>
        <res-auth>Container</res-auth>
    </resource-ref>

  <resource-ref>
      <description>DB Connection</description>
      <res-ref-name>jdbc/TestDB</res-ref-name>
      <res-type>javax.sql.DataSource</res-type>
      <res-auth>Container</res-auth>
  </resource-ref>

    <context-param >
        <param-name>contextConfigLocation</param-name>
        <param-value>
            /WEB-INF/applicationContext-security.xml
            /WEB-INF/schedulers-context.xml
        </param-value>
    </context-param>

    <context-param >
        <param-name>log4jConfigLocation</param-name>
        <param-value>/WEB-INF/classes/log4j.properties</param-value>
    </context-param>

    <filter >
        <filter-name>springSecurityFilterChain</filter-name>

<filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class>
    </filter>

    <filter-mapping >
        <filter-name>springSecurityFilterChain</filter-name>
        <url-pattern>/*</url-pattern>
    </filter-mapping>

    <listener >

<listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
    </listener>

    <listener >

<listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
    </listener>

    <listener >

<listener-class>org.springframework.security.ui.session.HttpSessionEventPublisher</listener-class>
    </listener>

    <servlet id="com.company.application" >
        <servlet-name>com.company.application</servlet-name>

<servlet-class>org.springframework.web.servlet.DispatcherServlet</servlet-class>
        <load-on-startup>1</load-on-startup>
    </servlet>

    <servlet-mapping >
        <servlet-name>com.company.application</servlet-name>
        <url-pattern>*.form</url-pattern>
    </servlet-mapping>

</web-app>


*catalina.2009-03-30.log:*
Mar 30, 2009 11:09:11 AM org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal
performance in production environments was not found on the
java.library.path: E:\Program Files\Apache Software Foundation\Tomcat
6.0\bin;.;E:\WINDOWS\Sun\Java\bin;E:\WINDOWS\system32;E:\WINDOWS;E:\Program
Files\Windows Resource Kits\Tools\;E:\Program
Files\PHP\;F:\home3\bin;F:\OraHome_1\bin;E:\WINDOWS\system32;E:\WINDOWS;E:\WINDOWS\System32\Wbem;E:\Program
Files\Intel\DMIX;E:\Program Files\Diskeeper
Corporation\Diskeeper\;E:\Program Files\7-Zip;E:\Program Files\WinRAR;
Mar 30, 2009 11:09:11 AM org.apache.coyote.http11.Http11Protocol init
INFO: Initializing Coyote HTTP/1.1 on http-9080
Mar 30, 2009 11:09:11 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 274 ms
Mar 30, 2009 11:09:11 AM org.apache.catalina.core.StandardService start
INFO: Starting service Catalina
Mar 30, 2009 11:09:11 AM org.apache.catalina.core.StandardEngine start
INFO: Starting Servlet Engine: Apache Tomcat/6.0.16
Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
addApplicationListener
INFO: The listener "org.springframework.web.context.ContextLoaderListener"
is already configured for this context. The duplicate definition has been
ignored.
Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
addApplicationListener
INFO: The listener "org.springframework.web.util.Log4jConfigListener" is
already configured for this context. The duplicate definition has been
ignored.
Mar 30, 2009 11:09:12 AM org.apache.catalina.core.StandardContext
addApplicationListener
INFO: The listener
"org.springframework.security.ui.session.HttpSessionEventPublisher" is
already configured for this context. The duplicate definition has been
ignored.

Mar 30, 2009 11:09:12 AM org.apache.tomcat.util.modeler.Registry
registerComponent
SEVERE: Null component
Catalina:type=DataSource,path=/com.company.application,host=localhost,class=javax.sql.DataSource,name="jdbc/isDS"

Mar 30, 2009 11:09:12 AM org.apache.tomcat.util.modeler.Registry
registerComponent
SEVERE: Null component
Catalina:type=DataSource,path=/com.company.application,host=localhost,class=javax.sql.DataSource,name="jdbc/TestDB"

Mar 30, 2009 11:09:16 AM org.apache.coyote.http11.Http11Protocol start
INFO: Starting Coyote HTTP/1.1 on http-9080
Mar 30, 2009 11:09:16 AM org.apache.jk.common.ChannelSocket init
INFO: JK: ajp13 listening on /0.0.0.0:8009
Mar 30, 2009 11:09:16 AM org.apache.jk.server.JkMain start
INFO: Jk running ID=0 time=0/32  config=null
Mar 30, 2009 11:09:16 AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 4910 ms
Mar 30, 2009 11:11:11 AM org.apache.coyote.http11.Http11Protocol pause
INFO: Pausing Coyote HTTP/1.1 on http-9080
Mar 30, 2009 11:11:12 AM org.apache.catalina.core.StandardService stop
INFO: Stopping service Catalina
Mar 30, 2009 11:11:12 AM org.apache.coyote.http11.Http11Protocol destroy
INFO: Stopping Coyote HTTP/1.1 on http-9080

*localhost.2009-03-30.log *

Mar 30, 2009 11:09:12 AM org.apache.catalina.core.ApplicationContext log
INFO: Initializing Spring root WebApplicationContext
Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
INFO: Set web app root system property: 'webapp.root' = [E:\Program
Files\Apache Software Foundation\Tomcat
6.0\webapps\com.company.application\]
Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
INFO: Initializing Log4J from [E:\Program Files\Apache Software
Foundation\Tomcat
6.0\webapps\com.company.application\WEB-INF\classes\log4j.properties]
Mar 30, 2009 11:09:15 AM org.apache.catalina.core.ApplicationContext log
INFO: Initializing Spring FrameworkServlet 'com.company.application'
Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
INFO: Destroying Spring FrameworkServlet 'com.company.application'
Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
INFO: Shutting down Log4J
Mar 30, 2009 11:11:12 AM org.apache.catalina.core.ApplicationContext log
INFO: Closing Spring root WebApplicationContext

That is all :).

Waiting your solutions.



On Fri, Mar 27, 2009 at 6:21 PM, Gregor Schneider <rc...@googlemail.com>wrote:

> 1st: I Agree to Yassine that it would be helpful if you could provide some
> logs.
>
> 2nd: If I'm not mistaken, you're using the Tomcat5-syntax which has
> changed since Tomcat 6.
>
> Have l look here:
> http://tomcat.apache.org/tomcat-6.0-doc/config/realm.html
>
> I.e., the username-attribute becomes connectionName-attribute etc.
>
> Please look it up, change your settings and let us know if it works now.
>
> If not, please provide
>
> - your complete context-definition
> - your complete deplyment-descriptor
> - the logs
>
> Rgds
>
> Gregor
> --
> just because your paranoid, doesn't mean they're not after you...
> gpgp-fp: 79A84FA526807026795E4209D3B3FE028B3170B2
> gpgp-key available
> @ http://pgpkeys.pca.dfn.de:11371
> @ http://pgp.mit.edu:11371/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>


-- 
________________________
Best regards,
Alexandr Khlystov

Re: SEVERE: Null component Catalina:type=DataSource

Posted by Khlystov Alexandr <al...@gmail.com>.
Thanks for reply Gregor, but I'm not using any realm. And sorry but now 
is friday evening and I'll provide more data in the monday only.

Thanks for replies anyway!

Gregor Schneider пишет:
> 1st: I Agree to Yassine that it would be helpful if you could provide some logs.
>
> 2nd: If I'm not mistaken, you're using the Tomcat5-syntax which has
> changed since Tomcat 6.
>
> Have l look here: http://tomcat.apache.org/tomcat-6.0-doc/config/realm.html
>
> I.e., the username-attribute becomes connectionName-attribute etc.
>
> Please look it up, change your settings and let us know if it works now.
>
> If not, please provide
>
> - your complete context-definition
> - your complete deplyment-descriptor
> - the logs
>
> Rgds
>
> Gregor
>   


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: SEVERE: Null component Catalina:type=DataSource

Posted by Gregor Schneider <rc...@googlemail.com>.
Mea culpa, Chuck, you're right...

On Fri, Mar 27, 2009 at 3:21 PM, Caldarale, Charles R
<Ch...@unisys.com> wrote:
>
> A week in Amsterdam, and...  How much have you guys been drinking? :-)
>

erm... actually I wasn't drinking :)

so let's just wait for the logs

Cheers

Gregor
-- 
just because your paranoid, doesn't mean they're not after you...
gpgp-fp: 79A84FA526807026795E4209D3B3FE028B3170B2
gpgp-key available
@ http://pgpkeys.pca.dfn.de:11371
@ http://pgp.mit.edu:11371/

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


[OT] Re: SEVERE: Null component Catalina:type=DataSource

Posted by André Warnier <aw...@ice-sa.com>.
Caldarale, Charles R wrote:
...

> 
> A week in Amsterdam, and...  How much have you guys been drinking? :-)
> 
Actually, not a lot. They seem to be a pretty sober lot.
I'm talking about the participants to the ApacheCON.
The Scottish football supporters who started arriving on Thursday night, 
that's another story..
:-)


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: SEVERE: Null component Catalina:type=DataSource

Posted by "Caldarale, Charles R" <Ch...@unisys.com>.
> From: Gregor Schneider [mailto:rc46fi@googlemail.com]
> Subject: Re: SEVERE: Null component Catalina:type=DataSource
> 
> 2nd: If I'm not mistaken, you're using the Tomcat5-syntax which has
> changed since Tomcat 6.
> 
> Have l look here: http://tomcat.apache.org/tomcat-6.0-
> doc/config/realm.html

A week in Amsterdam, and...  How much have you guys been drinking? :-)

The OP is not declaring a <Realm>, he's declaring a <Resource> for a JDBC connection pool; the syntax presented is correct for Tomcat 6.0.  However, seeing all of server.xml and the logs would certainly be useful.

 - Chuck


THIS COMMUNICATION MAY CONTAIN CONFIDENTIAL AND/OR OTHERWISE PROPRIETARY MATERIAL and is thus for use only by the intended recipient. If you received this in error, please contact the sender and delete the e-mail and its attachments from all computers.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: SEVERE: Null component Catalina:type=DataSource

Posted by Gregor Schneider <rc...@googlemail.com>.
1st: I Agree to Yassine that it would be helpful if you could provide some logs.

2nd: If I'm not mistaken, you're using the Tomcat5-syntax which has
changed since Tomcat 6.

Have l look here: http://tomcat.apache.org/tomcat-6.0-doc/config/realm.html

I.e., the username-attribute becomes connectionName-attribute etc.

Please look it up, change your settings and let us know if it works now.

If not, please provide

- your complete context-definition
- your complete deplyment-descriptor
- the logs

Rgds

Gregor
-- 
just because your paranoid, doesn't mean they're not after you...
gpgp-fp: 79A84FA526807026795E4209D3B3FE028B3170B2
gpgp-key available
@ http://pgpkeys.pca.dfn.de:11371
@ http://pgp.mit.edu:11371/

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: SEVERE: Null component Catalina:type=DataSource

Posted by Yassine <el...@users.sourceforge.net>.
could you provide more from your catalina log files ?


On Fri, Mar 27, 2009 at 11:22 AM, Alexandr Khlystov
<al...@gmail.com> wrote:
> Thanks Yassine, but I've reinstalled Tomcat before sample execution. Than I
> have no any old context.xml conflicts.
>
> I've tested mysql too, the same error.
>
> On Fri, Mar 27, 2009 at 4:17 PM, Yassine <el...@users.sourceforge.net>wrote:
>
>> Hi Alexander,
>>
>> as far i can see, everything seems to be fine, the only thing that i
>> can think of is
>> that you could have an old instance of context.xml in your
>> E:\Program Files\Apache Software Foundation\Tomcat
>> 6.0\conf\Catalina\localhost\yourAppName.xml
>> which contains old configs and since that one exist tomcat does not
>> overwrite it with the one
>> you put into yourAppDir/META-INF/context.xml
>>
>> Yassine
>>
>>
>>
>> On Fri, Mar 27, 2009 at 9:55 AM, Alexandr Khlystov
>> <al...@gmail.com> wrote:
>> > Guys I've broken my head with this error, google gives nothing.
>> >
>> > I tried to follow
>> >
>> http://tomcat.apache.org/tomcat-6.0-doc/jndi-datasource-examples-howto.html
>> .
>> >
>> > Tomcat 6.0.
>> > Oracle 9.0.
>> > driver: oracle_jdbc13-9.0.2.0.0.jar is added to "E:\Program Files\Apache
>> > Software Foundation\Tomcat 6.0\lib\"
>> >
>> > I see at catalina.2009-03-27.log:
>> >
>> > *SEVERE:* Null component
>> >
>> Catalina:type=DataSource,path=/com.km.integration.service.web,host=localhost,class=javax.sql.DataSource,name="jdbc/isDS"
>> >
>> >
>> > *web.xml*:
>> > <web-app>
>> >
>> >    <resource-ref>
>> >        <description>Oracle Datasource example</description>
>> >        <res-ref-name>jdbc/isDS</res-ref-name>
>> >        <res-type>javax.sql.DataSource</res-type>
>> >        <res-auth>Container</res-auth>
>> >    </resource-ref>
>> > ....
>> >
>> >
>> > context.xml is placed to META-INF/context.xml :
>> > <?xml version='1.0' encoding='utf-8'?>
>> > <Context>
>> >    <Resource name="jdbc/isDS" auth="Container"
>> >        type="javax.sql.DataSource"
>> >        driverClassName="oracle.jdbc.OracleDriver"
>> >        url="jdbc:oracle:thin:@172.16.4.4:1523:schema"
>> >        username="test" password="test"/>
>> > </Context>
>> >
>> > This connection works I've tested it.
>> >
>> > *How can I fix this exception??*
>> > I've even don't try to call the interested JNDI DataSource.
>> >
>> > When Tomcat starts it even check the connection, screenshot at
>> > http://ovservice.org/trouble.PNG
>> >
>> >
>> > --
>> > ________________________
>> > Best regards,
>> > Alexandr Khlystov
>> >
>>
>>
>>
>> --
>> --
>> Yassine Elassad
>> Bonn, Germany.
>> Fon : +49 228 97629355
>> Mobile : +49 157 74519666
>>
>> PEACE :
>> ( P ) Positive ( E ) Energy ( A ) Always ( C ) Correct ( E ) Errors.
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>> For additional commands, e-mail: users-help@tomcat.apache.org
>>
>>
>
>
> --
> ________________________
> Best regards,
> Alexandr Khlystov
>



-- 
--
Yassine Elassad
Bonn, Germany.
Fon : +49 228 97629355
Mobile : +49 157 74519666

PEACE :
( P ) Positive ( E ) Energy ( A ) Always ( C ) Correct ( E ) Errors.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: SEVERE: Null component Catalina:type=DataSource

Posted by Alexandr Khlystov <al...@gmail.com>.
Thanks Yassine, but I've reinstalled Tomcat before sample execution. Than I
have no any old context.xml conflicts.

I've tested mysql too, the same error.

On Fri, Mar 27, 2009 at 4:17 PM, Yassine <el...@users.sourceforge.net>wrote:

> Hi Alexander,
>
> as far i can see, everything seems to be fine, the only thing that i
> can think of is
> that you could have an old instance of context.xml in your
> E:\Program Files\Apache Software Foundation\Tomcat
> 6.0\conf\Catalina\localhost\yourAppName.xml
> which contains old configs and since that one exist tomcat does not
> overwrite it with the one
> you put into yourAppDir/META-INF/context.xml
>
> Yassine
>
>
>
> On Fri, Mar 27, 2009 at 9:55 AM, Alexandr Khlystov
> <al...@gmail.com> wrote:
> > Guys I've broken my head with this error, google gives nothing.
> >
> > I tried to follow
> >
> http://tomcat.apache.org/tomcat-6.0-doc/jndi-datasource-examples-howto.html
> .
> >
> > Tomcat 6.0.
> > Oracle 9.0.
> > driver: oracle_jdbc13-9.0.2.0.0.jar is added to "E:\Program Files\Apache
> > Software Foundation\Tomcat 6.0\lib\"
> >
> > I see at catalina.2009-03-27.log:
> >
> > *SEVERE:* Null component
> >
> Catalina:type=DataSource,path=/com.km.integration.service.web,host=localhost,class=javax.sql.DataSource,name="jdbc/isDS"
> >
> >
> > *web.xml*:
> > <web-app>
> >
> >    <resource-ref>
> >        <description>Oracle Datasource example</description>
> >        <res-ref-name>jdbc/isDS</res-ref-name>
> >        <res-type>javax.sql.DataSource</res-type>
> >        <res-auth>Container</res-auth>
> >    </resource-ref>
> > ....
> >
> >
> > context.xml is placed to META-INF/context.xml :
> > <?xml version='1.0' encoding='utf-8'?>
> > <Context>
> >    <Resource name="jdbc/isDS" auth="Container"
> >        type="javax.sql.DataSource"
> >        driverClassName="oracle.jdbc.OracleDriver"
> >        url="jdbc:oracle:thin:@172.16.4.4:1523:schema"
> >        username="test" password="test"/>
> > </Context>
> >
> > This connection works I've tested it.
> >
> > *How can I fix this exception??*
> > I've even don't try to call the interested JNDI DataSource.
> >
> > When Tomcat starts it even check the connection, screenshot at
> > http://ovservice.org/trouble.PNG
> >
> >
> > --
> > ________________________
> > Best regards,
> > Alexandr Khlystov
> >
>
>
>
> --
> --
> Yassine Elassad
> Bonn, Germany.
> Fon : +49 228 97629355
> Mobile : +49 157 74519666
>
> PEACE :
> ( P ) Positive ( E ) Energy ( A ) Always ( C ) Correct ( E ) Errors.
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
>
>


-- 
________________________
Best regards,
Alexandr Khlystov

Re: SEVERE: Null component Catalina:type=DataSource

Posted by Yassine <el...@users.sourceforge.net>.
Hi Alexander,

as far i can see, everything seems to be fine, the only thing that i
can think of is
that you could have an old instance of context.xml in your
E:\Program Files\Apache Software Foundation\Tomcat
6.0\conf\Catalina\localhost\yourAppName.xml
which contains old configs and since that one exist tomcat does not
overwrite it with the one
you put into yourAppDir/META-INF/context.xml

Yassine



On Fri, Mar 27, 2009 at 9:55 AM, Alexandr Khlystov
<al...@gmail.com> wrote:
> Guys I've broken my head with this error, google gives nothing.
>
> I tried to follow
> http://tomcat.apache.org/tomcat-6.0-doc/jndi-datasource-examples-howto.html.
>
> Tomcat 6.0.
> Oracle 9.0.
> driver: oracle_jdbc13-9.0.2.0.0.jar is added to "E:\Program Files\Apache
> Software Foundation\Tomcat 6.0\lib\"
>
> I see at catalina.2009-03-27.log:
>
> *SEVERE:* Null component
> Catalina:type=DataSource,path=/com.km.integration.service.web,host=localhost,class=javax.sql.DataSource,name="jdbc/isDS"
>
>
> *web.xml*:
> <web-app>
>
>    <resource-ref>
>        <description>Oracle Datasource example</description>
>        <res-ref-name>jdbc/isDS</res-ref-name>
>        <res-type>javax.sql.DataSource</res-type>
>        <res-auth>Container</res-auth>
>    </resource-ref>
> ....
>
>
> context.xml is placed to META-INF/context.xml :
> <?xml version='1.0' encoding='utf-8'?>
> <Context>
>    <Resource name="jdbc/isDS" auth="Container"
>        type="javax.sql.DataSource"
>        driverClassName="oracle.jdbc.OracleDriver"
>        url="jdbc:oracle:thin:@172.16.4.4:1523:schema"
>        username="test" password="test"/>
> </Context>
>
> This connection works I've tested it.
>
> *How can I fix this exception??*
> I've even don't try to call the interested JNDI DataSource.
>
> When Tomcat starts it even check the connection, screenshot at
> http://ovservice.org/trouble.PNG
>
>
> --
> ________________________
> Best regards,
> Alexandr Khlystov
>



-- 
--
Yassine Elassad
Bonn, Germany.
Fon : +49 228 97629355
Mobile : +49 157 74519666

PEACE :
( P ) Positive ( E ) Energy ( A ) Always ( C ) Correct ( E ) Errors.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org