incubator-adffaces-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject [jira] Updated: (ADFFACES-466) Issues in change persistence framework code
Date Wed, 25 Apr 2007 10:54:16 GMT



    Attachment: trunk.patch

The changes are as follows

When a child is added with the ID which is already present in the children list. we were removing
the old component and add the new component to the list. Modified it to throw a warning instead
of removing and adding.

Removed the _getChildIndex() method as it is expensive calling the ChangeUtils.getChildForId()
and again indexOf(child) on the Children list and added a static utility method ChangeUtils.getChildIndexForId()
to return the index directly. returns -1 if the insertBeforeId  is not found

Added the method getChildIndexForId() method which takes parent component and insertBeforeId
as parameters and returns the index where the child has to be added, -1 if the insertBeforeId
is not found.

_getUniqueIdForComponent() was evaluating only one namingcontainer in the parent tree which
will fail if two different naming containers has childs with the same ID.
Modified to evaluate all the naming container Ids in the parent tree

synchronized the list used to store the changes

Javadoc change for the getComponentIdsWithChanges() to make it clear that the changes associated
with the viewId in facesContext will be returned

Use ConcurrentHashMap instead of HashMaps for the map to be synchronized.

The Changes were being applied on each restore phase. Modified to apply the changes only on
the Tag creation using getCreated() method on the tag instance

Added the synchronized block around the iteration of changes inside _applyChanges() method.

> Issues in change persistence framework code
> -------------------------------------------
>                 Key: ADFFACES-466
>                 URL:
>             Project: MyFaces ADF-Faces
>          Issue Type: Bug
>    Affects Versions: 2.0.0-incubating-plugins-SNAPSHOT, 2.0.0-incubating-core-SNAPSHOT,
1.0.1-incubating-plugins-SNAPSHOT, 1.0.1-incubating-core-SNAPSHOT
>            Reporter: K SRINATH REDDY
>            Priority: Critical
>             Fix For: 2.0.0-incubating-plugins-SNAPSHOT, 2.0.0-incubating-core-SNAPSHOT,
1.0.1-incubating-plugins-SNAPSHOT, 1.0.1-incubating-core-SNAPSHOT
>         Attachments: trunk.patch
> 1. The datastructures used in the SessionChangeManager are not synchronized
> 2. The _getUniqueIdForComponent() method in BaseChangeManager doesn't return the unique
ID in the component tree instead it returns the unique id in the containing NamingContainer
> 3.  In the AddChildComponentChange, if the child with the already existing ID is added,
the child is being removed and the new child is added which is faulty.
> 4. The changes are applied in each of the restoreView phase of the lifecycle which is
not needed and also impacts the performance. the changes must be applied only on the creation

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message