Tuesday, January 31, 2012

Content Presenter does not return any documents for a query

If you add a Content Presenter taskflow to your WebvCenter (Spaces) application and want to shown content as a result of a query, it might happen that the query does not return any documents.
Normal procedure would be:
  1. Go to edit mode in the page (CTRL-SHIFT-E)

  2. Click Add Content
  3. From the folder Content Management, select Content Presenter

  4. Close the repository
  5. Click the first edit icon
  6. Click the button Select Content
  7. As Content Source, select Results of a Query
  8. Enter the query criteria and click Preview Results to see... a preview of the results.
Even though you're sure that the selection criteria should at least match one or more content items, the preview remains empty.
No errors show up in either the WebCenter log file or the Content Server log file.

The problem is most likely in the configuration of the Content Server.
If you check the config.cfg from the content server, you probably are missing to directives:
  • SearchIndexerEngineName
  • IndexerDatabaseProviderName
These tell the content server to use the Oracle Text Search features. Without these, the query will not result in any hits.

Change the $DOMAIN_HOME/ucm/cs/config/config.cfg file and add the two following lines:


Save the file and restart both the content server managed server and the WebCenter managed server.

If you retry the Preview results, you should get results.

Sunday, January 29, 2012

Deploying a WebCenter application - Simple

When you have developed your WebCenter application and want to deploy it to a standalone Weblogic server, you can do it in several ways.
First (in an ideal world) you would deploy it to a development environment.
Often, developers have (unlimited) access to the development environment.
A quick way to deploy your WebCenter application is from JDeveloper.
To use this method, you need access to the admin server. This is the reason why you probably cannot deploy this way to test or production environments.

How do we deploy from JDeveloper:

  1. When you're ready for testing the application on a development environment, open the Application menu and select deploy, then your application

  2. Select Deploy to Application Server as we want to deploy it directly and click Next.

  3. If you already created a connection to your admin server, select it and click Next. Then proceed to step 9
    Otherwise, click the + image at the top right hand corner

  4. Enter a name for the connection, e.g. development-server and click Next

  5. Enter the admin username / password for the admin server and click Next

  6. Enter the connection details for the domain, and click Next

  7. Test the connection (you never know) and click Finish

  8. Select the connection and click Next

  9. Select Deploy to selected instances in the domain, select a server (preferably a custom server, otherwise a server with the WebCenter libraries targetted) A safe choice is the WC_Spaces server.
  10. Click Finish

  11. After some time, a Deployment Configuration wizard will popup.
    On the MDS tab, you can select the Metadata Store and the partition within the MDS

  12. On the connections tab you can modify the connection details.
    For different environments, you might have different servers providing different services.
    If you would like to change connections, select the connection and click the pencil icon

  13. Change the connection details and click OK

  14. Finally, click Deploy to deploy your application.

  15. Run the application by going to the URL in the browser:

  16. For deployments using other methods, keep an eye on the blog.