You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by "Dmitry S. Kravchenko" <di...@vsetech.ru> on 2006/05/08 17:23:28 UTC

Default servlet

Hi!

How can I configure existance of default servlet? 

This servlet, as I can see, allows me to use following mappings

  <servlet-mapping>
    <servlet-name>default</servlet-name>
    <url-pattern>/res/*</url-pattern>
  </servlet-mapping>
  <servlet-mapping>

See, that I don't want to write this servlet by my own, it should already
exist somewhere in the Tomcat.

Thnx.

Dims.


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


Re: Default servlet

Posted by Tim Funk <fu...@joedog.org>.
The default servlet already is mapped to / so your mapping below is not needed.

Tomcat's default servlet is defined in $CATALINA_HOME/conf/web.xml


-Tim

Dmitry S. Kravchenko wrote:

> Hi!
> 
> How can I configure existance of default servlet? 
> 
> This servlet, as I can see, allows me to use following mappings
> 
>   <servlet-mapping>
>     <servlet-name>default</servlet-name>
>     <url-pattern>/res/*</url-pattern>
>   </servlet-mapping>
>   <servlet-mapping>
> 
> See, that I don't want to write this servlet by my own, it should already
> exist somewhere in the Tomcat.
>  

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


Re: error during tomcat startup when starting springframework

Posted by Konstantin Ignatyev <ko...@sourcelabs.com>.
I used to do it with JDBC-ODBC bridge driver few years ago
http://java.sun.com/j2se/1.3/docs/guide/jdbc/getstart/bridge.doc.html

Asegid Debebe wrote:
> Dear All,
> 
> Can you please tell me where I can download the JDBC driver for Microsoft
> Access 2002/3 databases? I have write a sample Servlet that reads data from
> Microsost Access databases, very quickly.
> 
> Thanks,
> 
> AD
> 

-- 
Thanks,

Konstantin

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


Re: error during tomcat startup when starting springframework

Posted by Asegid Debebe <as...@gmail.com>.
Dear All,

Can you please tell me where I can download the JDBC driver for Microsoft
Access 2002/3 databases? I have write a sample Servlet that reads data from
Microsost Access databases, very quickly.

Thanks,

AD

error during tomcat startup when starting springframework

Posted by lee hwaying <hw...@hotmail.com>.
can some one help please



@40000000445f116006a73194
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
@40000000445f116006a74134 java.lang.NoClassDefFoundError
@40000000445f116006a7451c at
net.sf.cglib.core.KeyFactory$Generator.generateClass(KeyFactory.java:167)
@40000000445f116006a7d5a4 at
net.sf.cglib.core.DefaultGeneratorStrategy.generate
(DefaultGeneratorStrategy.java:25)
@40000000445f116006a7dd74 at
net.sf.cglib.core.AbstractClassGenerator.create
(AbstractClassGenerator.java:215)
@40000000445f116006a7e544 at
net.sf.cglib.core.KeyFactory$Generator.create(KeyFactory.java:145)
@40000000445f116006a7ed14 at net.sf.cglib.core.KeyFactory.create
(KeyFactory.java:117)
@40000000445f116006a80c54 at net.sf.cglib.core.KeyFactory.create
(KeyFactory.java:108)
@40000000445f116006a8103c at net.sf.cglib.core.KeyFactory.create
(KeyFactory.java:104)
@40000000445f116006a8180c at
org.hibernate.impl.SessionFactoryImpl.<clinit>(SessionFactoryImpl.java:321)
@40000000445f116006a81fdc at
org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1005)
@40000000445f116006a852a4 at
org.springframework.orm.hibernate3.LocalSessionFactoryBean.newSessionFactory
(LocalSessionFactoryBean.java:777)
@40000000445f116006a85a74 at
org.springframework.orm.hibernate3.LocalSessionFactoryBean.afterPropertiesSet
(LocalSessionFactoryBean.java:703)
@40000000445f116006a8662c at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.in
vokeInitMethods(AbstractAutowireCapableBeanFactory.java:1058)
@40000000445f116006a8856c at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.cr
eateBean(AbstractAutowireCapableBeanFactory.java:363)
@40000000445f116006a89124 at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean
(AbstractBeanFactory.java:226)
@40000000445f116006a898f4 at
org.springframework.beans.factory.support.AbstractBeanFactory.getBean
(AbstractBeanFactory.java:147)
@40000000445f116006a8b44c at
org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstant
iateSingletons(DefaultListableBeanFactory.java:269)
@40000000445f116006a8c004 at
org.springframework.context.support.AbstractApplicationContext.refresh
(AbstractApplicationContext.java:318)
@40000000445f116006a8c7d4 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: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


[OT] Hijack (WAS: Re: System.setProperty failed during Tomcat5 startup)

Posted by Antonio Petrelli <br...@tariffenet.it>.
Tim Funk ha scritto:
> 1) Don't hijack threads - start a new one
The last famous words... some people will never learn ;-)
Ciao
Antonio

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


Re: update jar file does not work immediately

Posted by Mark Thomas <ma...@apache.org>.
When starting a new thread (ie sending a message to the list about a
new topic) please do not reply to an existing message and change the
subject line. To many of the list archiving services and mail clients
used by list subscribers this  makes your new message appear as part
of the old thread. This makes it harder for other users to find
relevant information when searching the lists.

This is known as thread hijacking and is that is frowned
upon on this list. Frequent offenders will be removed from the list.
It should also be noted that many list subscribers automatically
ignore any messages that hijack another thread.

The correct procedure is to create a new message with a new subject.
This will start a new thread.

Mark
tomcat-user-owner

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


Re: update jar file does not work immediately

Posted by Calvin Deiterich <ce...@comcast.net>.
Tony,
I have the same problem. Eclipse 3.1 WTP install.
I ended up shutting down tomcat and deleting the .war and the folder,
then saving the new .war file and start the tomcat up again.
I also publish to another tomcat server and still have to do the same
thing.  On both machines I am running tomcat 5.5.17.
Hope someone has a solution as this is a pain.
Calvin

Tony Smith wrote the following on 5/18/2006 7:30 PM:
> Hi, 
>  
>  I am using Tomcat 5.5.9 on Windows. I use Eclipse to
>  write my server code. Every time I change my code, I
>  export the jar directly to the myapp/WEB-INF/lib
>  directory and restart Tomcat. I found that the new
>  code is not immediately used by Tomcat, I have to
>  re-export, re-start Tomcat a couple times to make
>  Tomcat pickup my new code.
>  
>  Anyone know why?
>  
>  Thanks,
>  
>  qq
>>
>> __________________________________________________


-- 
http://mywebpages.comcast.net/tnczoo/
-----
"If a dog will not come to you after having looked you in the face,
you should go home and examine your conscience."
- Woodrow Wilson
-----


update jar file does not work immediately

Posted by Tony Smith <qu...@yahoo.com>.
Hi, 
 
 I am using Tomcat 5.5.9 on Windows. I use Eclipse to
 write my server code. Every time I change my code, I
 export the jar directly to the myapp/WEB-INF/lib
 directory and restart Tomcat. I found that the new
 code is not immediately used by Tomcat, I have to
 re-export, re-start Tomcat a couple times to make
 Tomcat pickup my new code.
 
 Anyone know why?
 
 Thanks,
 
 qq
> 
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam
> protection around 
> http://mail.yahoo.com 
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail:
> users-help@tomcat.apache.org
> 
> 


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

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


update jar file does not work immediately

Posted by Tony Smith <qu...@yahoo.com>.
Hi, 

I am using Tomcat 5.5.9 on Windows. I use Eclipse to
write my server code. Every time I change my code, I
export the jar directly to the myapp/WEB-INF/lib
directory and restart Tomcat. I found that the new
code is not immediately used by Tomcat, I have to
re-export, re-start Tomcat a couple times to make
Tomcat pickup my new code.

Anyone know why?

Thanks,

qq


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

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


Re: System.setProperty failed during Tomcat5 startup

Posted by Tim Funk <fu...@joedog.org>.
Don't know - you'll need to ask a spring related user list.

-Tim

lee hwaying wrote:

> 
> 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 <fu...@joedog.org>
>> Reply-To: "Tomcat Users List" <us...@tomcat.apache.org>
>> To: Tomcat Users List <us...@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)
>>> @40000000445f114f374f04fc at
>>> java.security.AccessControlContext.checkPermission
>>> java.security.AccessController.checkPermission(AccessController.java:427) 
>>>
>>> @40000000445f114f374f149c at java.lang.SecurityManager.checkPermission
>>> (SecurityManager.java:532)
>>> @40000000445f114f374fa524 at java.lang.System.setProperty
>>> (System.java:698)
>>> @40000000445f114f374facf4 at
>>> org.springframework.web.util.WebUtils.setWebAppRootSystemProperty
>>> (WebUtils.java:104)
>>> @40000000445f114f374fb4c4 at
>>> org.springframework.web.util.Log4jWebConfigurer.initLogging

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


Re: System.setProperty failed during Tomcat5 startup

Posted by lee hwaying <hw...@hotmail.com>.
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 <fu...@joedog.org>
>Reply-To: "Tomcat Users List" <us...@tomcat.apache.org>
>To: Tomcat Users List <us...@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)
>>@40000000445f114f374f04fc at
>>java.security.AccessControlContext.checkPermission
>>java.security.AccessController.checkPermission(AccessController.java:427)
>>@40000000445f114f374f149c at java.lang.SecurityManager.checkPermission
>>(SecurityManager.java:532)
>>@40000000445f114f374fa524 at java.lang.System.setProperty
>>(System.java:698)
>>@40000000445f114f374facf4 at
>>org.springframework.web.util.WebUtils.setWebAppRootSystemProperty
>>(WebUtils.java:104)
>>@40000000445f114f374fb4c4 at
>>org.springframework.web.util.Log4jWebConfigurer.initLogging
>>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>For additional commands, e-mail: users-help@tomcat.apache.org
>

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


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


Re: System.setProperty failed during Tomcat5 startup

Posted by Tim Funk <fu...@joedog.org>.
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)
> @40000000445f114f374f04fc at
> java.security.AccessControlContext.checkPermission
> java.security.AccessController.checkPermission(AccessController.java:427)
> @40000000445f114f374f149c at java.lang.SecurityManager.checkPermission
> (SecurityManager.java:532)
> @40000000445f114f374fa524 at java.lang.System.setProperty
> (System.java:698)
> @40000000445f114f374facf4 at
> org.springframework.web.util.WebUtils.setWebAppRootSystemProperty
> (WebUtils.java:104)
> @40000000445f114f374fb4c4 at
> org.springframework.web.util.Log4jWebConfigurer.initLogging
> 

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


System.setProperty failed during Tomcat5 startup

Posted by lee hwaying <hw...@hotmail.com>.
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)
@40000000445f114f374f04fc at
java.security.AccessControlContext.checkPermission
java.security.AccessController.checkPermission(AccessController.java:427)
@40000000445f114f374f149c at java.lang.SecurityManager.checkPermission
(SecurityManager.java:532)
@40000000445f114f374fa524 at java.lang.System.setProperty
(System.java:698)
@40000000445f114f374facf4 at
org.springframework.web.util.WebUtils.setWebAppRootSystemProperty
(WebUtils.java:104)
@40000000445f114f374fb4c4 at
org.springframework.web.util.Log4jWebConfigurer.initLogging


>From: "Tim Lucia" <ti...@yahoo.com>
>Reply-To: "Tomcat Users List" <us...@tomcat.apache.org>
>To: "'Tomcat Users List'" <us...@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:markt@apache.org]
>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: users-unsubscribe@tomcat.apache.org
>For additional commands, e-mail: users-help@tomcat.apache.org
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
>For additional commands, e-mail: users-help@tomcat.apache.org
>

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


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


RE: Default servlet

Posted by Tim Lucia <ti...@yahoo.com>.
Mark is right (of course)... my bad.

-----Original Message-----
From: Mark Thomas [mailto:markt@apache.org] 
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: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


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


Re: Default servlet

Posted by Mark Thomas <ma...@apache.org>.
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: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: Default servlet

Posted by Tim Lucia <ti...@yahoo.com>.
Look in conf/web.xml -- it is commented out by default.  It is widely
considered evil to use the default servlet.  At a minimum, it poses security
risks.

Tim


-----Original Message-----
From: Dmitry S. Kravchenko [mailto:dims@vsetech.ru] 
Sent: Monday, May 08, 2006 11:23 AM
To: users@tomcat.apache.org
Subject: Default servlet

Hi!

How can I configure existance of default servlet? 

This servlet, as I can see, allows me to use following mappings

  <servlet-mapping>
    <servlet-name>default</servlet-name>
    <url-pattern>/res/*</url-pattern>
  </servlet-mapping>
  <servlet-mapping>

See, that I don't want to write this servlet by my own, it should already
exist somewhere in the Tomcat.

Thnx.

Dims.


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


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