From Venus to Mars Developer land Real world
Maven Alfresco SDK is fun! -Pamp-to-war Alfresco AMP Archetype Share AMP Archetype
What about deployments? Real world has environments … … and integrated systems TES T PREPRO TESTPREPRO
REPO SHARE TEST + PRE + PRO Properties everywhere INT 1 INT 2 INT 3 INT 1 INT 2 INT 3
Shared properties REPO SHARE
Alfresco Repo properties alfresco-global.properties Packaging this file inside AMP module Or including new entries in Alfresco shared folder original file No possibility to configure it by environment
Alfresco Share properties No visibility for resources in shared alfresco-global.properties Custom properties files or custom messages files No possibility to configure it by environment No possibility to share props with repo
TEST PRE PRO Our approach Maven Alfresco SDK to the rescue profiles properties-maven-plugin maven-antrun-plugin TEST PRE PRO TEST PRE PRO AMP
TEST PRE PRO Our approach Maven Alfresco SDK to the rescue profiles properties-maven-plugin maven-antrun-plugin TEST PRE PRO TEST PRE PRO AMP
Properties files external.system.url=test.external-system.com conf/test.alfresco-amp.properties external.system.url=pre.external-system.com conf/pre.alfresco-amp.properties external.system.url=external-system.com conf/pro.alfresco-amp.properties TEST PRE PRO
pom.xml - environments test pre pro
pom.xml – properties plugin org.codehaus.mojo properties-maven-plugin ${user.dir}/conf/${env}.alfresco-amp.properties validate read-project-properties
pom.xml – AntRun plugin maven-antrun-plugin package run Repo + Share
<bean id="externalConnection" class="es.keensoft.alfresco.ExternalConnection”> Using values … or by message property injection amp/config/alfresco/module/service-context.xml
Packaging AMPs for TEST environment available at dist/test/amps dist/test/amps_share $ mvn clean package -Ptest AMP
Real life A sample on where it can be useful eSignature service Server signatureClient signatureVerification
Real life A sample on where it can be useful eSignature service Server signatureClient signatureVerification
# Server signature url.SignatureServer= SignatureServer # Verification url.PolicyManager= licyManager # Client signature url.websigner= Properties conf/pre.alfresco-ast.properties
Use case AMP Repo <bean id="asfSignatureSystem” class="es.aragon.ast.alfresco.sign.impl.external.ASFSignatureSystem" > AMP Share
Final marks Using additional maven plugins to extend Maven Alfresco SDK functionalities Ready to deploy AMPs are produced by environment Version organization can be added to store each distributed AMP
Resources GitHub Blog