You are here

Alfresco SDK 3.0

Alfresco SDK 3.0 is a major update to the SDK and provides several improvements on the previous SDK releases.

The 3.0 release takes advantage of SEMVER, which means that this new release is not directly compatible with the previous releases of the SDK. If you have existing projects that you wish to upgrade to SDK 3.0, refer to our migration guide. The recommended approach is to generate a new project from our archetypes and move your code into place.

What’s new?

Alfresco SDK 3.0 brings a lot of new changes into the way your customizations are built, packaged, run, and tested.

JAR packaging

Since the early days of the SDK, AMPs have been the way customizations were packaged. In SDK 3.0 everything is now packaged as a JAR by default, while the AMPs are still available as an optional assembly. This gives developers much more control over packaging and simple modules can easily be deployed as JARs.


One of the main motivators behind the improved Alfresco SDK 3.0 was to centralize run and integration testing logic in a plugin. This provides much more flexibility in the supported versions. Alfresco SDK 3.0 is compatible with Alfresco One 4.2.x*, 5.0.x, 5.1.x, and Alfresco Content Services 5.2.x.

To change the version you want to test your customization against, simply change <alfresco.platform.version /> and <alfresco.share.version /> along with <maven.alfresco.edition /> .

*A small one line change is required in for 4.2.x support.

Easy upgrades

SDK 3.0 strives to follow SEMVER closely. This means that no breaking changes within a major version.

We will continue to add new functionality and extra configuration options, but in a backwards compatible way.

Upgrading within a major version of the Alfresco SDK 3.0 should be as easy as changing the <version /> in the plugin configuration, or for convenience, all the archetypes have a property defined as <alfresco.sdk.version /> .

Alfresco Maven Plugin

All logic to run Alfresco Platform and Share has been moved out of the profiles and parent pom. The plugin now has a single goal alfresco:run which can be invoked directly.

The Alfresco Maven Plugin has a lot of configuration options to cover many different use cases. It is easy to configure it to use an external database like MySQL, PostgreSQL or enterprise databases. It is also easy to control exactly which webapps should be run, for example, alfresco-platform-jar-archetype comes with the plugin configured to use the H2 database and to start the Alfresco Platform, Solr 4, and Alfresco REST API Explorer.

The plugin also reads properties, like <alfresco.platform.version /> and <alfresco.share.version /> to control which version you want to run with your customization.

Adding third party dependencies (wither AMPs or JARs) is easier than ever, a simple configuration enables you to define which dependencies to install.

Integration testing

The Alfresco Maven Plugin handles integration tests that are executed in the full context of the application, including Solr. Executing mvn integration-test detects if an Alfresco Platform is already running and executes the tests against it, giving developers instant feedback on their tests. If an Alfresco Platform is not currently running, one will be started to execute the tests.

Simplified archetypes

As we have moved to JAR packaging, the previously used alfresco-amp-archetype and share-amp-archetype have now been replaced with alfresco-platform-jar-archetype and alfresco-share-jar-archetype. Also, alfresco-allinone-archetype is provided. The JAR packaging renders a standard Maven JAR structure.

The pom.xml files are simplified as all the previous profiles are now embedded inside the Alfresco Maven Plugin. This provides developers a pretty standard pom.xml, which defines dependencies, properties, and configuration of the Alfresco Maven Plugin.

The All-In-One archetype is much smaller than before. It no longer has the runner or the WAR overlay modules. It contains three modules: platform-jar, share-jar, and integration-tests.

No forced parent pom

SDK 3.0 no longer requires a parent pom in your project. All you need is a standard JAR project and the Alfresco Maven Plugin.

Hot reloading

Alfresco SDK 3.0 supports two different mechanisms of hot reloading:
  • HotSwap Agent (via DCEVM - free and open source)
  • JRebel (commercial)
Note: Spring Loaded is no longer supported.

Sending feedback to the Alfresco documentation team

You don't appear to have JavaScript enabled in your browser. With JavaScript enabled, you can provide feedback to us using our simple form. Here are some instructions on how to enable JavaScript in your web browser.