Bug 104909 - application fault when creating template
application fault when creating template
Status: CLOSED WONTFIX
Product: Red Hat Enterprise CMS
Classification: Retired
Component: other (Show other bugs)
nightly
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Daniel Berrange
Jon Orris
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2003-09-23 10:40 EDT by Mark Watson
Modified: 2007-04-18 12:57 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-09-05 13:36:28 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Mark Watson 2003-09-23 10:40:25 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686) Gecko/20030807 Galeon/1.3.5

Description of problem:
On the nightly build for 09-21-2003 (and on 09-17-2003 which I previously had),
creating a template throws the following error ... (information from the ccm log): 

WARN  dispatcher.CMSPage - Failed to load content item 500012003-09-23
13:35:03,560 [0][9]] 
WARN  search.SearchTransactionListener - Search save event failed for object
[com.arsdigita.cms.Template:{id=50001}]java.lang.ClassCastException:
com.arsdigita.cms.Template at
com.arsdigita.cms.search.ContentPageMetadataProvider.getTypeSpecificInfo(ContentPageMetadataProvider.java:62)
       at
com.arsdigita.search.lucene.DocumentObserver.onSave(DocumentObserver.java:63)  
     at
com.arsdigita.search.SearchTransactionListener.beforeCommit(SearchTransactionListener.java:66)
       at
com.arsdigita.persistence.TransactionContext.fireBeforeCommitEvent(TransactionContext.java:181)
       at
com.arsdigita.persistence.TransactionContext.commitTxn(TransactionContext.java:88)
       ... etc

2003-09-23 13:35:03,799 [0][9]] 
FATAL logging.ErrorReport --*-*-*-*-*- 
Begin Error Report -*-*-*-*-*--*-*-*- 
ACS Error Report Code: x.x.x.x:2554aa10:f7ce720ff4 -*-*-*--*-*-*- 
Message: Unable to send all events to database because these required properties
are null: [com.arsdigita.search.lucene.Document:{id=50001}].title -*-*-*-

Version-Release number of selected component (if applicable):
ccm-core-6.1.0.AUTO.09.21.2003-1-bin.zip

How reproducible:
Always

Steps to Reproduce:
1. Go to content types, choose article
2. Add a template
3. Fill in values and save
    

Actual Results:  See Description
Note the template then appears against the content type as created, but attempts
to edit it throw the same error.

Expected Results:  Template created and no error thrown.

Additional info:

Reported to list, 2 responses as follows:

RESPONSE 1 - Vadim Nasardinov <vadimn@redhat.com>:
Looks like you might want to file a bug report on this one. The method
getTypeSpecificInfo assumes it can cast DomainObject to ContentPage:

$ nl -ba ContentPageMetadataProvider.java | head -n 65 | tail -n 5    
61      public String getTypeSpecificInfo(DomainObject dobj) {    
62          ContentPage item = (ContentPage) dobj;    
63          return ContentItem.LIVE.equals(item.getVersion()) ?    
64              ContentItem.LIVE : ContentItem.DRAFT;    
65      }

You found a situation where this is not the case.

RESPONSE 2 - Daniel P. Berrange <berrange@redhat.com>
- reply to response 1
In fact there shouldn't even be a search object registeredagainst the
c.a.cms.Template object type, since its an internal type for managing JSP
templates rather than content per se.
Comment 1 Richard Li 2003-09-23 17:59:09 EDT
dan, should this be you?
Comment 2 Daniel Berrange 2003-09-24 09:21:08 EDT
Yep, its my mistake. When registering search metadata adapters in the XML
content type loader it was not taking care to filter out those with the
'isInternal' flag set & those which are not subclasses of ContentPage. This is
fixed in p4 36296.
Comment 3 David Lawrence 2006-07-17 23:32:55 EDT
QA_READY has been deprecated in favor of ON_QA. Please use ON_QA in the future.
Moving to ON_QA.
Comment 4 Jon Orris 2006-09-05 13:36:28 EDT
Closing old tickets



Note You need to log in before you can comment on or make changes to this bug.