Template Project To Create Mule Application

 

In this tutorial we will demonstrate how can we create template project to create mule application and publish on exchange to create similar mule application. Sharing Mule applications as templates is a great way to share your work with other people who are in your organization in anypoint Platform. When they need to build a similar application they can create the mule application using the template project from anypoint studio

Create a sample mule application in anypoint studio

 

Please follow some best practices while creating the template project:

  • Define the common error handler as part of template project, either using pom dependency or mule config file
  • Define common logger/audit framework as part of the template project
  • Define the env specific properties and secure properties file as per the requirement
  • Define global.xml for global configuration
  • Define the config file for connector configuration like Http,Salesforce,File,FTP etc
  • Create separate folders to create DWL,Properties,SSL certificates etc
  • Add the dependency and configure the pom.xml as per the business need
  • Configure the mule-artifact.json as per the business need

Note: You can extend and change the template project as per the business need and project requirement

Note: If you are publishing your asset to the master organization, the group ID is the same as the organization ID.

Publish the project on exchange, Right click on project and click on publish to exchange

 

Project successfully published to exchange

 

See the project on exchange

 

Create mule application from template project

Click on file->new->project from template

Template Project To Create Mule Application

 

A new window open and we can see the project on exchange

Template Project To Create Mule Application

 

Click on project and then click open, project will open in studio

Template Project To Create Mule Application

 

Deploy the project, project should successfully build and deploy ,now you can rename the project and its file as per the business requirement

Template Project To Create Mule Application

 

Sample project: mulesy-api-template-project

  
Thank you for taking out time to read the above post. Hope you found it useful. In case of any questions, feel free to comment below. Also, if you are keen on knowing about a specific topic, happy to explore your recommendations as well.
 
For any latest updates or posts on our website, you can follow us on LinkedIn. Look forward to connecting with you there.


Share this:
Subscribe
Notify of
guest
1 Comment
Oldest
Newest Most Voted
Inline Feedbacks
View all comments
Rainer
Rainer
3 years ago

unable to import the project. got following exception in studio 7.8.0

Failed to resolve 723f1f66-b2a0-424f-9245-0db39e66f475:mulesy-api-template:1.0.0 (hover for more details or open this problem’s Properties)
Resolving dependency 723f1f66-b2a0-424f-9245-0db39e66f475:mulesy-api-template found the following exceptions:
org.eclipse.aether.resolution.DependencyResolutionException: Failed to collect dependencies at 723f1f66-b2a0-424f-9245-0db39e66f475:mulesy-api-template:zip:raml:1.0.0