Zouxxyy opened a new issue, #4616:
URL: https://github.com/apache/paimon/issues/4616

   ### Search before asking
   
   - [X] I searched in the [issues](https://github.com/apache/paimon/issues) 
and found nothing similar.
   
   
   ### Motivation
   
   Currently, the transaction isolation level of paimon is snapshot level. For 
the following concurrent modification scenarios, incorrect data may occur
   
   ```scala
   sql("create table t1 (id int, c1 string, c2 string) using paimon 
tblproperties('primary-key'='id')")
   
   sql("insert into t1 values (1, 'a', 'a')")
   
   val update1 = Future {
     sql("update t1 set c1 = 'b' where id = 1")
   }
   
   Thread.sleep(5000)
   
   val update2 = Future {
     sql("update t1 set c2 = 'c' where id = 1")
   }
   Await.result(update1, 1000.seconds)
   Await.result(update2, 1000.seconds)
   sql("select * from t1").show()
   ```
   
   The output result may be any of `1, 'b', 'a'`  `1, 'a', 'c'` or `1, 'b', 'c'`
   
   
   ### Solution
   
   _No response_
   
   ### Anything else?
   
   _No response_
   
   ### Are you willing to submit a PR?
   
   - [ ] I'm willing to submit a PR!


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@paimon.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to