[jboss-user] [Clustering/JBoss] - Re: Cluster Deployment: farming

sankul123 do-not-reply at jboss.com
Wed Jun 25 18:09:52 EDT 2008

"bstansberry at jboss.com" wrote : I don't understand your question.  Are you saying you try to edit files in the default/tmp folder but then find they get overridden from the content in default/deploy when you redeploy?  But an exploded archive lets you edit the exploded content?
I am sorry for the confusion, I meant to say that a previously exploded context is lost once you restart the Jboss server.
Consider following myApp.ear for example -
  | |
  | |
  | |-------myWeb.war
  | |          |
  | |          |-------config
  | |          |          |
  | |          |          |-------customConfig.properties[configurations are lost after restarts]
  | |          |          |
  | |          |          
  | |          |-------upload[User uploads few config input file. Uploaded files are also lost on restarts of server]          
  | |          |          |          
  | |          |          |------- aInput.xml
  | |          |          |------- bInput.xml
  | |          |          |------- cInput.xml
  | |          |    

myApp.ear archived file is deployed under  ${jboss.home}\server\default\deploy\ then its content will be exploded to default\tmp\deploy\tmp1234myApp-contents.ear[with some namimg protocol of Jboss].

Any configuration changes done to customConfig.properties file resides inside exploded context tmp1234myApp-contents.ear directory. Similarly any file uploads done to the context will also reside in this temp exploaded directory.

Once we restart Jboss server, it deletes all contents of ${jboss.home}\server\default\tmp\deploy folder,where the ear files are exploaded and exploads are the ear files again.
Since modification done to the exploaded application[context] resides in tmp\deploy\, are lost after restart.When server is restarted ear file is extracted again to tmp\deploy folder. 

All configurations done on previously exploaded application are lost.

"bstansberry at jboss.com" wrote : And your description of "farming service" doesn't describe any service provided by JBoss. There is no feature to replicate uploaded files around a cluster (except if you did something like store the file content byte[] as an attributed in a clustered web session).
And for this I still need some more clarification -
>From Cluster guide -
anonymous wrote : The easiest way to deploy an application into the cluster is to use the farming service. That is to hot-deploy the application
  | archive file (e.g., the EAR, WAR or SAR file) in the all/farm/ directory of any of the cluster member
  | and the application is automatically duplicated across all nodes in the same cluster. If node joins the cluster later, it
  | will pull in all farm deployed applications in the cluster and deploy them locally at start-up time. If you delete the
  | application from one of the running cluster server node's farm/ folder, the application will be undeployed locally
  | and then removed from all other cluster server nodes farm folder (triggers undeployment.) You should manually
  | delete the application from the farm folder of any server node not currently connected to the cluster
What if there is any modifcation to the context , as explained in above in myApp.ear  issue example.If there is a file upload to the context? how will this be communicate to other nodes?
I dont see any thing that explain my doubt in cluster guide/doc, please let me know if my understanding is wrong. 
If Jboss does not support replication of context , should we use any cluster software to do that?


View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4160686#4160686

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4160686

More information about the jboss-user mailing list