Cannot Login To BCC

Business Control Center Error

Sometimes I can’t login to the BCC. Usually when that happens I see errors like this in the logs.

page seeing error: /atg/templates/page/html/BizUIPageTemplate.jsp
error message: null

java.lang.NullPointerException
   at org.apache.pluto.factory.PortletObjectAccess.getRenderRequest(PortletObjectAccess.java:36)
   at org.apache.pluto.PortletContainerImpl.portletLoad(PortletContainerImpl.java:197)
   at atg.portal.portletstandard.services.ATGContainerService.portletLoad(ATGContainerService.java:202)
   at atg.portal.servlet.GearRequestDispatcherImpl.dispatch(GearRequestDispatcherImpl.java:397)
   at atg.portal.servlet.GearRequestDispatcherImpl.include(GearRequestDispatcherImpl.java:438)
   at atg.portal.servlet.GearRequestDispatcherImpl.include(GearRequestDispatcherImpl.java:453)
   at atg.portal.framework.taglib.IncludeTag.doEndTag(IncludeTag.java:162)
   at atg.portal.framework.taglib.elwrap.IncludeTagWrapper.doEndTag(IncludeTagWrapper.java:36)
   at org.apache.jsp.templates.layout.html.BizUILayout_jsp._jspx_meth_paf_005finclude_005f0(BizUILayout_jsp.java:708)
   at org.apache.jsp.templates.layout.html.BizUILayout_jsp._jspService(BizUILayout_jsp.java:263)
....stack trace CROPPED after 10 lines.
ATG Business Control Center 
© ATG 2005-2011

When this happens I first try clearing my cookies and then reloading the BCC login page.

When that doesn’t work I then remove the tmp and work directories.

$ cd /opt/jboss/home/server/merch
$ rm -rf tmp work

Then I restart the BCC and things seem happy again.

Fixing Existing Repository ID Errors

I was feeling part of the scenery. I walked right out of the machinery. | Flickr

I was feeling part of the scenery. I walked right out of the machinery. by Neal.

The other day I was trying to create a page repository item using the BCC when I got an error saying it could not create the item. Looking in the logs I saw this exception.

16:13:59,909 ERROR [RepositoryAssetService]
atg.repository.RepositoryException: createItem() was called with an existing ID : '3100007' for type 'page'. Use getItemForUpdate() instead.
        at atg.adapter.version.VersionRepository.createItem(VersionRepository.java:1903)
        at atg.adapter.version.VersionRepository.createItem(VersionRepository.java:1125)
        at atg.remote.assetmanager.editor.service.RepositoryAssetServiceImpl.doCreateAsset(RepositoryAssetServiceImpl.java:476)
        at atg.remote.assetmanager.editor.service.AssetServiceImpl.createAsset(AssetServiceImpl.java:331)
        at atg.remote.assetmanager.editor.service.AssetEditorService.createAssetAndLink(AssetEditorService.java:555)
        at atg.remote.assetmanager.editor.service.AssetEditorService.createAsset(AssetEditorService.java:508)

The problem was the ID generator was producing ID’s that already existed in the database. This sometimes happens when things are imported into the BCC.

To fix this problem do the following.

  1. Look for the row in the das_id_generator table which has the item descriptor that is causing the error.
  2. Change the seed value (typically upwards) or put a prefix or suffix on it.
  3. Restart the server.

In this case I ended up running this SQL to fix the existing ID error:

UPDATE DAS_ID_GENERATOR SET PREFIX = 'pg_' WHERE id_space_name = ‘page’;

Clearing Out BCC Projects

Clean Up or You're Out! :Brooklyn Street Sign | Flickr

Clean Up or You’re Out! :Brooklyn Street Sign by emilydickinsonridesabmx

This may not be the best way to clear out your BCC projects but it’s quick.

delete from epub_pr_history;

delete from epub_project;

delete from epub_proc_history;

delete from epub_proc_taskinfo;

delete from epub_ind_workflow;

delete from epub_process;

delete from avm_asset_lock;

delete from avm_workspace;