Import Content into Publisher
These are exciting times with Aqualogic (ALI) and its direction as a Portal technology after Oracle’s acquisition of BEA Systems. Some of our ALI clients have decided to migrate off ALI’s Content Management System (CMS), Publisher, and adopt a different platform; e.g. Adobe Contribute. While others are embracing the new Portal CMS Web Center Interaction stack, more specifically, Universal Content Management (UCM) as a Publisher alternative as they migrate from their existing CMS; e.g. Dynamic Site Framework. Each organization has its unique set of requirements and IT governance that define its decision. But, under any circumstances, the task of migrating content into Publisher or out of Publisher doesn’t have to be a manual or laborious task.
Since the Portal’s inception during Plumtree days, a set of APIs were provided to programmatically interact with the underlying Portal objects. The API’s name might have changed through the product’s evolution – Enterprise Development Kit 5.x (EDK) during Plumtree days, Interaction Development Kit (IDK) 6.x during the portal’s short lived years with BEA and it seems that Oracle will retain the IDK name as it just prefixed it with “Oracle WebCenter” and just changed the version numbering to 10.x Yet, the concept remains unchanged: a set of interfaces for Portal objects – portlets, documents, projects, folders, communities, security groups, etc.)
With that said, we compiled a high level example of how to programmatically import content items from an external CMS to UCM/Publisher. In a subsequent example we will address how to export content items from Publisher/UCM to HTML and then load these to a target CMS while leveraging its intrinsic API set.
//initially we want to establish a remote session to the portal where soapConnectionURL is web service end point
IRemoteSession remoteSession = RemoteSessionFactory.getExplicitLoginContext(
new URL(“http://YourPortalserver/ptapi/services/QueryInterfaceAPI”), yourUserName, yourPassword);
IContentFactory contentFactory = remoteSession.getContentFactory();
// get the required publisher object managers from IContentFactory
folderManager = contentFactory.getFolderManager();
contentItemManager = contentFactory.getContentItemManager();
propertyManager = contentFactory.getPropertyManager();
presentationTemplateManager = contentFactory.getPresentationTemplateManager();
dataEntryEntryTemplateManager = contentFactory.getDataEntryTemplateManager();
// create a text property to store HTML content
ITextBlockProperty textBlockProperty = propertyManager.createTextBlockProperty(“htmlTextProperty”, “htmlText”);
IFolder folder = folderManager.getFolderByPath(targetFolderPath”);
// create a presentation template that would use the html property
String templateText = “htmlTextProperty=<pcs:value expr=\”htmlTextProperty\”>unset</pcs:value>\n”;
IPresentationTemplate presentationTemplate = presentationTemplateManager.createPresentationTemplate(folder, “Presentation Template”, templateText);
presentationTemplate.store();
// create a data entry template and attach the newly created presentation template
IDataEntryTemplate dataEntryTemplate = dataEntryTemplateManager.createDataEntryTemplate(folder, “Data Entry Template”);
dataEntryTemplate.addProperty(textBlockProperty);
dataEntryTemplate.attachPresentationTemplate(presentationTemplate);
dataEntryTemplate.store();
//create a content item and set the rich/block text property with the HTML from the source CMS
IContentItem contentItem = contentItemManager.createContentItem(folder, “contentItemNameGoesHere”, dataEntryTemplate);
textBlockProperty.setTextBlockProperty(“Hello <strong><font color=\”#000000\”>World</font></strong>”);
contentItemManager.checkInItem(contentItem, “Initial checkin.”);
// publish the content item
contentItemManager.publishContentItem(contentItem);
The above code sample is a draft for how you can upload an HTML string from a separete CMS into Publisher as a content item, some of these method calls should be refactored outside the main method since, more likely, you’ll be looping through the source CMS content repository. Feel free to ping us if you have any questions.
Thanks.
Any comments on how satisfied clients have been in their transitions from Publisher to other CMS products?
Did they just pull the plug on Publisher completely or do a phased in approach? Any pros/cons to the various products out there, especially in terms of incorporating Plumtree security?
You could make a whole blog series just on case studies of such a change!
Geoff,
Thanks for commenting.
One of our clients considered using a third party CM system and the software cost was reasonable, what was prohibitive was the cost of building the integration of the 3rd party app into the WC stack in addition to the cost of migrating content off Publisher.
You might be aware that Publisher 6.5 has a number of limitations that hinder a content editor’s productivity. Check out our last post on the issues. If you’ve encountered any of these issues, we’d be happy to help. But for the most part, our clients are sitting tight sticking to the Portal stack awaiting the integration with Stellent/UCMS – the product that Oracle is pushing as an ALUI Publisher alternative.
Thanks.
Could you please put some light on how the contents can be extracted from the publisher along with the metadata associated with it.
Sure, we’ll be more than happy to do that. Actually that was our intent: to do some sample 2 way code, that is import content into Publisher as well as export content out of Publisher; though the latter might be a little more involved since we are talking content items, presentation templates, data entry templates, and custom properties. Stay tuned for more info.
Thanks.
Hani
Thanks,
I am very new to Publisher and hardly knows much about it.I have some questions.
Here we are trying to export the contents out of Publisher in case they have to be now managed by some other CMS say UCM. So why do we need to export presentation templates and data entry templates here as the other UCM will have its own mechanism to create the new contents ? Again a question arises that if we will export the published HTML of the contents how one would be able to modify them and make new revisions in the new CMS ?
Please forget the questions if they are not relevant :-)
Thanks
DK
DK,
Thanks for your post and your question is very valid.
So if we’ve got a handful of distinct presentation and data entry templates in our current ALI or Oracle WebCenter Publisher deployment then it makes sense to just manually create these in advance in the target CMS (SharePoint, UCMS, Contribute, etc.) and just export the HTML from Publisher (stored in the long text field in its respective data entry template.) And, during the migration process, upon programmatically creating the content items in their new CMS destination, attach the content items to the equivalent of data entry and presentation templates in the target CMS system. In my view, that would make sense.
Yet, in a large Portal deployment, you might have hundreds of presentation and data entry templates with different custom metadata tags (e.g. keywords, authors, titles, dates, etc.) that you might also need to export along with each content item’s raw HTML. Then, the challenge becomes how to extract these custom properties from the data entry templates and create/map them in the target CMS system. I reckon it becomes a question of “level of effort” as far as which route one should take; i.e. manually create the equivalent of each data entry template in the target system or exert the effort in advance and include the functionality that would extract and map the custom properties in a migration tool.
Thanks.
Hani
Thanks Hani,
This really make sense. I was thinking some thing similar. This will depend on the type of migration one wants to do.
Thanks
DK