-
Notifications
You must be signed in to change notification settings - Fork 61
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
lastUpdatedBy is not getting updated #182
Comments
What's your plugin config? |
|
Are you using the |
I'm experiencing the same problem using version 3.0.1 (with Hibernate 5.1.16.Final) and the Stampable trait. I'm not trying to make lastUpdatedBy nullable like OP and initial value is set to match createdBy as expected. But changes to lastUpdatedBy afterwards are not saved to the database, whereas changes to other fields including lastUpdated are. I can see that StampListener.handleUpdate is called after calling save(flush:true) and the value in the domain object is updated within the session of the one request. However, it's not saved to the database and subsequent requests show the unchanged value of lastUpdatedBy while all other changes to the domain including lastUpdated were persisted. |
A similar problem occurs if you independently implement the abstract class AbstractPersistenceEventListener. Example: https://github.com/MaxMoto1702/grails-AbstractPersistenceEventListener |
@tekells-usgs How did you finally deal with this problem? I had the same problem,thanks |
Version: org.grails.plugins:audit-logging:3.0.3
I am new to this plugin, but have noticed a fairly critical issue. The last_updated_by column is not being updated when entities are updated. However, it is being set when the entity is first created (along with created_by)
Could this be a bug in the new version?
I'm not sure what the expected behaviour is, but I would expect:
The text was updated successfully, but these errors were encountered: