---
schema_version: "1"
id: cbe4da33b812e4f8bf272141da96e235e4ffe1b451d680ed1c346874c1b1ed0c
title: "Introduction to Mule 4: Packaging Applications"
collection: mulesoft
version: current
locale: en-us
portal_url: https://docs.salesforce.com/mulesoft/current/en-us/mule-runtime/4.4/intro-packaging.md
canonical_url: https://docs.mulesoft.com/mule-runtime/4.4/intro-packaging
source_site: docs.mulesoft.com
content_type: documentation
content_hash: 21d54a112d2735e9c89f1403b6c52b827b1bb982186e2fa84b80021f20f8218a
description: MuleSoft Documentation Site
release: "4.4"
latest: false
---
---
product: Mule Runtime
version: 4.4
---

# Introduction to Mule 4: Packaging Applications

> For the full documentation index, see: https://docs.mulesoft.com/llms.txt

## Application Structure

There are few important changes to how Mule applications are packaged in Mule 4. Mule applications
are now packaged as a JAR and have a different structure. You can use the Mule Maven Plugin to
easily package your source code into this structure.

<table><colgroup><col> <col></colgroup><thead><tr><th>Location</th><th>Description</th></tr></thead><tbody><tr><td><p><code>META-INF/mule-artifact/mule-artifact.json</code></p></td><td><p>Descriptor for your Mule application (see <a href="#app_descriptor">Application Descriptor</a>).</p></td></tr><tr><td><p><code>META-INF/mule-src/yourapp/</code></p></td><td><p>An optional location for your source code.</p></td></tr><tr><td><p><code>repository</code></p></td><td><p>A repository for all your application’s dependencies in Maven layout. This includes all your connectors for your app. For example, <code>repository/commons-collections/commons-collections/3.2.2/commons-collections-3.2.2.jar</code></p></td></tr><tr><td><p><code>yourapp.xml</code></p></td><td><p>Your Mule XML code.</p></td></tr></tbody></table>

## Application Descriptor

Mule 4 applications include a `mule-artifact.json` file in `META-INF/mule-artifact/`. This describes
your app, configuration settings, the required Mule version, and the class loader configuration.

```json
{
  "configs": ["ch-usage-sync.xml"],
  "redeploymentEnabled": true,
  "name": "ch-usage-sync",
  "minMuleVersion": "4.0.0",
  "requiredProduct": "MULE_EE",
  "classLoaderModelLoaderDescriptor": {
    "id": "mule",
    "attributes": {
      "exportedResources": []
    }
  },
  "bundleDescriptorLoader": {
    "id": "mule",
    "attributes": {}
  }
}
```

### Application Descriptor Reference

<table><colgroup><col> <col> <col></colgroup><thead><tr><th>Attribute</th><th>Value type</th><th>Description</th></tr></thead><tbody><tr><td><p><code>configs</code></p></td><td><p>Array of Strings</p></td><td><p>Set of Mule configuration files.</p></td></tr><tr><td><p><code>redeploymentEnabled</code></p></td><td><p>Boolean</p></td><td><p>Whether modifying the app configuration files will trigger a redeployment.</p></td></tr><tr><td><p><code>name</code></p></td><td><p>String</p></td><td><p>Meaningful name for the app.</p></td></tr><tr><td><p><code>minMuleVersion</code></p></td><td><p>String</p></td><td><p>Minimum Mule Runtime version required to deploy the app.</p></td></tr><tr><td><p><code>requiredProduct</code></p></td><td><p>String</p></td><td><p>Required product type to deploy the app. <code>MULE</code> means that the app can be deployed on the Community Edition (CE) version or the Enterprise Edition (EE) version. <code>MULE_EE</code> means that the app can only be deployed on the EE version.</p></td></tr><tr><td><p><code>classLoaderModelLoaderDescriptor</code></p></td><td><p>Object</p></td><td><p>Descriptor of the classloading model for the app. The <code>id</code> field identifies the mechanism to be used by the runtime to understand how the dependencies and the packages/resources of the app are meant to be used. By default, Mule uses the ID <code>mule</code>, which means that the exported packages and resources from the apps are described in the <code>attributes</code> field, and the dependencies are described in the file <code>/META-INF/mule-artifact/classloader-model.json</code>.</p></td></tr><tr><td><p><code>bundleDescriptorLoader</code></p></td><td><p>Object</p></td><td><p>Descriptor of the app bundle coordinates. The <code>id</code> field identifies the mechanism to be used by the runtime to understand the app bundle coordinates. The default is <code>mule</code> and will load the Artifact Group ID, Artifact ID, and Version from the POM file.</p></td></tr><tr><td><p><code>secureProperties</code></p></td><td><p>Array of Strings</p></td><td><p>Declares the set of configuration properties of the artifact that must be managed as secure in the platform.</p></td></tr></tbody></table>

## Application Versioning

Mule Runtime follows [semantic versioning](https://semver.org/) in all its artifacts. By following
semantic versioning, clients of our APIs can clearly understand what to expect whenever MuleSoft
releases a new version of an asset. For instance, consider the case of Mule connectors. You can
expect bug fixes (and only bug fixes) when a patch version is updated. You can expect new features
in new minor versions. Both of those changes are expected to be backward compatible so that you can
upgrade without any problem. But if MuleSoft updates the major version of the connector, it means
that it was necessary to break backward compatibility to include new functionality or provide a much
better UX.

It is also expected that Mule artifacts (app, domains, policies) follow semantic versioning, so you
might encounter some validations when working with Mule apps. By following semantic versioning,
Anypoint Platform can better understand new assets and provide a better experience. For instance, if
there’s a new major version of a Mule domain, you can expect that there is not going to be, for
instance, the same set of global components defined in it as in the previous major version. So mule
apps that belong to that domain might required to be updated if the new domain is used.

## Mule Maven Plugin

The Mule Maven Plugin in Mule 4 packages your app into the required format and enables you to deploy
it into your target environment. Studio 7 will automatically add the plugin to your `pom.xml`. See
the Mule Maven Plugin documentation for information on how to use it to deploy apps.

> [!IMPORTANT] Domains, policies, Mule artifact plugins (connectors, modules, and so on) all have
> the same structure as Mule apps. Depending on the type of artifact, there might be more or less
> properties in the artifact descriptors (`mule-artifact.json`), but they are all similar and all
> must follow semantic versioning.

## See Also

- [Package Mule Apps using the Mule Maven Plugin](https://docs.mulesoft.com/mule-runtime/4.4/mmp-concept#mule-application-packaging)

- [Deploy Mule Apps using the Mule Maven Plugin](https://docs.mulesoft.com/mule-runtime/4.4/mmp-concept#mule-application-deployment)
