You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Roman S. Bushmanov (JIRA)" <ji...@apache.org> on 2007/06/01 08:03:16 UTC

[jira] Created: (HARMONY-4019) [classlib][beans] Incorect behaviour of BeanContextSupport.add()

[classlib][beans] Incorect behaviour of BeanContextSupport.add() 
-----------------------------------------------------------------

                 Key: HARMONY-4019
                 URL: https://issues.apache.org/jira/browse/HARMONY-4019
             Project: Harmony
          Issue Type: Bug
          Components: Classlib
            Reporter: Roman S. Bushmanov


According to the Extensible Runtime Containment and Services Protocol (v1.0),  if an object that implements BeanContextProxy is added to a BeanContext, than the BeanContextChild returned from BeanContextProxy.getBeanContextProxy() should be also added to that BeanContext. The same is specified for 'remove' operation.

However, Harmony implementation of BeanContextSupport behaves differently. Only the object that implements BeanContextProxy is added in the described case.  To reproduce the issue, please run the testcase listed below.

The expected output is
Context size: 2

But on Harmony the testcase prints
Context size: 1

------------------------------------- Test.java ---------------------------------------
import java.beans.beancontext.*;

public class Test {

    public static void main(String[] args) throws Exception {

        BeanContextSupport context = new BeanContextSupport(); 
        context.add(new MyBeanContextProxy()); 
        System.out.println("Context size: "+context.size());
    }

    static class MyBeanContextProxy implements BeanContextProxy {
    
        private BeanContextChild child = new BeanContextChildSupport();
        
        public BeanContextChild getBeanContextProxy(){
            return child; 
        }
    }

}
--------------------------------------------------------------------------------------

Affected tests:
functional/org/apache/harmony/test/func/api/java/beans/beancontext/TestSizeBeanContext.xml
(see HARMONY-3528)


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


[jira] Commented: (HARMONY-4019) [classlib][beans] Incorect behaviour of BeanContextSupport.add()

Posted by "Nellya Udovichenko (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/HARMONY-4019?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12506177 ] 

Nellya Udovichenko commented on HARMONY-4019:
---------------------------------------------

The bug isn't reproduced after java.beans.beancontext.BeanContextSupport class bugs fix at revision 548642. The regression test 
is included in org.apache.harmony.beans.tests.java.beans.beancontext.BeanContextSupportTest.testAddBCP() (now it is in excluded tests list). Please could anybody close the issue?

> [classlib][beans] Incorect behaviour of BeanContextSupport.add() 
> -----------------------------------------------------------------
>
>                 Key: HARMONY-4019
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4019
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Roman S. Bushmanov
>
> According to the Extensible Runtime Containment and Services Protocol (v1.0),  if an object that implements BeanContextProxy is added to a BeanContext, than the BeanContextChild returned from BeanContextProxy.getBeanContextProxy() should be also added to that BeanContext. The same is specified for 'remove' operation.
> However, Harmony implementation of BeanContextSupport behaves differently. Only the object that implements BeanContextProxy is added in the described case.  To reproduce the issue, please run the testcase listed below.
> The expected output is
> Context size: 2
> But on Harmony the testcase prints
> Context size: 1
> ------------------------------------- Test.java ---------------------------------------
> import java.beans.beancontext.*;
> public class Test {
>     public static void main(String[] args) throws Exception {
>         BeanContextSupport context = new BeanContextSupport(); 
>         context.add(new MyBeanContextProxy()); 
>         System.out.println("Context size: "+context.size());
>     }
>     static class MyBeanContextProxy implements BeanContextProxy {
>     
>         private BeanContextChild child = new BeanContextChildSupport();
>         
>         public BeanContextChild getBeanContextProxy(){
>             return child; 
>         }
>     }
> }
> --------------------------------------------------------------------------------------
> Affected tests:
> functional/org/apache/harmony/test/func/api/java/beans/beancontext/TestSizeBeanContext.xml
> (see HARMONY-3528)

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


[jira] Closed: (HARMONY-4019) [classlib][beans] Incorect behaviour of BeanContextSupport.add()

Posted by "Roman S. Bushmanov (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-4019?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Roman S. Bushmanov closed HARMONY-4019.
---------------------------------------


Verified on  r549715.
Both the affected functional test and the reproducer one work as expected. 

> [classlib][beans] Incorect behaviour of BeanContextSupport.add() 
> -----------------------------------------------------------------
>
>                 Key: HARMONY-4019
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4019
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Roman S. Bushmanov
>            Assignee: Alexei Zakharov
>
> According to the Extensible Runtime Containment and Services Protocol (v1.0),  if an object that implements BeanContextProxy is added to a BeanContext, than the BeanContextChild returned from BeanContextProxy.getBeanContextProxy() should be also added to that BeanContext. The same is specified for 'remove' operation.
> However, Harmony implementation of BeanContextSupport behaves differently. Only the object that implements BeanContextProxy is added in the described case.  To reproduce the issue, please run the testcase listed below.
> The expected output is
> Context size: 2
> But on Harmony the testcase prints
> Context size: 1
> ------------------------------------- Test.java ---------------------------------------
> import java.beans.beancontext.*;
> public class Test {
>     public static void main(String[] args) throws Exception {
>         BeanContextSupport context = new BeanContextSupport(); 
>         context.add(new MyBeanContextProxy()); 
>         System.out.println("Context size: "+context.size());
>     }
>     static class MyBeanContextProxy implements BeanContextProxy {
>     
>         private BeanContextChild child = new BeanContextChildSupport();
>         
>         public BeanContextChild getBeanContextProxy(){
>             return child; 
>         }
>     }
> }
> --------------------------------------------------------------------------------------
> Affected tests:
> functional/org/apache/harmony/test/func/api/java/beans/beancontext/TestSizeBeanContext.xml
> (see HARMONY-3528)

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


[jira] Assigned: (HARMONY-4019) [classlib][beans] Incorect behaviour of BeanContextSupport.add()

Posted by "Alexei Zakharov (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-4019?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alexei Zakharov reassigned HARMONY-4019:
----------------------------------------

    Assignee: Alexei Zakharov

> [classlib][beans] Incorect behaviour of BeanContextSupport.add() 
> -----------------------------------------------------------------
>
>                 Key: HARMONY-4019
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4019
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Roman S. Bushmanov
>            Assignee: Alexei Zakharov
>
> According to the Extensible Runtime Containment and Services Protocol (v1.0),  if an object that implements BeanContextProxy is added to a BeanContext, than the BeanContextChild returned from BeanContextProxy.getBeanContextProxy() should be also added to that BeanContext. The same is specified for 'remove' operation.
> However, Harmony implementation of BeanContextSupport behaves differently. Only the object that implements BeanContextProxy is added in the described case.  To reproduce the issue, please run the testcase listed below.
> The expected output is
> Context size: 2
> But on Harmony the testcase prints
> Context size: 1
> ------------------------------------- Test.java ---------------------------------------
> import java.beans.beancontext.*;
> public class Test {
>     public static void main(String[] args) throws Exception {
>         BeanContextSupport context = new BeanContextSupport(); 
>         context.add(new MyBeanContextProxy()); 
>         System.out.println("Context size: "+context.size());
>     }
>     static class MyBeanContextProxy implements BeanContextProxy {
>     
>         private BeanContextChild child = new BeanContextChildSupport();
>         
>         public BeanContextChild getBeanContextProxy(){
>             return child; 
>         }
>     }
> }
> --------------------------------------------------------------------------------------
> Affected tests:
> functional/org/apache/harmony/test/func/api/java/beans/beancontext/TestSizeBeanContext.xml
> (see HARMONY-3528)

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


[jira] Resolved: (HARMONY-4019) [classlib][beans] Incorect behaviour of BeanContextSupport.add()

Posted by "Alexei Zakharov (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/HARMONY-4019?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alexei Zakharov resolved HARMONY-4019.
--------------------------------------

    Resolution: Fixed

I'm unable to reproduce it too on the latest harmony build (r549135). Looks like this issue was fixed by one the recent commits to the beans module. Roman, please verify that it is not reproducible in your environment anymore.

> [classlib][beans] Incorect behaviour of BeanContextSupport.add() 
> -----------------------------------------------------------------
>
>                 Key: HARMONY-4019
>                 URL: https://issues.apache.org/jira/browse/HARMONY-4019
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>            Reporter: Roman S. Bushmanov
>            Assignee: Alexei Zakharov
>
> According to the Extensible Runtime Containment and Services Protocol (v1.0),  if an object that implements BeanContextProxy is added to a BeanContext, than the BeanContextChild returned from BeanContextProxy.getBeanContextProxy() should be also added to that BeanContext. The same is specified for 'remove' operation.
> However, Harmony implementation of BeanContextSupport behaves differently. Only the object that implements BeanContextProxy is added in the described case.  To reproduce the issue, please run the testcase listed below.
> The expected output is
> Context size: 2
> But on Harmony the testcase prints
> Context size: 1
> ------------------------------------- Test.java ---------------------------------------
> import java.beans.beancontext.*;
> public class Test {
>     public static void main(String[] args) throws Exception {
>         BeanContextSupport context = new BeanContextSupport(); 
>         context.add(new MyBeanContextProxy()); 
>         System.out.println("Context size: "+context.size());
>     }
>     static class MyBeanContextProxy implements BeanContextProxy {
>     
>         private BeanContextChild child = new BeanContextChildSupport();
>         
>         public BeanContextChild getBeanContextProxy(){
>             return child; 
>         }
>     }
> }
> --------------------------------------------------------------------------------------
> Affected tests:
> functional/org/apache/harmony/test/func/api/java/beans/beancontext/TestSizeBeanContext.xml
> (see HARMONY-3528)

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