cancel
Showing results for 
Search instead for 
Did you mean: 

Serving Alfresco documents via WCM

fschnell
Champ in-the-making
Champ in-the-making
Hello,

we would like to build an Intranet site using Alfresco WCM. Amongs other things this site shall serve documents which are stored in the Alfresco document management store. What we would need is that the WCM always serve the latest (published) version of a document. We would use the Intranet as a catalogue to reach some documents. The actual documents may be stored in a variety of spaces.

I am hearing contradicting statements whether that is possible or not.
As Alfresco claims to be an ECM I would assume that this scenario is possible. Is it?

I also heard, that the Alfresco CMS search would not be able to include the WCM store and vice versa for searches. Is that true?

Thanks
Frank
3 REPLIES 3

kvc
Champ in-the-making
Champ in-the-making
Yes, this is a great use of Alfresco.

One approach would be to set-up a simple document promotion or publishing process via rules.  You can have a content rule that automatically moves or copies a checked-in document into a "doc library space", where docs promoted into that space from one or more collaboration spaces could represent known, good docs that can be surfaced on the intranet.  This "promotion" can be conditional based on some metadata value set by the user at check-in time (user marks the item "FINAL", for example) and can kick-off advanced workflow, or - better - yet, a simple approval process.

In a web project, you can create a form that allows a publisher to specify which documents to fetch from the doc library, how many items to render in that list, sort order, metadata attribute display (show summary, show author, etc.), and more.  That form data (XML) can have a template applied to it which generates a dynamic web page (a JSP, for example).  That JSP can either (a) directly query the repo based on the parameters supplied by the publisher to generate a list of docs in the library or (b) and better still, have a callout to a web script which generates the doc list based on the supplied parameters - meaning you're coding in Javascript and writing Freemarker templates rather than making API calls.

Now, that web script should be generic.  You might want to allow a publisher (using a repeating element in a page form) to add multiple doc lists, and for each doc list specify a different set of docs from the doc library to return.  This is where we'll be heading with web scripts - making them reusable web components that are business user configurable when adding to a page within our WCM system.

Let me know if you've any further question.  But in short you are right:  we can not only do this, but it is definitely a huge part of the value prop of having a combined ECM platform.


Kevin


PS  Please note, when publishing in an Internet or extranet setting, it is
      often preferrable for the doc promotion process to copy a
      transformed rendition (PDF) of the doc to one or more web projects
      (using our pre-built action when creating content rules).  The
      reason for this is that because the rendition is contained within
      the web project, it is snapshoted along with the rest of the assets
      and transactionally deployable to one or more systems that are
      hosting your website outside your firewall or in your DMZ.  For
      intranets, this is less important, as it is often easiest (and their
      are no or fewer security, firewall restrictions) to just serve docs
      straight out of the document library.

fschnell
Champ in-the-making
Champ in-the-making
Thanks for the detailed answer, Kevin.

Any word regarding searching from WCM->ECM and vice versa?

Idea is to have a search box which allows to find the search term in either place.

Frank

kvc
Champ in-the-making
Champ in-the-making
Yes.  When you search, you search a store.  Presently, the entire hierarchy of spaces in Alfresco is considered a single store (in the near future, we will support multiple stores here for purposes of scalability, firewalling of content between different business units or organizational groups, and stronger local delegated administration and server configuration).  Each sandbox within a WCM production environment is likewise considered its own store (each sandbox is actually it's own independent Subversion-style repo, supporting versioning of a hierarchy of files and folders.  For a WCM production model, it just so happens that a set of these sandboxes - authoring sandbox - set a development and preview context against another known sandbox - the web project staging sandbox - and have a promotional workflow that synchronizes the underlying repos when change sets need to be promoted.  Really though, it's just a forest of repository that can compare themselves and synchronize themselves with one another - much more flexibility under the covers than what you see in the web app).

So, if you want to search across all your websites (say you have an Internet and two Intranet sites) and all your business documents, you'd need to use execute a search against the spaces stores and the staging store for each of your three websites.   In your presentation layer, you can choose whether to concatenate or maintain a separation between the different result sets.

You can read more on the Search API here:

http://wiki.alfresco.com/wiki/Search

Or, from a Javascript perspective for your web scripts:

http://wiki.alfresco.com/wiki/JavaScript_API#Search_API


Cheers!  Let us know if anymore questions … and do let us know how you get on.  Would love to hear what you wind up producing!


Kevin