Wednesday, November 5, 2014

Where to put an enterprise license file for alfresco-maven-sdk

I've been using the alfresco-maven-sdk version 1.1.1 with community alfresco for quite some time.  Recently, I started using it for enterprise version 4.1.4, and tried several ways to install the license file.  My findings are below.

The following did not recognize and install the enterprise license file
  1. Using the tomcat shared extension location:  The alfresco-maven-sdk has embedded tomcat setup, where only the tomcat context.xml file exists under the tomcat folder.  Creating tomcat/shared/classes/extension/license, and saving the license there didn't work.  For example:
  2. ./alfresco-amp

  3. Using the alfresco extension location inside the amp folder structure:  I figure this didn't work because the amp structure gets overlayed during the deployment process and doesn't "stick around" like a regular external tomcat deployment setup.  For example:

  4. D:\workspaces\cherryshoe\alfresco-amp\src\main\amp\config\alfresco\extension\license

  5. dir.license.external with an relative path to the license file:

    • dir.license.external=tomcat
    • dir.license.external=./tomcat
    • dir.license.external=${} (this is pointing to alfresco-amp/alf_data_dev as specified in the pom file)
Solution - recognized and installed the license file (renamed license file to .installed and can see in log file)
  1. dir.license.external with explicit path:  For example, putting the license file under the root of the alfresco-amp module.  
    • I had hoped I would find a solution where an explicit path to the license folder location could be avoided.  If I have multiple people on my software team, then each person would need to change this value.


  2. dir.license.external with explicit path via property replacement:  For example, putting the license file under the root of the alfresco-amp module.  Then adding a new custom property, we'll call it alfresco.license.location in the pom properties, then using property replacement in the file.  
    • This solution is a little better than the one above, since the pom.xml file *will probably* change less than the

    <!-- custom to pick up alfresco enterprise license location -->
    # enterprise license location

Possible Solutions that I wasn't able to verify
  1. You should also be able to load the license via Share.  Login as administrator, More -> More -> License Descriptor -> Edit -> Click 'Load License' button.
    1. This didn't work for me with Chrome Version 38.0.2125.111 m, Internet Explorer 11.0.9600.17280, or Firefox 33.0.2 (Look at Alfresco 4.1.x supported browsers -
  2. With 4.2 or higher, you should also be able to use the Alfresco Administration Console to upload a license.
Please let me know if you found another way that makes the maven alfresco sdk recognize an enterprise license file.  What questions do you have about this post? Let me know in the comments section below, and I will answer each one.


  1. Hi Judy,

    What happens if you have a property reference with a full path? I don't see that combination.

    Also, can the property come from the, or some properties you control at runtime? Instead of at build time?

  2. Hi Dave,

    Thank you for your suggestion on pulling a property reference with a full path out, that work. I updated the blog with "Solution number 2", which I like better!

    Also, alfresco.war/WEB-INF/classes/alfresco/ file has the following license properties, which could also work for license placement.

    #Directory to find external license
    # Spring resource location of external license files
    # Spring resource location of embedded license files
    # Spring resource location of license files on shared classpath


    1. Great Article. Thank you for sharing! Really an awesome post for every one.

      IEEE Final Year projects Project Centers in Chennai are consistently sought after. Final Year Students Projects take a shot at them to improve their aptitudes, while specialists like the enjoyment in interfering with innovation. For experts, it's an alternate ball game through and through. Smaller than expected IEEE Final Year project centers ground for all fragments of CSE & IT engineers hoping to assemble. Final Year Project Domains for IT It gives you tips and rules that is progressively critical to consider while choosing any final year project point.

      JavaScript Training in Chennai

      JavaScript Training in Chennai

  3. They formed an alliance called Trade Partners Alliance to explore ways to be transparent with quick, reliable, actionable, in-depth product information for the consumer.

  4. There are two methods of setting up a small business, home office network. The first method is to have one main computer as the share point for files and printers file sharing

  5. The increasing importance of technology in every industry continues to drive the need for a diverse group of qualified professionals to manage the implementation and changes in technology. Best Motherboard of 2018

  6. Thank you for some other informative website. The place else may just I get that kind of information written in such a perfect method? I have a venture that I am simply now running on, and I’ve been at the glance out for such info.

  7. A debt of gratitude is in order for your understanding for your phenomenal posting. I'm happy I have set aside an ideal opportunity to see t Easy Traffic School Online California for Traffic Tickets

  8. Up-to-date bloggers and social media influencers make brands regarded thru their superb reviews, often sharing those stories over the mobile network.Managed Services

  9. Wow, What a Excellent post. I really found this to much informatics. It is what i was searching for.I would like to suggest you that please keep sharing such type of info.Thanks Small Business IT Support Toronto

  10. Hello, this weekend is good for me, since this time i am reading this enormous informative article here at my home. נעלי אצבע


I appreciate your time in leaving a comment!