Access Keys:
Skip to content (Access Key - 0)
Cancel    
Cancel   
 

Hot Deployment

Aug 26, 2010 16:37

Janet Revell

Feb 27, 2013 14:55

Mulesoft Current Mule Documentation

Hot Deployment

Mulesoft Documentation Page

Contents

Hot Deployment

You can now modify your configuration files and custom classes and have them reloaded without having to restart Mule.

Outline of a Deployment

Here is a quick summary for deploying an app 'foo':

  • Create a directory under $MULE_HOME/apps/foo
  • Jar custom classes (if any), and put them under $MULE_HOME/apps/foo/lib
  • Place the master Mule config file at $MULE_HOME/apps/foo/mule-config.xml
  • Start your app with mule -app foo

As a bonus, application's master config file is monitored, so if there are any class changes you want to pick up or simply modify the config, save or touch mule-config.xml and Mule will hot-reload the application.

How Hot Deployment works

Mule checks every three seconds for updated configuration files under the $MULE_HOME/apps directory, and when it finds one, it reloads the configuration file and the JARs in that applications lib directory.

Therefore, if you want to change one of your custom classes, you modify and rejar it, copy the updated JAR to the lib directory, and then touch or save the configuration file. Currently, Mule checks only the first configuration file in your application's directory, so right now hot deployment works best with applications that have a single configuration file.

Additional Features

  • Applications can depend on different library versions, even if they would conflict before
  • Applications are now deployed with clear boundaries
  • Multiple applications can be run side-by-side within a single instance of Mule