4

When we change the Mule Deployment Descriptor (mule-deploy.properties file) to add more flow configuration files, is it must to restart Mule for the new flows to start running? Is there any way we can deploy the new flows without restarting Mule or interrupting already running flows?

As far as I understand from the Hot Deployment Page in Mule documentation, Hot Deployment works only for the changed configuration files and Java classes. Does it work for Deployment Descriptor too?

Pranav Pal
  • 275
  • 6
  • 18

1 Answers1

2

You can always touch any configuration file that has already been loaded to have Mule trigger a hot deployment so it picks up the new entries in mule-deploy.properties.

David Dossot
  • 33,403
  • 4
  • 38
  • 72
  • Thanks for the reply, David! But this doesn't seem to be working for me. I changed the mule-deploy.properties file and touched the already loaded configuration files, but nothing happened. Are there any things that I need to take care of? The documentation page says start your app as `mule -app foo`. Is it necessary to start Mule for a particular app? I am using Mule 3.2. – Pranav Pal Apr 18 '13 at 04:29
  • Grumph :( Just checking: is `redeployment.enabled=true` in `mule-deploy.properties`. And no, most of the time, you just start Mule and load all the apps in the `/app` directory. – David Dossot Apr 18 '13 at 16:48
  • Yes, `redeployment.enabled=true` is set in `mule-deploy.properties`. I just realized that I am running Mule by embedding it in a Java application (`java org.mule.MuleServer -config `), and hot deployment is not supported in this scenario according to this [page](http://www.mulesoft.org/documentation/display/current/Deployment+Scenarios). Thanks for your help anyways. – Pranav Pal Apr 19 '13 at 05:00
  • Indeed, hot deployment only works if you run the standalone broker. If you run embedded in a web-app, the simplest is to redeploy your web-app. Otherwise, you'll have to restart the embedded Mule your application is running: you have full control from your code, so no need to restart the wrapper app. – David Dossot Apr 19 '13 at 16:12
  • Hi David! I was trying out Hot Deployment with Mule standalone model and noticed that Hot Deployment picks up changes in the configuration files, but it does not pick up changes in `mule-deploy.properties` file. For example, I removed a flow from config.resources list in the `mule-deploy.properties` file and then touched `mule-config.xml`. The app was reloaded, but the removed flow still ran. Am I missing something here? – Pranav Pal May 20 '13 at 10:14
  • Take a look at http://www.mulesoft.org/documentation/display/current/Hot+Deployment#HotDeployment-HowHotDeploymentworks : "Mule checks only the first configuration file in your application's directory" but **first** is not strictly defined (I reckon it depends on the file system). This said, it doesn't make sense that the removed flow was still running. Maybe a bug? – David Dossot May 20 '13 at 13:29
  • Thanks, David! Somehow the Hot Deployment documentation does not talk anything about changes to `mule-deploy.properties`. So not sure if it is a bug or it is designed that way. – Pranav Pal May 21 '13 at 09:13