Caucho Forums  

This forum is permanently closed because of spam. For free community support, please visit Google Groups:


Go Back   Caucho Forums > Resin

Reply
 
Thread Tools Display Modes
  #1  
Old 04-24-2012, 04:07 PM
jalberto jalberto is offline
Junior Member
 
Join Date: Mar 2012
Location: London, UK
Posts: 24
Question How to disable WelcomeFile exception

Hi,

We are getting continuously the following exception in the logs:

java.lang.ClassNotFoundException: file in EnvironmentClassLoader[web-app:production/webapp/default/ROOT-2.0.15]
at com.caucho.loader.DynamicClassLoader.loadClass(Dyn amicClassLoader.java:1467)
at com.caucho.loader.DynamicClassLoader.loadClass(Dyn amicClassLoader.java:1444)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:247)
at com.caucho.server.dispatch.ServletMapping.initRege xpClass(ServletMapping.java:229)
at com.caucho.server.dispatch.ServletMapping.getServl etClass(ServletMapping.java:169)
at com.caucho.server.dispatch.ServletMapper.getServle tClassByUri(ServletMapper.java:473)
at com.caucho.rewrite.WelcomeFile.matchWelcomeUri(Wel comeFile.java:219)
at com.caucho.rewrite.WelcomeFile.matchWelcomeFileRes ource(WelcomeFile.java:150)
at com.caucho.rewrite.WelcomeFile.map(WelcomeFile.jav a:125)
at com.caucho.server.webapp.WebApp.applyWelcomeFile(W ebApp.java:3902)
at com.caucho.server.webapp.WebApp.buildInvocation(We bApp.java:3828)
at com.caucho.server.webapp.WebAppContainer.buildInvo cation(WebAppContainer.java:781)
at com.caucho.server.host.Host.buildInvocation(Host.j ava:752)
at com.caucho.server.host.HostContainer.buildInvocati on(HostContainer.java:319)
at com.caucho.server.cluster.ServletService.buildInvo cation(ServletService.java:961)
at com.caucho.server.dispatch.InvocationServer.buildI nvocation(InvocationServer.java:247)
at com.caucho.server.dispatch.InvocationServer.buildI nvocation(InvocationServer.java:220)
at com.caucho.server.http.AbstractHttpRequest.buildIn vocation(AbstractHttpRequest.java:1565)
at com.caucho.server.http.AbstractHttpRequest.getInvo cation(AbstractHttpRequest.java:1538)
at com.caucho.server.hmux.HmuxRequest.handleInvocatio n(HmuxRequest.java:457)
at com.caucho.server.hmux.HmuxRequest.handleRequestIm pl(HmuxRequest.java:369)
at com.caucho.server.hmux.HmuxRequest.handleRequest(H muxRequest.java:336)
at com.caucho.network.listen.TcpSocketLink.dispatchRe quest(TcpSocketLink.java:1301)
at com.caucho.network.listen.TcpSocketLink.handleRequ est(TcpSocketLink.java:1257)
at com.caucho.network.listen.TcpSocketLink.handleRequ estsImpl(TcpSocketLink.java:1241)
at com.caucho.network.listen.TcpSocketLink.handleRequ ests(TcpSocketLink.java:1149)
at com.caucho.network.listen.TcpSocketLink.handleKeep aliveTask(TcpSocketLink.java:985)
at com.caucho.network.listen.KeepaliveRequestTask.doT ask(KeepaliveRequestTask.java:55)
at com.caucho.network.listen.ConnectionTask.runThread (ConnectionTask.java:110)
at com.caucho.network.listen.ConnectionTask.run(Conne ctionTask.java:93)
at com.caucho.network.listen.SocketLinkThreadLauncher .handleTasks(SocketLinkThreadLauncher.java:169)
at com.caucho.network.listen.TcpSocketResumeThread.ru n(TcpSocketResumeThread.java:62)
at com.caucho.env.thread2.ResinThread2.runTasks(Resin Thread2.java:173)
at com.caucho.env.thread2.ResinThread2.run(ResinThrea d2.java:118)
We do not have nor want a WelcomePage on ROOT, the rewrite of "/" into the correct URL is managed outside Resin. Either watchdog or mod_caucho or Health subsystems are calling this URL every minute.

We have setup the following rules in web.xml:

<welcome-file-list/>
<resin:Redirect regexp="^/?$" target="http://www.cellectivity.com"/>
If one accesses directly one of the servers on port 8080 on "/" no exception is thrown and one is correctly redirected as specified. However something is triggering the exception every 60s.

How can I change this behaviour or tell whatever component it is that it must look at some other URL. There are no access entries for "/" on the access logs.
Reply With Quote
  #2  
Old 04-24-2012, 07:29 PM
alex alex is offline
Administrator
 
Join Date: Aug 2009
Posts: 218
Default

You should be able to see what url is being accessed with logging level set to finer. This can be set in conf/resin.properties file.

What http_ping_urls is set to?

Thanks,
Alex
Reply With Quote
  #3  
Old 04-26-2012, 12:34 PM
jalberto jalberto is offline
Junior Member
 
Join Date: Mar 2012
Location: London, UK
Posts: 24
Default

We have not set any at the moment, is "/" the default URL?
We were planning to add the ping URLs separate for each one of our webapps, in their own resin-web.xml.

What I do not understand is why this checking is bypassing the <welcome-file-list/> and the <resin:Redirect> settings. As I mentioned, if I go on the browser to "/" the exception is not triggered.

Regards,

Jose Alberto
Reply With Quote
  #4  
Old 04-26-2012, 07:25 PM
alex alex is offline
Administrator
 
Join Date: Aug 2009
Posts: 218
Default

I am checking against the trunk (since it would be fixed on the trunk).

If the ping url isn't specified (empty) it will be omitted.

Can you check servlet-class mapping in your web.xml. The ones that have ${ as part of the value are the suspects.

There is that mapping & request uri pair that cause Resin to evaluate that servlet-class as a 'file' which is obviously wrong.

You might want to change that mapping to be more strict.

Thanks,
Alex
Reply With Quote
  #5  
Old 04-27-2012, 02:15 PM
jalberto jalberto is offline
Junior Member
 
Join Date: Mar 2012
Location: London, UK
Posts: 24
Default

Hi Alex,

I do not have any ${ at all in the servlet definitions or servlet mappings. If not the watchdog, could it be something like mod_caucho trying to check on the servers?

Jose Alberto
Reply With Quote
  #6  
Old 04-27-2012, 10:59 PM
alex alex is offline
Administrator
 
Join Date: Aug 2009
Posts: 218
Default

Well, it looks like the request is coming in on a HmuxPort, so it could be mod_caucho. I would start with matching the exception to a record in access.log of Resin ( by timestamp).
Reply With Quote
Reply

Tags
cluster, healthcheck, mod_caucho, resin 4.0, watchdog configuration

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT. The time now is 01:08 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.