Bug 109054 - c.a.runtime.Script should verify DB transaction committed (Was: Unable to create a new content item)
Summary: c.a.runtime.Script should verify DB transaction committed (Was: Unable to cre...
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise CMS
Classification: Retired
Component: other
Version: nightly
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: ccm-bugs-list
QA Contact: Jon Orris
URL:
Whiteboard:
Keywords:
Depends On:
Blocks: 111508
TreeView+ depends on / blocked
 
Reported: 2003-11-04 17:53 UTC by Daniel Berrange
Modified: 2007-04-18 16:59 UTC (History)
1 user (show)

(edit)
Clone Of:
(edit)
Last Closed: 2006-09-02 17:27:51 UTC


Attachments (Terms of Use)

Description Daniel Berrange 2003-11-04 17:53:06 UTC
Description of problem:

I am currently unable to create a new content item or folder in CMS.
Upon submitting the 'New Item' / 'New Folder' forms, the browser hangs
indefinitely.

On Oracle, the last query logged in developer support is:

-- ID: #48
-- Duration: 2ms
update cms_items
set ancestors = '61/1307/1306/'
where cms_items.item_id = '1306';

Looking in v$sql, shows an entry for

  update cms_items set ancestors = :1 where cms_items.item_id = :2

Which matches.

On PostgreSQL, the last entry in developer support is


insert into vcx_obj_changes
(obj_id, txn_id, id)
values
('com.arsdigita.cms.contenttypes.Agenda;id:1:9001', '28', '901');

But oddly this *doesn't* match what's in pg_stat_activity:

insert into vcx_operations
(id, change_id, attribute, event_type_id, class_id, subtype)
values
(902, 901, 'com.arsdigita.cms.contenttypes.Agenda', 1, 12, 1)



Version-Release number of selected component (if applicable):


How reproducible:

I can reproduce it 100% on Oracle/PG with 'New Item' or 'New Folder',
others can't :-(

Steps to Reproduce:
1. Go to contet section
2. Choose 'agenda' & submit 
3. Enter title & name & submit
  
Actual results:

Hangs

Expected results:
Creates item

Additional info:

Comment 1 Jon Orris 2003-11-04 21:49:39 UTC
Vadim, can you try to reproduce if possible? If it affects you, you
should run into it in the course of fixing whatever you're working on.


Comment 2 Richard Li 2003-11-04 22:48:49 UTC
scott can't reproduce it with oracle/resin/ibm jdk1.3.

Comment 3 Randy Graebner 2003-11-04 22:56:38 UTC
I cannot reproduce it with oracle 9.2.0.1/resin/ibm jdk 1.3 and RH 7.3

Comment 4 Jon Orris 2003-11-04 23:10:59 UTC
Unable to reproduce. So far have attempted:

RH 8 2.4.20-20.8
 DBS:
  Postgres 7.3.3
  Oracle 9.2.0.2
 JVMS:
  Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2-b28)
  Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1)
  Classic VM (build 1.3.1, J2RE 1.3.1 IBM build cxia32131-20030618
(JIT  enabled: jitc))

RHEL 2.1  2.4.9-e.16
 DBS:
  Postgres 7.3.3
  Oracle 9.2.0.2
 JVMS:
  Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1)
  Classic VM (build 1.3.1, J2RE 1.3.1 IBM build cxia32131-20030329
(JIT enabled: jitc))


Comment 5 Vadim Nasardinov 2003-11-05 02:37:02 UTC
I can create an Article in the "content" content section.

| $ java -version
| java version "1.3.1_09"
| Java(TM) 2 Runtime Environment, Standard Edition (build 1.3.1_09-b03)
| Java HotSpot(TM) Client VM (build 1.3.1_09-b03, mixed mode)
| $ rpm -q postgresql-server
| postgresql-server-7.2.3-5.80


Comment 6 Daniel Berrange 2003-11-05 09:39:31 UTC
Ok, I'm going to strip my server right back to just include core, cms
& agenda (ie removing all the APLAWS apps), to try & isolate the
problem. Don't bother spending more time trying to reproduce until I
find more useful information.

Comment 7 Daniel Berrange 2003-11-05 18:20:49 UTC
The problem turned out to be an Initializer which didn't explicitly
commit the transaction after doing some DB work. THus when time came
to create an item, the DB would block the SQL for creating the item,
until the initializer threads' DB connection had committed.

This isn't a problem when the running of the initializers was lazily
started when the first request arrived, but I add 'load-on-startup'
flag to the web.xml to get around some dodgy edge cases with lazy
initialization.

Recommendation: c.a.runtime.Startup should commit (or, abort, or throw
Exception?) if an initializer fails to close a DB transaction before
allowing control to return from init() events.


Comment 8 Richard Li 2003-11-06 16:15:25 UTC
retargeting for rc0 since no longer blocker

Comment 9 Daniel Berrange 2003-11-07 10:20:08 UTC
Altering summary to relect the cause of the problem & downgrading
severity.


Comment 10 Daniel Berrange 2006-09-02 17:27:51 UTC
Closing old tickets



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