cancel
Showing results for 
Search instead for 
Did you mean: 

How to use old generated amp in new eclipse project

deeps
Champ in-the-making
Champ in-the-making
Hi guys,

I have created one project in eclipse. but i want to use one uploader-plus AMP file in my newly created eclipse project.

so how can i achieve this.

or is there any way to convert that uploader-plus amp file in to jar file.

or if u know any other way, then please suggest me.

my main requirement is i just want to that uploader-plus amp functionality in my newly  created alfresco project.


Please help me


Thanks in Advance

Regards: Deepak
6 REPLIES 6

hiten_rastogi1
Star Contributor
Star Contributor
Hi Deepak,

You can apply the uploader-plus amps in your alfresco installation. Copy the repo-amp in {alfresco_installation_path}/amps folder and share-amp in your {alfresco_installation_path}/amps_share folder, then use the apply_amps.sh(Please see the docs for how to use it) under your {alfresco_installation_path}/bin folder; restart your alfresco. You will be able to see uploader-plus option in Admin Console.

For alfresco installation you can download the community version and install in your local.

Hiten Rastogi
EisenVault

deeps
Champ in-the-making
Champ in-the-making
Hi hitten,

actually its working in that way.

but i wanted do it through eclipse.
i have created all in one project in eclipse.
and i wanted to use that amp in my eclipse project, so can you give me some suggestions to do this??

purohitsumit
Champ in-the-making
Champ in-the-making
Hi Deepak,

have you got success in converting amp to jar file ?
I need to do the same for uploader-plus plugin.

thanks
sumit

deeps
Champ in-the-making
Champ in-the-making
Hi Sumit,

Actually its not working in eclipse, and also we are not able to convert amp to jar.

So I directly put apm's in alfresco installation directory. And over there i am using that functionality.

steven_okennedy
Star Contributor
Star Contributor
Hi deeps,

The AMP is Alfresco's packaging mechanism for a single extension - generally as far as I know they don't support nesting of other AMPs within them, and I've never seen any tools that could could convert one to a useable jar. 

However, it's probably worth asking what your overall end goal is here? I'm assuming you want to have a project that when you build it out pops a fully useable Alfresco war (complete with all the extensions you want built in).

There are a couple of ways you could achieve this:
<ol>
<li>Use multiple Eclipse projects. 1 for any of your customisations that will itself create an amp and another that applies all the amps (included as maven dependencies) you want to the alfresco war and gives you a ready-to-run war file as the output.  This is the standard maven-style approach and is supported by the Alresco SDK with the alfresco-amp-archetype and alfresco-allinone-archetype archetypes. (http://docs.alfresco.com/5.0/concepts/alfresco-sdk-advanced-add-custom-amps.html)</li>
<li>Another option if you want to only deal with a single project, will be to bundle the source code from the external amps into your extension so that everything gets built as a single amp.  Just be sure to check license requirements (and maybe touch base with the owners) of any code you don't own to make sure that this use case is acceptable.  I wouldn't recommend this option as it will be a lot of hassle both up front and if you want to keep the other extensions up to date.</li>
<li>Lastly, you could create your own alfresco war that is preinstalled with the extra amps you want to use, and then use this as your Alfresco dependency.  So as a one off step you apply all the 3rd party amps you want to use and then take the resultant alfresco/share war files and store those as artefacts in your maven repo.  You can then use them as deependencies for your own project.  This approach might take some fiddling with to get working if you're using the Alfresco SDK and will have to be redone any time you upgrade Alfresco</li>
</ol>

Really in my opinion, the 1st option, is the most standard and least problematic and just requires you to create more than project in eclipse.

Regards

Steven

Thank you Steven.

ts really helpful information.

Thanks
Getting started

Tags


Find what you came for

We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.