openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Patrick Linskey (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (OPENJPA-1973) Unlocked field support
Date Sun, 24 Apr 2011 18:29:05 GMT

    [ https://issues.apache.org/jira/browse/OPENJPA-1973?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13024658#comment-13024658
] 

Patrick Linskey commented on OPENJPA-1973:
------------------------------------------

Yeah, I chose a pretty poor example.

Consider a relationship between Discussion and Comment. A discussion might have hundreds of
comments, all arriving somewhat concurrently. It might be desirable to have a one-to-many
relationship between Discussion and Comment, and an insert of a new Comment or a modification
to a Comment might cause the Discussion's lastModified field to be updated. In this scenario,
it'd be useful for both of these fields (Discussion.comments and Discussion.lastModified)
to be excluded from optimistic lock computations.

Does that make more sense?

> Unlocked field support
> ----------------------
>
>                 Key: OPENJPA-1973
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1973
>             Project: OpenJPA
>          Issue Type: New Feature
>          Components: docs, jdbc, jpa
>            Reporter: Patrick Linskey
>            Assignee: Patrick Linskey
>         Attachments: OPENJPA-1973-with-docs.patch, OPENJPA-1973.patch
>
>
> Often, it's desirable to exclude certain fields from the optimistic locking computation.
For example, if a PurchaseOrder's lastUpdatedDate field is updated every time a line item
is added, it may be acceptable to simply use the latest value instead of requiring an optimistic
lock check / collision.
> Let's add support for such fields.

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message