Document migration
As of version 6.1, Document Manager is no longer available in WebSphere Portal. Before migrating data, you will need to replace web content previously stored as documents in a document library with either file resource components or file resource elements stored in authoring templates, content items or site areas.
Saving documents as file resource elements and components
To save documents as file resource elements or components you:
- identify which documents need to be saved as file resource elements or components by installing and running the document list portlet on version 6.0 server.
- open document library on version 6.0 server and save documents to a temporary directory.
- create file resource elements and components on version 6.0 server and upload documents from the temporary directory.
Install the document list portlet
Before migrating documents install the document list portlet on version 6.0 server. The document list portlet is used to identify document manager elements and components, and what items reference document manager elements and components. This will assist you to convert documents to file resource elements and components.
- Login to WebSphere Portal as an administrator.
- Go to the Administration view and then Portlet Management.
- Select Web Modules.
- Click Install.
- Click Browse.
- Select the file called ilwwcm-pdmdoclist.war from the $PORTAL_HOME/wcm/prereq.wcm/installableApps folder of version 7.0 server.
- Click Open.
- Click Next.
- Click Finish.
Use the document list portlet
- Create a new portal page and add the document list portlet to the page.
- Select a library to analyze.
- Select an analysis type:
Document Manager components
Display a list of Document Manager components in the selected library. A list of items that reference each Document Manager component are also listed. You will need to replace each Document Manager component with a file resource component, and replace each reference to the Document Manager component with a reference to the new file resource component.
Document Manager elementsDisplay a list of sites, site areas, content items and authoring templates that contain a Document Manager element in the selected library. You will need to replace each Document Manager element with a file resource element. This option may take longer to run than the options as it will search every site, site area, content item and authoring template in the selected library.
Document Manager tagsDisplay a list of presentation templates and components that contain a Document Manager element tag. You will need to replace each Document Manager element tag with an element tag pointing to the file resource elements you created when using the "Document Manager elements" option.
Document replacement strategies
There are three ways to replace the use of Document Manager documents:
As a file resource componentThe simplest way to replace Document Manager documents is by importing them into file resource components. The strategy is suitable if you only need to display a basic set of file attributes, or to create a downloadable link to a file.
As a file resource element stored in a site area or content itemThe benefit of this strategy is that you can add elements to an item to store additional metadata not available in a file resource component. Downloadable links can only be used when displaying content from a site area or content item. You cannot create a download link directly to the file resource element.
As a file resource component referenced in a site area or content item using a component reference elementThis strategy combines elements of the first two strategies. Additional metadata can be stored in a site area or content item, and downloadable links can be used both when displaying content from a site area or content item, and by linking directly to the file resource component.
Storing images:In some cases, where you don't want users to be able to download an image file but only want to render an image on a page, you could store the image in an image component or image element instead of using a file resource component or element.
Create a download link to a file resource component
If you store a document in a file resource component, you use a component tag to create a download link:<a href="<component name="FileResource" />">Link Text</a>This code can be referenced in any presentation template, component design or element design.
Create a download link to a file resource element
If you store a document in a file resource element, you use an element tag to create a download link. For example, to create a link to a file resource element stored in a content item:<a href="<element type="content" context="current" key="FileResource" />">Link Text</a>This link will only be displayed when the currently displayed content item contains a file resource element named "FileResource".
Displaying the attributes of file resource components and elements
Previously it was possible to display a range of attributes of documents stored in document libraries when displayed within web pages. When you migrate documents to file resource components or elements not all attributes will be available. You will need to create own attribute fields in an authoring template, content item, site area to replace the document attributes:
Document attribute File resource component File resource element stored in a site area, authoring template or content item authors Add authors to the author field in the file resource element. Use a Property tag to render the authors. Add authors to the author field in the authoring template, content item, or site area. Use a Property tag to render the authors. categories Not available. You will need to create a taxonomy to replace the categories used by old document library. You then enable profiling and then assign a category to the site area or content item that the file resource element is stored in. Use a Property tag to render the profile of the content item or site area.
created Use a historycmpnt tag to render the creation date of the file resource component. Use a historycmpnt tag to render the creation date of the content item or site area. creators Use a historycmpnt tag to render the creator of the file resource component. Use a historycmpnt tag to render the creator of the content item or site area. data Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
dataLength Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
dataMimeType Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
description Enter text in the description field of the file resource element. Use a Property tag to render the description. Enter text in the description field of the authoring template, content item or site area. Use a Property tag to render the description. drafts Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
effectiveDate Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
hidden Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
id Use a Property tag to render the ID of the file resource component. Use a Property tag to render the ID of the content item or site area. isdoc Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
label Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
language Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
lastModified Use a historycmpnt tag to render the last modified date of the file resource component. Use a historycmpnt tag to render the last modified date of the content item or site area. lastModifier Use a historycmpnt tag to render the last modifier of the file resource component. Use a historycmpnt tag to render the last modifier of the content item or site area. mimeType Use a component tag to display the mime type of the file. Use an element tag to display the mime type of the file. owners Add owners to the owners field in the file resource element. Use a Property tag to render the owners. Add owners to the owners field in the authoring template, content item or site area. Use a Property tag to render the owners. path Use a pathcmpnt tag to render the path to the file resource component. Use a pathcmpnt tag to render the path to the content item or site area. permission Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
proxy Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
renditions Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
revision Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
searchable Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
size Use a component tag to display the size of the file. Use an element tag to display the size of the file. systemCreated Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
systemLastModified Not available. Not available. You can use an element, such as a text element, to store this information and then use an element tag to display this information.
title Enter text in the title field of the file resource element. Use a Property tag to render the title. Enter text in the title field of the authoring template, content item or site area. Use a Property tag to render the title.
Displaying the content of file resource components and elements
File resource elements and components cannot be dynamically converted to HTML and displayed on a web page. The following strategies can be used to display the contents of a document as HTML:
Convert document to HTML and store it as an HTML component
- Go to the document library on 6.0 server and save document to file system.
- Open the file and convert it to HTML. For example, if you are converting a Microsoft Word file, open it in Microsoft Word and save it as HTML.
- Create a new HTML component on 6.1 server and import the HTML you created in step 2 using the Import button in the HTML component.
- Use a component tag to reference the HTML component in any presentation template, component design or element design. For example:
<component name="ComponentName" />
Images in HTML:
If HTML contains images you will need to import images into HTML component separately using the button. Alternatively, you could use a Rich Text component instead of an HTML component and the images will automatically be imported when you import HTML.
Convert document to HTML and store it as an HTML element
- Go to the document library on 6.0 server and save document to file system.
- Open the file and convert it to HTML. For example, if you are converting a Microsoft Word file, open it in Microsoft Word and save it as HTML.
- Create a new HTML element in a site area or content item on 6.1 server and import the HTML you created in step 2 using the Import button in the HTML element.
- Use an element tag to reference the HTML element in any presentation template, component design or element design. For example:
<element type="content" context="current" key="ElementName" />
Images in HTML:
If HTML contains images you will need to import images into HTML element separately using the button. Alternatively, you could use a Rich Text element instead of an HTML element and the images will automatically be imported when you import HTML.
Use a third-party application to dynamically convert a file to HTMLUse code stored in a JSP component to call a third-party application that can dynamically convert the file to HTML before rendering on a page. In this case you would reference file resource element or component in some JSP and use the third-party application to convert the file resource to HTML before it is rendered.
Post migration alternative
You can also use the document list portlet on 7.0 server. This allows you to migrate data first, and then retrospectively replace documents on new server. When migrated:
- Documents stored in document libraries in previous versions of WebSphere Portal will not be migrated.
- Document Manager elements and components are migrated unchanged, but you can no longer select or replace documents.
- Web content tags that reference Document Manager elements or components are left unchanged in presentation templates and element designs. When rendered on a web page, a message will be displayed showing the basic information of the document previously referenced.
Parent
Prepare for migration from v6.0.1.x