should always the “version” field be checked when updating a domain class object ? If so, is using a while with sleep an acceptable option ?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Why would you want to check the version? This is maintained automatically by hibernate for optimistic locking. i.e. if the version has changed since you loaded the object any update you flush to the DB will fail.
Normal Grails apps do not need to interact with the version property.