You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using the aforementioned annotation (as you do in the examples) with @Column(updatable=false) doesn't do anything.
@Entity
data class Customer(
@Id
val uuid: UUID = UUID.randomUUID(),
val email: String,
@Column(updatable = false)
val name: String,
@Embedded
var address: CustomerAddress = CustomerAddress(),
var groupId: String?
)
I expect the uuid and the name to not be included in this generated update mapping.
So it would be nice to either have documentation on what you actually process (found it here indirectly though). I feel like it's weird behaviour btw that I can just update an id after creation. My question is: can I somehow prevent updating with krush? If not, would it be something you'd consider implementing?
The text was updated successfully, but these errors were encountered:
Hi, thanks for the submission.
For now we support @Transient annotation which prevents property from either read or update. updatable=false seems like a good feature to implement - I'll keep the issue open to track the progress.
Sure, id should not be in the UpdateBuilder - we'll check this as well.
Hi guys,
Using the aforementioned annotation (as you do in the examples) with
@Column(updatable=false)
doesn't do anything.generates the following mapping (
mapping.kt
):I expect the
uuid
and thename
to not be included in this generated update mapping.So it would be nice to either have documentation on what you actually process (found it here indirectly though). I feel like it's weird behaviour btw that I can just update an id after creation. My question is: can I somehow prevent updating with krush? If not, would it be something you'd consider implementing?
The text was updated successfully, but these errors were encountered: