History | Log In     View a printable version of the current page.  
Issue Details (XML | Word | Printable)

Key: UP-726
Type: Bug Bug
Status: Closed Closed
Resolution: Fixed
Priority: Minor Minor
Assignee: Andrew Petro
Reporter: Vincent MATHIEU
Votes: 1
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
uPortal

pushfragment accepted even if priority is bad

Created: 28/Oct/04 08:14 AM   Updated: 05/Mar/08 07:59 AM
Component/s: Aggregated Layouts
Affects Version/s: 2.5.0 M1, 2.6.0 M1, 2.5.1 RC1, 2.5.0 RC1, 2.5.0 RC3, 2.5.0 RC2, 2.5.0 GA, 2.5.1 RC2, 2.5.2 RC1, 2.5.1 RC3, 2.5.1 GA, 2.5.3 RC1, 2.5.2 GA, 2.5.3 RC2, 2.5.3 RC3, 2.5.3 GA, 2.6.0 RC1, 2.6.0 RC2, 2.5.3.1, 2.6.0 GA
Fix Version/s: 2.5.4, 3.0.0-M5, 2.6.1 RC1

Original Estimate: Unknown Remaining Estimate: Unknown Time Spent: Unknown
File Attachments: 1. Text File 242_pubfragment_priority.txt (2 kb)
2. Text File FragmentLoaderPatch.txt (2 kb)
3. Text File patch (2 kb)
4. Text File patch25.txt (4 kb)


Bugzilla Id: 1760


 Description  « Hide
with uPortal 2.3 and 2.4 :

If I make a mistake in a pushfragment, for example :
<restriction path="local" name="priority" value="20000-10000"/>
instead of
<restriction path="local" name="priority" value="10000-20000"/>
(fragment developers in fragments.xml)

ant pubfragments accepts the file, the value "20000-10000" is written in
up_layout_restrictions table.

Then, the users layout managment is disorganized, even if I repair my mistake in
fragment.xml and republish it.

I think pubfragments must control fragment coherence before publishing in database.

 All   Comments   Work Log   Change History      Sort Order:
David Grimwood [03/Nov/04 01:32 PM]
Created an attachment (id=122)
Patch to check priorities

Added following block of code to check if valid priorities were entered in
fragments.xml:
String priority = ai.getValue("value");
StringTokenizer st = new StringTokenizer(priority, "-");
if (st.countTokens() == 2){
String minPriority = st.nextToken();
String maxPriority = st.nextToken();
if (maxPriority.compareTo(minPriority) < 0){ System.out.println("ERROR: Invalid priority. Check priorities to ensure they are valid."); System.exit(1);}
}


Julien Marchal [08/Nov/04 05:55 AM]
Created an attachment (id=124)
Add new test on priority

I've tested the first patch and this patch work fine.
I've added 2 new tests on the priority :

  • not null
  • not only one integer (like value="1")

Andrew Petro [19/Apr/05 10:02 AM]
This patch doesn't appear to be making the milestone. Pushing back.


Andrew Petro [18/Jul/05 01:56 AM]
Patch against uP 2.5. Checks for priority restriction ranges being non-empty, integer ranges.

Brad Johnson [05/Aug/05 04:36 PM]
Hey Andrew,

So what's the status on this? Is the patch good?


Andrew Petro [29/Sep/05 02:38 PM]
Lost context on this issue. Will have to spin this one up again for a future release.

Brad Johnson [08/Sep/06 12:37 PM]
How about we push this issue to 2.5.4.

Andrew Petro [20/Aug/07 03:52 PM]
Patch against 2.4.2

Andrew Petro [20/Aug/07 04:16 PM]
Committed to 2-4-patches, 2-5-patches, 2-6-patches, and HEAD, after validation on 2.4.2 ALM exploratory branch.

Andrew Petro [20/Aug/07 05:06 PM]
Fixed in 2-4-patches, 2-5-patches, 2-6-patches, and HEAD following verification in 2.4.2 exploratory branch.