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

Mule 3 Installation Guide - Contents

Mission critical Mule deployment?

Try Mule Enterprise

Mule Enterprise Edition provides:

  • Hot fixes, security patches and backported bug fixes
  • High availability clustering to eliminate downtime
  • Root cause problem analysis tools
  • 24/7 support from the Mule experts

Need help with Mule?

Get Mule services

Whether you are just getting started or want to improve an existing Mule architecture, MuleSoft experts provide:

  • Onsite and online Training
  • Consulting Services
  • Enterprise Support

Mule is Hiring!

Apply now

Like working with Mule? We're looking for superstars to join our amazing team.

Did you know . . .
MuleSoft has released Studio GA, a powerful new interface for Mule ESB that can cut your development time by half or more. You can model, debug, and deploy your applications all within the rich, yet flexible Studio environment.

Studio provides two-way (i.e., graphical and code-based) editing, which means that developers no longer have to trade ease-of-use against fine-grained control over their development projects. Any changes you make in one mode appear instantly in the other.

Mule Enterprise and Mule iON developers can fine-tune their applications in the advanced Studio XML editor, then re-deploy them on whichever version of Mule those applications were originally developed.

Studio installation is almost instantaneous, and a pair of tutorials can get you up and running in less than 40 minutes.

Let’s get Kicking!

Hello, Mule!

This page describes the fastest route for downloading, installing, and running Mule ESB. After following the steps in this topic, you will have configured your development environment, launched Mule ESB 3, and successfully deployed your first Mule ESB application.

For the complete installation instructions, including how to set up additional tools such as Maven, or controlling how Mule is configured at startup, see the Complete Installation Manual.

Prerequisites

  • You must have one of the following Java Development Kit packages installed on the computer where you install Mule:
  • Standard Edition 1.6.0_26 (also known as JDK SE 6 Update 26) or more recent
  • Enterprise Edition 1.6u3 (JDK EE 6 Update 3) or more recent

Download and Install Mule

  1. In your browser, go to the Mule download page.
  2. Use the .zip button for Windows and the .tar.gz button for Linux/UNIX. On Linux/UNIX, if wget ships by default on your distribution, or if you have installed wget, you can also enter the following command in a terminal window to download Mule:
    wget http://dist.codehaus.org/mule/distributions/mule-standalone-3.2.0.tar.gz.
    
  3. Extract the files from it into the directory you want to use as your Mule home directory.
    Do not install Mule in a directory path that contains spaces!

    On Linux/UNIX, in a terminal window switch to your installation directory, and enter the following command:

    tar -xvzf mule-standalone-3.2.0.tar.gz
    
If you're upgrading from Mule ESB 2.2, read this: Previous versions of Mule ESB required setting an environment variable called MULE_HOME to run Mule. As of Mule 3.1, the MULE_HOME variable is no longer required. Make sure to remove this setting from your environment before running Mule 3.2. This is also true of a previously set MULE_BASE variable.

Install Eclipse and Mule IDE

To begin developing a Mule application, install the Mule IDE.

  1. If you do not have Eclipse version 3.4 or later, download the latest version of Eclipse from http://www.eclipse.org/downloads/ and install it. MuleSoft recommends the Eclipse Java EE Developers package, but you can also install the Java Developers package.
  2. Start Eclipse, and set up a workspace for your installation of Mule. (Important: Make sure your workspace does not have a space in the directory path or the Mule application you develop will not run.)

For Eclipse version 3.5/3.6/3.7 (Galileo/Helios/Indigo) follow these steps to install Mule IDE:

  1. In the workbench view, click Help > Install New Software.
  2. Click the Add button next to the Work with text box, enter http://dist.muleforge.org/mule-ide/updates-2.1.x/ for the location, and press Enter. The Mule IDE now appears in your list of available software.
  3. Select the Mule IDE check box and click Next. Eclipse will process for a moment. When Eclipse is finished processing, click Next again.
  4. Review the Mule IDE license, select the option to accept the license, and then click Finish.
  5. Click Yes to restart Eclipse.

If you are using Eclipse version 3.4 (Ganymede), read this:

  1. In the workbench view, choose Help > Software Updates.
  2. On the Available Software tab, click Add Site.
  3. Specify http://dist.muleforge.org/mule-ide/updates-2.1.x/ for the location and click OK. It now appears in your list of available software.
  4. Expand the list until you see the Mule IDE. Choose Mule IDE and click Install.
  5. Click Next, read and accept the license agreement terms, and click Finish.
  6. Choose to run the installation in the background.
  7. When prompted, restart Eclipse.

Configure the Mule Distribution

To execute Mule properly, you must specify in the IDE the location of your Mule distribution.

  1. In the Eclipse workbench, choose Window > Preferences. (On Mac OS X, choose Eclipse > Preferences.)
  2. Choose Mule, and then click Add
  3. Specify your Mule home directory. Then click OK.
  4. Select the Mule distribution's check box, click Apply, then click OK.

Create a Mule Application

  1. Choose File > New > Project, expand the Mule folder and select Mule Project, and then click Next.
  2. Enter a name for the project, ensuring that there is no space in the project name. If you want to put the project in a location other than the default workspace, clear the Use default location check box and specify a new file location.
  3. Click Finish so the Mule IDE will generate your project. The project just created is added to the Package Explorer pane. The Mule libraries from the distribution you selected are contained in the project.
  4. Create a conf directory in your Mule project.
  5. Create a new file in the conf directory called "mule-config.xml."
  6. Add the following configuration to mule-config.xml:
<?xml version="1.0" encoding="UTF-8"?>

<mule xmlns="http://www.mulesoft.org/schema/mule/core"
      xmlns:script="http://www.mulesoft.org/schema/mule/scripting"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="
      http://www.mulesoft.org/schema/mule/scripting http://www.mulesoft.org/schema/mule/scripting/3.2/mule-scripting.xsd
      http://www.mulesoft.org/schema/mule/core http://www.mulesoft.org/schema/mule/core/3.2/mule.xsd" >

    <simple-service name="hello" address="http://localhost:8080/hello">
        <script:component>
            <script:script engine="groovy">
                <script:text>return "Hello World"</script:text>
            </script:script>
        </script:component>
    </simple-service>
</mule>


Note that what you have just done is create a Mule application, which is XML-driven. When you create a configuration, you are creating an application.

Run the Application

  1. In the Package Explorer, expand the conf directory, and right-click the mule-config.xml configuration file.
  2. Choose Run As > Mule Server.

A new run configuration is created automatically and the server is started. To trigger the Hello service, connect to http://localhost:8080/hello in your browser. The server should respond back with the text "Hello World."

That's it! You have a complete Mule development environment up and running and have created your first application.

Next Steps

Your Rating: Results: PatheticBadOKGoodOutstanding! 41 rates
Adaptavist Theme Builder (4.2.2) Powered by Atlassian Confluence 3.4.7, the Enterprise Wiki