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 11-22-2011, 06:58 PM
theBlueSage theBlueSage is offline
Member
 
Join Date: Apr 2011
Posts: 33
Default Clustered resins need to used separate work-dirs .. how?

I am experimenting with using a cluster of 5 resins, managed by a single watchdog. So far I have been able to get 99% of it working but the last bit is a killing me and is a show-stopper.

How can I configure resin.xml to allow me to use different work-dirs for each <server> node

so far I have this :

<server id="a" ip="*" port="6800">
<http port="10880" />
</server>
<server id="b" ip="*" port="6801">
<http port="10881" />
</server>

etc, but as work-dir is a child/attribute of web-app, and web-app is a child if resin and/or host, but not a child of server, how can I configure resin to achieve my goals?

answers, suggestions, pointer etc, all welcome .... This is driving me bat**** crazy ...

thanks for any help,

Richard
Reply With Quote
  #2  
Old 11-22-2011, 09:51 PM
ferg ferg is offline
Administrator
 
Join Date: Aug 2009
Posts: 190
Default

The quick answer is that you can configure the <work-dir> to depend on the server id.

<work-dir>WEB-INF/work-${resin.serverId}</work-dir>
Reply With Quote
  #3  
Old 11-23-2011, 01:14 AM
theBlueSage theBlueSage is offline
Member
 
Join Date: Apr 2011
Posts: 33
Default

ok, let me check I understand what you are saying. Given that all the server nodes are in the same resin.xml file, are you telling me to create a separate work-dir node in the xml doc for each server node? If so that is great, do these work-dir nodes all live within the same web-app node?

You said that that was the quick answer ... was is the long/real answer?
Reply With Quote
  #4  
Old 11-23-2011, 02:15 AM
ferg ferg is offline
Administrator
 
Join Date: Aug 2009
Posts: 190
Default

you'd basically be creating separate work-dirs for each server, because each server has a different server-id, and therefore they wouldn't conflict.

The longer answer is just that recently a number of people have tried to do the same thing for some reason, so we might consider building that configuration as default somehow. (Although that feature might conflict with precompiled jsps, so it might need a more complicated solution.)
Reply With Quote
  #5  
Old 11-29-2011, 06:55 PM
theBlueSage theBlueSage is offline
Member
 
Join Date: Apr 2011
Posts: 33
Default Solved

Just wanted to confirm that setting the work-dir to a server-id dependent directory works correctly for us.
<web-app id="/" root-directory="webapps/ROOT" work-dir="WEB-INF/${work_dir}">

....

</web-app>

thanks for the help
Reply With Quote
Reply

Tags
cluster, configuration, resin, web-app, work-dir

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 07:46 AM.


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