- Removing file '/WEB-INF/lib/custom-docmodel-platform-jar-1.0-SNAPSHOT.jar' from war - Removing file '/WEB-INF/classes/alfresco/module/custom-docmodel-platform-jar/modifications.install' from war - Removing file '/WEB-INF/classes/alfresco/module/custom-docmodel-platform-jar/module.properties' from war
After this uninstall, if I list the modules, it still contains the module in alfresco.war
You do not need to uninstall old AMPs when you are installing the same AMP (same module ID) that has a newer version. But you do need to remove old versions of the AMP you are updating from the amps/amps_share directories before running apply_amps.
Assuming the version of your AMP is the same or higher, you should be able to copy it into the amps directory, make sure there are no other AMPs in that directory with the same module ID but a different file name (old versions, for example), and then re-run apply_amps. It works every time, quite reliably.
Additionally, when you run apply_amps, it should remove the exploded war file. Check to make sure that is happening. If it doesn't, and Tomcat does not re-deploy, your old AMP will still be in the exploded WAR directory.
It also might be a good idea for you to use versioning to reduce confusion. If your original AMP was 1.0-SNAPSHOT this new version ought to be 1.1-SNAPSHOT (or similar). You can control that by changing the version in your pom.xml files.
I have used apply_amps before in different environment. As far as I could say, It worked great.
But this time, I do not know why it does not seem to work.
Therefore, I did try to uninstall them using the JAR file.
I could not explain the following behavior.
The server is in a stopped state. Then I run the mmt jar with the list command. I see the module installed.
Then I call the mmt jar with uninstall command. It says it removes.
Then I call list again. I still see the module installed.
The only thing I could think of is the user permissions in this machine.
Nowadays, IT offices spawn up these virtual/cloud machines in few minutes.
I am working with a virtual machine on this. In my own physical development machine, apply_amps, or even the JAR way of installing/uninstalling works good.
Has anyone had any similar issue?
C:\alfresco-community>java -jar bin/alfresco-mmt.jar list tomcat/webapps/alfresco.war
Module 'lo-docmodel-platform-jar' installed in 'tomcat/webapps/alfresco.war' - Title: Alfresco Platform/Repository JAR Module - Version: 1.0-SNAPSHOT - Install Date: Mon Oct 22 09:30:09 EDT 2018 - Description: Platform/Repo JAR Module (to be included in the alfresco.war) - part of AIO - SDK 3
C:\alfresco-community>java -jar bin/alfresco-mmt.jar uninstall lo-docmodel-platform-jar tomcat/webapps/alfresco.war - Removing file '/WEB-INF/lib/lo-docmodel-platform-jar-1.0-SNAPSHOT.jar' from war - Removing file '/WEB-INF/classes/alfresco/module/lo-docmodel-platform-jar/modifications.install' from war - Removing file '/WEB-INF/classes/alfresco/module/lo-docmodel-platform-jar/module.properties' from war
C:\alfresco-community>java -jar bin/alfresco-mmt.jar list tomcat/webapps/alfresco.war Module 'lo-docmodel-platform-jar' installed in 'tomcat/webapps/alfresco.war' - Title: Alfresco Platform/Repository JAR Module - Version: 1.0-SNAPSHOT - Install Date: Mon Oct 22 09:30:09 EDT 2018 - Description: Platform/Repo JAR Module (to be included in the alfresco.war) - part of AIO - SDK 3