title: Laravel lockForUpdate + Transaction
body: <p>We're using lockForUpdate like this:</p>
  
  <pre><code>DB::beginTransaction();
  
  try {
      $balance = UserBalance::where('user_id', 2)
                      -&gt;lockForUpdate()
                      -&gt;first();
      $balance-&gt;usd += 100;
      $balance-&gt;save();
  
      // A LOT MORE LOGIC HERE
  
      $balance = UserBalance::where('user_id', 7)
                      -&gt;lockForUpdate()
                      -&gt;first();
      $balance-&gt;usd -= 100;
      $balance-&gt;save();
  
  } catch (\Exception $e) {
      DB::rollback();
      return json_encode ([
          'success' =&gt; false,
          'message' =&gt; 'error',
      ]);
  }
  DB::commit();
  </code></pre>
  
  <p>Everything ok, i tried with some "sleep(20)" before the commit and sent another requisition (without the sleep) and the row is really locked, but we're facing a problem. When we run this from a cron multiple times, it seems that the function run on the exactly same millisecond, then the lock doesn't seems to work, is this possible? Is there any other solution instead of using a queue?</p>
  
  <p>The CRON is just calling a route multiple times like this:</p>
  
  <pre><code>* * * * * curl http://test.com.br/test
  * * * * * curl http://test.com.br/test
  * * * * * curl http://test.com.br/test
  </code></pre>