2 Replies Latest reply on Aug 28, 2007 2:06 PM by matt.drees

    Potential Bug (?)

    wschwendt

      The following is a potential bug.

      How to replicate:

      Use the CVS-based Seam and modify the seamdiscs example as follows:

      Make the following changes to WEB-INF/components.xml

      
      // remove the definition of the "discs" query with a comment
      <!-- <framework:entity-query name="discs"
       ejbql="select disc from Disc disc"
       order="disc.name ASC"
       max-results="5"/>
      -->
      
      
      // add the following definition of a "discs" query instead
       <component name="discs"
       class="org.jboss.seam.framework.EntityQuery"
       scope="CONVERSATION">
       <property name="ejbql">select disc from Disc disc</property>
       <property name="order">disc.name ASC</property>
       <property name="max-results">5</property>
       </component>
      


      Afterwards click on the following URL
      http://127.0.0.1:8080/seam-discs/discs.seam

      and an exception is thrown when javax.el.BeanResolver tries to access the dataModel property of the discs-Query Object.

        • 1. Re: Potential Bug (?)
          wschwendt

          addendum:

          if the "discs" query is defined in component.xml without the scope attribute,
          no exception is thrown and the seamdiscs example continues to work.

           <component name="discs" class="org.jboss.seam.framework.EntityQuery">
           <property name="ejbql">select disc from Disc disc</property>
           <property name="order">disc.name ASC</property>
           <property name="max-results">5</property>
           </component>
          


          This raises the question what is wrong with the scope attribute set to "CONVERSATION".
           <component name="discs" scope="CONVERSATION" ...
           ...
           </component>
          


          • 2. Re: Potential Bug (?)
            matt.drees