Red Hat Bugzilla – Bug 107944
Publishing fails if a live item ends up in the publishing queue
Last modified: 2007-04-18 12:58:45 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.4) Gecko/20030701
Description of problem:
cms.lifecycle.PublishLifecycleListener.java asserts that it only operates on
draft or pending versions. However, there are some situations (involving
auto-publishing) in which a live item could end up in the publishing queue.
This causes publishing to die with an assertion error.
There is no need for the assertion. The promotePendingVersion() method (called
by the PublishLifecycleListener) is smart enough to do the right thing if it's
passed an already-live item. See the attached patch for a solution to the problem.
Version-Release number of selected component (if applicable):
Steps to Reproduce:
1. Update an item from pending to live while it's in the publishing queue.
Actual Results: Assertion error, item does not get published correctly (it
never becomes the "liveVersion" of it's draft item).
Expected Results: No assertion error, item does get published correctly.
Created attachment 95468 [details]
This removes the assertion that the item is draft or pending, and treats a live
version the same as a pending version. ContentItem.promotePendingVersion()
does the right thing in either case.
Adding as blocking the 6.0.1 tracking bug, because it's required for a client
(they're already using the patch, and we'd *really* like to get them onto a
fully supported release).
merged on 6.0.x (38222) and dev (38422)
actually, it is change 38411 on dev