This page last changed on Oct 02, 2006 by lajos@mulesource.com.

Introduction

The easiest way to start using mule is to walk through an example. The following chapters provide a step-by-step guide to setting up and running the example applications that ship with Mule.

Build Scripts

Starting with the 1.3-rc5 release, Mule samples are found in the examples directory under the distribution. Mule ships will two kinds of samples: samples that run out of the box, and samples the depend on downloading of third-party jars. For this reason, the examples directory is subdivided into ant and maven directories. Each of these directories contains the same samples - the only practical difference is the build script in each sample directory. In the ant directory structure, all samples have a build.xml file. In the maven directory structure, all samples have a pom.xml file.

Currently, the only examples that require third-party jars are the Loan Broker and Error Hander examples. If you wish to use Ant (version 1.6.5 or greater) to prepare these samples, use the examples/ant directory. If you prefer to use Maven instead, use the examples/maven

Samples

Listed below are the samples that ship with the full Mule distribution. Click on the links below to see the detailed instructions for each.


Echo Example
Is a simple component example that demostrates how to expose a component over multiple transports.


Hello World Example
Shows how to configure multiple components to interact on a single request and how to manage event transformations.
The is a good article on DevX that describes how to get started with Mule using the Hello World Example.


Stock Quote Example
This example demonstrates how to invoke an ASPX web service from Mule and transform the result using XSLT and deserialise the result to a StockQuote javabean. The examples demonstrates invoking the service using REST and SOAP.


Error Handler Example
Demonstrates using Spring as the external container to provide the objects managed by Mule and how to publish events to multiple outbound endpoints. The sample consists of two components; ExecptionManager and BusinessErrorManager.


Spring Events Example
Demostrates how to send and recieve Mule events using the Spring ApplicationContext without needing to write any Mule specific code or configuration!


Scripting Example
Demostrates Mule's JSR-223 Scripting support.


Loan Broker Example
The Loan Broker example application is based on the example presented in the Enterprise Integration Patterns book. This chapter of the book is available online so you can see a detailed description of the application here.


Voip Service Example
The Voip Service example is taken from a Java.net featured article, Provisioning Services Through ESB describes how to orchestrate services through abstraction, providing a VOIP provisioning example developed using Mule.

Mail, Servlet and Jms Example
This page contains a simple example that explains how to integrate Servlets, Jms (ActiveMQ) and JavaMail using a simple programming example.


Mule Examples Webapp
Is a webapp that provides an interface to some of the examples here such as the LoanBroker, Hello World and Echo examples. It also provides examples of accessing Mule using REST style service calls and is itself an example of how to embed Mule in a webapp.

Document generated by Confluence on Oct 03, 2006 09:23