Note that there are some explanatory texts on larger screens.

plurals
  1. POIncorrect Response when calling an action concurrenct
    primarykey
    data
    text
    <p>OK guys, let's go to a strange scenario ! </p> <p>We have JSF , Spring and Hibernate/JPA. </p> <p>Assume that we have a search form and we want to search based on many inputs and the response should back to form and shows to a grid.<br> So, we sent some inputs to server and wait for response to show back to the user. </p> <p>The problem is when :</p> <p>When I open 2 browser and go to same form , and I fill my two forms with some inputs, my grids will show the incorrect result. </p> <p>Incorrect result means :<br> form 1 : (input : <strong>lineId=10</strong> , result(expected) : a row which contains <strong>lineId=10</strong>);<br> form 2 : (input : <strong>lineId=20</strong> , result(expected) : a row which contains <strong>lineId=20</strong>); </p> <p>But when I click my buttons on two form concurrently to call my actions of my form (Controllers) , the result is : </p> <p>form 1 : (input : <strong>lineId=10</strong> , result: a row which contains <strong>lineId=20</strong>);<br> form 2 : (input : <strong>lineId=20</strong> , result: a row which contains <strong>lineId=10</strong>); </p> <p>My forms scope is : request<br> My service scope is : singleton </p> <p>My form has a method which called on the button action and this method sent the inputs to my services and after giving the response from my services , send it to form again for representation ( very common behaviour ). </p> <p>I should say that this scenario happens in concurrent call action , and when I click my buttons unsynchronized , everything is OK .!! </p> <p>What is wrong ? and what's happening ? </p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload