6 Replies Latest reply on Nov 17, 2008 3:05 AM by coolstone

    Page Action Lost in My concurrent Test

    coolstone

      it seems seam will lost in concurrent access

        • 1. Re: Page Action Lost in My concurrent Test
          coolstone

          Page Action Lost in My concurrent Test
          Seam2.0.0.GA JBoss4.2


          It seems seam will lost action in concurrent access.
          i have a page using get method to init:
          <page view-id="/resource/metadata/subjectDataList.xhtml" action="#{subjectDataList.init}">
                    <param name="subjectId" value="#{subjectDataList.dataSubjectId}" />     
          </page>


          and my action bean like
          '
          @Scope(PAGE)
          @Name("subjectDataList")
          public class SubjectDataList implements ISubjectDataList, Serializable
          {
          ...
             @Logger
             private Log log;


             public void init()
             {     
                 log.debug("querySubjectData call.");
                 ...
             }
          ...
          }
          '
          my test page: test.html
          <table>          
               <tr >
                    <td>
                    <iframe                         
                    src="http://172.16.8.169:8080/subjectDataList.seam?subjectId=a4d95d28-
          ea2c-442f-8c76-50a87a189269">
                    </iframe></td>
                    <td><iframe               
                              src="http://172.16.8.169:8080/subjectDataList.seam?
          subjectId=a4d95d28-ea2c-442f-8c76-50a87a189269">
                    </iframe></td>
               </tr>
               <tr >
                    <td>
                    <iframe                         
                    src="http://172.16.8.169:8080/subjectDataList.seam?subjectId=a4d95d28-
          ea2c-442f-8c76-50a87a189269">
                    </iframe></td>
                    <td><iframe               
                         src="http://172.16.8.169:8080/subjectDataList.seam?
          subjectId=a4d95d28-ea2c-442f-8c76-50a87a189269">
                    </iframe></td>
               </tr>     
          </table>

          • 2. Re: Page Action Lost in My concurrent Test
            coolstone

            Page Action Lost in My concurrent Test.


            Seam2.0.0.GA JBoss4.2.


            It seems seam will lost action in concurrent access.


            1. i have a page using get method to init


            <page view-id="/resource/metadata/subjectDataList.xhtml" action="#{subjectDataList.init}">
                      <param name="subjectId" value="#{subjectDataList.dataSubjectId}" />     
            </page>
            



            2. and my action bean like


            @Scope(PAGE)
            @Name("subjectDataList")
            public class SubjectDataList implements ISubjectDataList, Serializable
            {
             ...
               @Logger
               private Log log;
            
               public void init()
               {     
                   log.debug("querySubjectData call.");
                   ...
               }
             ...
            }
            



            3. my test page: test.html


            <table>          
                 <tr>
                      <td>
                      <iframe     src="http://172.16.8.169:8080/subjectDataList.seam"></iframe>
                      </td>
                      <td>
                      <iframe     src="http://172.16.8.169:8080/subjectDataList.seam"></iframe></td>
                 </tr>
                 <tr>
                      <td>
                      <iframe     src="http://172.16.8.169:8080/subjectDataList.seam"></iframe>
                      </td>
                      <td>
                      <iframe     src="http://172.16.8.169:8080/subjectDataList.seam"></iframe></td>
                 </tr>
            </table>
            




            • 3. Re: Page Action Lost in My concurrent Test
              dan.j.allen

              Page-scoped components are not synchronized by Seam. You can add the @Synchornized annotation if you desire this feature. Seam natively synchronizes conversation and session-scoped components.


              Regardless, I don't understand the nature of your problem based on the description you have provided.

              • 4. Re: Page Action Lost in My concurrent Test
                coolstone

                Thank you! Dan.


                I support several people access the page on the same time, so comes the test.
                But the result makes me surprise, not everybody invoke the action init, the console does not output all four querySubjectData call., why?


                I add @Synchornized annotation, it's the same.

                • 5. Re: Page Action Lost in My concurrent Test
                  jpviragine.jpviragine.gmail.com
                  Shawn,

                  Try put debug="false" in your components.xml

                  <core:init debug="false" jndi-pattern="@jndiPattern@" />

                  We have trouble with concurrent requests and debug mode on
                  • 6. Re: Page Action Lost in My concurrent Test
                    coolstone

                    Thank you!Joao.


                    Everything goes well now.