cancel
Showing results for 
Search instead for 
Did you mean: 

Forms or real content types?

huima
Champ in-the-making
Champ in-the-making
Hi,

I've been really trying to get my head around different ways of creating and managing content in Alfresco - and as far as I can tell, the two ways to do anything at the moment is to create either new content models through xml-configuration or use the XForms facility to create xml documents based on schema.

Could someone elaborate on what are the major usecases for each and or the downsides to use forms compared to real content types?

As far as I can tell, this is how everything goes for conten models:
- Content models are little bit more complex to define, requires Alfresco-specific knowledge
+ all the features ( aspects etc. ) are available, search works also on property level
- requires configuration on the webclient etc.
+ linking to other objects through properties

And for forms:
+ easier to create
- modeling little bit limited, but based on xml schema - so common knowledge and skills
+ aspects work(?)
- search only to the xml document and common properties
- templates work only in wcm
- no validation mechanisms(?)
- linking to other other content items?

Therefore forms would be really good choise for records management etc. where programs produce numerous xml documents and/or users will instantiate workflows / edit these records in webclient.

In web content management scenarios forms are a good fit to create content - either small snippets / pieces of data that gets patched together to form a full page, or as a full content page that will be shown through a template.

At the moment I would have a very good usecase for this web scenario, but would not want to use all the features of WCM as it is still very much unknown product to me. Basicly I believe I would just need forms to create xml content and ability to easily preview content through template. In my usecase content editors would create content in webclient - and content would be served through webscripts to a frontend. Workflow would be managed in different folders, if even needed at all. I'm just thinking whether there are some things that I don't know yet that I should know before implementing a demo with forms.

Any thoughts?
3 REPLIES 3

pmonks
Star Contributor
Star Contributor
Could someone elaborate on what are the major usecases for each and or the downsides to use forms compared to real content types?
Originally the forms functionality was implemented to support the WCM use cases, where a "metadata outside of files" model is inappropriate (due to filesystem deployment - most filesystems have no notion of metadata - all they know about are folders and files).

It was quickly realised that there was no reason this functionality couldn't be used on the DM side as well, to facilitate the production of XML content.  This functionality was enabled on the DM side of Alfresco in v2.9 (it had been available in Web Projects since v2.0).

- modeling little bit limited, but based on xml schema - so common knowledge and skills
XML Schema is a more powerful modeling language than the Alfresco content modeling language (aspects / types etc.).

- search only to the xml document and common properties
More sophisticated XML searching can be enabled via XML Metadata Extraction (http://wiki.alfresco.com/wiki/Metadata_Extraction#XML_Meta-data_Extractor_Configuration_for_WCM).

- no validation mechanisms(?)
Many native XML Schema constraints are supported by the forms functionality, and that's generally more powerful than the validation supported by the Alfresco content modeling language.

- linking to other other content items?
For Web Forms (WCM forms) the xs:anyURI XML Schema data type is used for this purpose, but I don't believe this is available in DM forms.

Basicly I believe I would just need forms to create xml content and ability to easily preview content through template.
Preview will be difficult to support with the DM repository, since it doesn't provide sandboxed content production and review (the ability to make and review changes before promoting them to an approved, "ready to be delivered" state).

In my usecase content editors would create content in webclient - and content would be served through webscripts to a frontend. Workflow would be managed in different folders, if even needed at all.
If you elect to use the DM repository, this process won't support controlled (ie. workflowable) editing or deletion of content, since both of these operations depend on sandboxed content production and review ala WCM.

Cheers,
Peter

stevewickii
Champ in-the-making
Champ in-the-making
This Thread was very helpful.  Thanks Peter and huima!

About Workflows, couldn't you set up Business Rules for Spaces, and provide workflow for XML content without WCM?

About Viewing XML as HTML through Freemarker templates, couldn't you use the "Custom Template" on the Content Details page to preview XML content as HTML without WCM?

Correct me if I'm wrong.  We are using Alfresco DM without WCM to serve web content via the URL Addressability services documented here: http://wiki.alfresco.com/wiki/URL_Addressability, http://wiki.alfresco.com/wiki/HTTP_API, and http://wiki.alfresco.com/wiki/Web_Scripts_Examples.

I hope this helps.

Stephen

pmonks
Star Contributor
Star Contributor
That model can work, provided you don't need some of the features that are only available in WCM, including:
  • Sandboxed content production

  • Deployment (allowing physically separate authoring and delivery environments)

  • Full version history of the site (for audit and rollback purposes)

  • In-context preview (preview of content as it will appear once published to the site)
As you've discovered some WCM features can be emulated (to a greater or lesser extent) in the DM repository, but the ones listed above (amongst others) are difficult to emulate.

Cheers,
Peter