Upgrade AMP to latest SDK 4.0 version. Issues if artifact name is changed?

cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
kaffi
Active Member II

Upgrade AMP to latest SDK 4.0 version. Issues if artifact name is changed?

Jump to solution

I need to upgrade from Alfresco SDK 2.0 to SDK 4.0. I need to change, the artefact name of the project, because the in the SDK 4.0 included Docker Containers do not allow, capital letters in the image name, which is produced by the maven artefact name. I will install it on a normal tomcat instance and migrate the old data from it. Can the change of the maven artifact name create problems during the upgrade process in a standalone Alfresco 6.1 instance? Such as missing module errors during startup?

Thanks for the information in advance.

Regards

Kaffi

1 Solution

Accepted Solutions
abhinavmishra14
Senior Member

Re: Upgrade AMP to latest SDK 4.0 version. Issues if artifact name is changed?

Jump to solution

As i understand, you are upgrading to SDK 4 from SDK 2.x. Changing the artifact id should not be a problem in your existing code as long as you have used ${project.artifactId} in all the path mappings. 

If you have hardcoded the artifact ID anywhere then it may fail. Try looking into your code and cross check all paths. 

Examples:

Recommended - alfresco/module/${project.artifactId}/messages/bootstrap-patch-messages

Not Recommended: - alfresco/module/my-alfresco-project/messages/bootstrap-patch-messages

Check the module.properties as well.

Recommended: 

module.id=${project.artifactId}
module.title=${project.name}
module.description=${project.description}
module.version=${project.version}

Not Recommended: 

module.id= my-module
module.title=my-project
module.description=some description
module.version=1.0

Also, you might face issue with already installed module. Once the modules are installed, the value is persisted in DB. You might have to fix the already installed modules. 

or use the already installed module id in the module.properties as hardcoded value (not recommended but it would be a workaround).

1 Reply
abhinavmishra14
Senior Member

Re: Upgrade AMP to latest SDK 4.0 version. Issues if artifact name is changed?

Jump to solution

As i understand, you are upgrading to SDK 4 from SDK 2.x. Changing the artifact id should not be a problem in your existing code as long as you have used ${project.artifactId} in all the path mappings. 

If you have hardcoded the artifact ID anywhere then it may fail. Try looking into your code and cross check all paths. 

Examples:

Recommended - alfresco/module/${project.artifactId}/messages/bootstrap-patch-messages

Not Recommended: - alfresco/module/my-alfresco-project/messages/bootstrap-patch-messages

Check the module.properties as well.

Recommended: 

module.id=${project.artifactId}
module.title=${project.name}
module.description=${project.description}
module.version=${project.version}

Not Recommended: 

module.id= my-module
module.title=my-project
module.description=some description
module.version=1.0

Also, you might face issue with already installed module. Once the modules are installed, the value is persisted in DB. You might have to fix the already installed modules. 

or use the already installed module id in the module.properties as hardcoded value (not recommended but it would be a workaround).