AnsweredAssumed Answered

Adding Custom metadata dynamically through Java Found API

Question asked by pramodkhare on Aug 14, 2012
Latest reply on Aug 20, 2012 by jpotts
I am new to Alfresco development. So please need help with this.

Hi currently I am developing web-UI in ExtJS for Alfresco 4.0 using Java Foundation API. Our total application is really big and we want to build a Document Mgmt Module, so we are using Alfresco at backend as doc-repository.

Basically, I am creating a new ExtJS UI which will internally connect with Alfresco Java Foundation API services. (i.e. ExtJS UI –> Struts Controller Action classes – > Some Custom/helper Classes—>Alfresco Java Services), we will be using Alfresco in embedded deployment mode.

I have a doubt - I want to add as many custom-metadata fields to a documents as user wants, I don't want to change Content Model.

From what I know is, we can achieve above feature by dynamically adding Aspects to document, and these aspects will have properties.

But my question is how to create these aspects dynamically, through java Foundation API.
As I am not using Alfresco-Explorer or Share as my UI, I am just using Core repository.

I know there are few approaches for Alfresco Explorer like adding new content model xml in alfresco/extension folder, or adding new aspect xml to this folder and restarting server. But I don't have that here.

I want to create a new aspect dynamically through Java Foundation API, and without server restart.

Any input is appreciated. If my approach is wrong then please suggest what should be the correct one.
If this query is already been raised by someone pls let me know that post's url.
ANY ANY HELP IS REALLY APPRECIATED.

Thanks

Outcomes