Uploaded image for project: 'OpenEJB'
  1. OpenEJB
  2. OPENEJB-1299

callback method search is not considering the overriding rule.

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.1.3
    • Fix Version/s: 3.1.3
    • Component/s: container system
    • Labels:
      None
    • Environment:
      3.1.3-snapshot , geronimo 2.2.1 jetty release

      Description

      Considering following scenario:

      Bean is a EJB, BeanSuper is the Bean's super class.

      BeanSuper {

      @PostConstruct
      private void postConstructMethodInBeanSuper() throws RuntimeException

      { System.out.println( " post construct method in bean super") }

      }

      @Stateless(name="Bean")
      Bean extends BeanSuper {

      protected void postConstructMethodInBeanSuper() throws RuntimeException

      { System.out.println( " post construct method in bean") }

      }

      When container invoke the @postconstruct callback method. It should call BeanSuper#postConstructMethodInBeanSuper() instead of Bean#postConstructMethodInBeanSuper() because BeanSuper#postConstructMethodInBeanSuper() is a private method that can't be overridden.

        Attachments

        1. 1299_31branch.patch
          9 kB
          Shawn Jiang
        2. 1299_trunk.patch
          4 kB
          Shawn Jiang
        3. OPENEJB-1299.diff
          4 kB
          Shawn Jiang

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              genspring Shawn Jiang
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: