openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Michael Baylis <maill...@baylishome.me.uk>
Subject Re: OpenJPA 2.1.1 and read entitys being marked as dirty
Date Tue, 17 Jan 2012 15:31:09 GMT
Rick,
       Ok,  I'll switch over,  using Eclipse so shouldn't be difficult.

Cheers,

Michael

On 01/17/2012 03:29 PM, Rick Curtis wrote:
> Michael -
>
> I'm nearly certain that is your problem. I'd recommend getting build time
> enhancement[1] working.
>
> [1] http://openjpa.apache.org/entity-enhancement.html
>
> Thanks,
> Rick
>
> On Tue, Jan 17, 2012 at 9:22 AM, Michael Baylis
> <maillist@baylishome.me.uk>wrote:
>
>> Rick,
>>       As I am developing I am relying on runtime enhancement,  however I
>> have to have
>> <property name="openjpa.**RuntimeUnenhancedClasses" value="supported"/>
>>
>> set.
>>
>> Cheers,
>>
>> Michael
>>
>>
>>
>> On 01/17/2012 03:20 PM, Rick Curtis wrote:
>>
>>> Michael -
>>>
>>> How are you enhancing your Entities?
>>>
>>>   I have performed further testing by amending a query to be surrounded by
>>> a begin() and commit() and the commit causes the db records to be updated
>>> even though I know that no updates have taken place.
>>> What fields are being updated? All of them? Are you running with SQL trace
>>> enabled?
>>>
>>> On Tue, Jan 17, 2012 at 9:12 AM, Michael Baylis
>>> <maillist@baylishome.me.uk>**wrote:
>>>
>>>   Hi Folks,
>>>>         I am experiencing an oddity that I can't google my way out of.
>>>>
>>>> I am running OpenJPA 2.1.1 under Tomcat 7.0.23 by using my own
>>>> EntityManager object that I create when the application starts.
>>>>
>>>> What I am noticing is when I update a field in an entity and then commit
>>>> the transaction,  all entities that I have read so far appear to be dirty
>>>> and is updated in the backend database, even though I have not updated
>>>> them.
>>>>
>>>> I have performed further testing by amending a query to be surrounded by
>>>> a
>>>> begin() and commit() and the commit causes the db records to be updated
>>>> even though I know that no updates have taken place.
>>>>
>>>> I am obviously missing something in the setup that causes this, but I am
>>>> at a loss to what.
>>>>
>>>> If I run a similar query outside of a Tomcat servlet, ie in native Java,
>>>> I
>>>> don't seem to encounter this problem.
>>>>
>>>> Any help in diagnosing this would be appreciated.
>>>>
>>>> Cheers,
>>>>
>>>> Michael
>>>>
>>>>
>>>
>


Mime
View raw message