
archetype-resources.README.vm Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of mule-module-archetype Show documentation
Show all versions of mule-module-archetype Show documentation
An architype for creating a Mule Module. It provides options for adding certain mule features and configuring the
module for Muleforge.
The newest version!
#* Common variables for all archetypes *#
#set($ModuleName = "$artifactId")
#set($ModuleName = $ModuleName.replaceAll("[-_!@#$%^&*()+:; ]", ""))
#set($ModuleName = "${ModuleName.substring(0,1).toUpperCase()}${ModuleName.substring(1)}")
#set($ModuleNameLower = "${ModuleName.toLowerCase()}")
#set($MuleVersion = "$muleVersion")
#set($MuleMajorMinorVersion = "$MuleVersion.substring(0, 3)")
#set($transports = $transports.replaceAll(" ", ""))
#if($transports.indexOf("vm") == -1)
#set($transports = "$transports,vm")
#end
#set( $transportArray = $transports.split(",") )
#set($modules = $modules.replaceAll(" ", ""))
#if($modules.indexOf("client") == -1)
#set($modules = "$modules,client")
#end
#set( $moduleArray = $modules.split(",") )
#* Setting specifict to this archetype *#
#set($package = "org/mule/module")
#set($groupId = "org.mule.modules")
#set($artifactId = "mule-module-${ModuleNameLower}")
#set($ModuleType = "Module")
#if($newProject == "n")
#set($description = "TODO")
#end
WELCOME
=======
#if($newProject == "y")
Congratulations you have just created a new Mule module!
#else
Congratulations you have just added some new features to your ${ModuleName} module!
Now you need to make sure that you update you pom.xml to use version ${muleVersion} of Mule. This will ensure you are
compiling against the correct version of Mule and you will avoid issues arising from not being about to find
configuration schemas for this module.
#end
This wizard created a number of new classes and resources useful for Mule modules. Each of the created files
contains documentation and _todo_ items where necessary. Here is an overview of what was created.
#if($newProject == "y")
./pom.xml:
A maven project descriptor that describes how to build this module. If you enabled this project for the
MuleForge, this file will contain additional information about the project on MuleForge.
./assembly.xml:
A maven assembly descriptor that defines how this module will be packaged when you make a release.
./LICENSE.txt:
The open source license text for this project.
-----------------------------------------------------------------
./src/main/java/${package}/${ModuleNameLower}/i18n/${ModuleName}Messages.java:
The ${ModuleName}Messages java class contains methods for access i18n messages embedded in your java code.
-----------------------------------------------------------------
./src/main/resources/META-INF/services/org/mule/i18n/${ModuleNameLower}-messages.properties
These message properties contain i18n strings used by ${ModuleName}Messages.java.
#end
#if($hasBootstrap == "y")
-----------------------------------------------------------------
./src/main/resources/META-INF/services/org/mule/config/registry-bootstrap.properties
This file contains key value pairs of objects that will be stored in the Mule registry when this module is loaded. These
objects are useful for loading module objects such as transformers or expression evaluators that you want to make
available inside the Mule context automatically.
These properties are defined in the form of: "objectName=fully qualified class name".
#end
#if($hasCustomSchema == "y")
-----------------------------------------------------------------
./src/main/resources/META-INF/mule-${ModuleNameLower}.xsd
The configuration schema file for this module. All configuration elements should be defined in this schema.
-----------------------------------------------------------------
./src/main/resources/META-INF/spring.schemas
Contains a mapping of the Namespace URI for this projects schema.
-----------------------------------------------------------------
./src/main/resources/META-INF/spring.handlers
Contains a mapping of the namespace handler to use for the schema in this project.
-----------------------------------------------------------------
./src/main/java/${package}/${ModuleNameLower}/config/${ModuleName}NamespaceHandler.java
The implmentation of the namespace handler used to parse elements defined in mule-${ModuleNameLower}.xsd.
#end
TESTING
=======
This project also contains test classes that can be run as part of a test suite.
#if($newProject == "y")
-----------------------------------------------------------------
./src/test/java/${package}/${ModuleNameLower}/${ModuleName}TestCase.java
This is an example functional test case. The test will work as is, but you need to configure it to actually test your
code. For more information about testing see: http://www.mulesoft.org/documentation/display/MULE3USER/Functional+Testing.
-----------------------------------------------------------------
./src/test/resources/${ModuleNameLower}-functional-test-config.xml
Defines the Mule configuration for the ${ModuleName}TestCase.java.
#end
#if($hasCustomSchema == "y")
-----------------------------------------------------------------
./src/test/java/${package}/${ModuleNameLower}/${ModuleName}NamespaceHandlerTestCase.java
A test case that is used to test each of the configuration elements inside your mule-${ModuleNameLower}.xsd schema file.
-----------------------------------------------------------------
./src/test/resources/${ModuleNameLower}-namespace-config.xml
The configuration file for the ${ModuleName}NamespaceHandlerTestCase.java testcase.
#end
ADDITIONAL RESOURCES
====================
Everything you need to know about getting started with Mule can be found here:
http://www.mulesoft.org/documentation/display/MULE3INSTALL/Hello,+Mule!
There further useful information about extending Mule here:
http://www.mulesoft.org/documentation/display/MULE3USER/Introduction+to+Extending+Mule
#if($hasCustomSchema == "y")
There is detailed information about creating Mule configuration schemas here:
http://www.mulesoft.org/documentation/display/MULE3USER/Creating+a+Custom+XML+Namespace
#end
For information about working with Mule inside and IDE with maven can be found here:
http://www.mulesoft.org/documentation/display/MULE3INSTALL/Setting+Up+Eclipse+for+Use+with+Maven
Remember if you get stuck you can try getting help on the Mule user list:
http://www.mulesoft.org/email-lists
Also, MuleSoft, the company behind Mule, offers 24x7 support options:
http://www.mulesoft.com/enterprise-subscriptions-and-support
Enjoy your Mule ride!
The Mule Team
--------------------------------------------------------------------
This project was auto-generated by the mule-module-archetype.
artifactId=${artifactId}
description=${description}
muleVersion=${muleVersion}
hasCustomSchema=${hasCustomSchema}
hasBootstrap=${hasBootstrap}
package=${package}
version=${version}
groupId=${groupId}
basedir=${basedir}
--------------------------------------------------------------------
© 2015 - 2025 Weber Informatics LLC | Privacy Policy