openjpa-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pinaki Poddar" <ppod...@bea.com>
Subject RE: [jira] Commented: (OPENJPA-35) In-memory Delete operation fails with active DataCache
Date Wed, 28 Feb 2007 22:14:27 GMT
   The issue is now better be stated as "Delete by Query does not remove
the copy from L2 cache".

   a) Tried to lock the instance, before delete causes commit to fail
with OptimisticVerification
   b) Modifying the object before delete causes no change in behaviour
in the scope of the given test.   


Pinaki Poddar
BEA Systems
415.402.7317  


-----Original Message-----
From: Patrick Linskey (JIRA) [mailto:jira@apache.org] 
Sent: Wednesday, February 28, 2007 2:00 PM
To: open-jpa-dev@incubator.apache.org
Subject: [jira] Commented: (OPENJPA-35) In-memory Delete operation fails
with active DataCache


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

Patrick Linskey commented on OPENJPA-35:
----------------------------------------

What happens if the user modifies the object or if the user obtains a
read lock on the instance?

> In-memory Delete operation fails with active DataCache
> ------------------------------------------------------
>
>                 Key: OPENJPA-35
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-35
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: datacache, query
>         Environment: Only happens when DataCache is active
> 			<property name="openjpa.DataCache"
value="true"/>
> 			<property name="openjpa.RemoteCommitProvider"
value="sjvm"/>
>            Reporter: Pinaki Poddar
>            Priority: Critical
>         Attachments: openjpa-35.test.zip
>
>
> Delete through query such as 
> 		Query query = em.createQuery("DELETE FROM Node n");
> 		query.executeUpdate();
> fails with following exception (only when DataCache is active) 
> Exception in thread "main" <4|false|0.0.0>
org.apache.openjpa.persistence.ArgumentException:
org.apache.openjpa.datacache.QueryCacheStoreQuery
> 	at
org.apache.openjpa.kernel.QueryImpl.deleteInMemory(QueryImpl.java:1029)
> 	at
org.apache.openjpa.kernel.ExpressionStoreQuery$DataStoreExecutor.execute
Delete(ExpressionStoreQuery.java:665)
> 	at
org.apache.openjpa.datacache.QueryCacheStoreQuery$QueryCacheExecutor.exe
cuteDelete(QueryCacheStoreQuery.java:348)
> 	at
org.apache.openjpa.kernel.QueryImpl.delete(QueryImpl.java:1012)
> 	at
org.apache.openjpa.kernel.QueryImpl.execute(QueryImpl.java:768)
> 	at
org.apache.openjpa.kernel.QueryImpl.deleteAll(QueryImpl.java:831)
> 	at
org.apache.openjpa.kernel.QueryImpl.deleteAll(QueryImpl.java:827)
> 	at
org.apache.openjpa.kernel.DelegatingQuery.deleteAll(DelegatingQuery.java
:544)
> 	at
org.apache.openjpa.persistence.QueryImpl.executeUpdate(QueryImpl.java:29
9)
> 	at control.Test.clear(Test.java:87)
> 	at control.Test.run(Test.java:37)
> 	at control.Test.main(Test.java:178)
> Caused by: java.lang.ClassCastException:
org.apache.openjpa.datacache.QueryCacheStoreQuery
> 	at
org.apache.openjpa.kernel.ExpressionStoreQuery$DataStoreExecutor.execute
Query(ExpressionStoreQuery.java:651)
> 	at
org.apache.openjpa.kernel.QueryImpl.execute(QueryImpl.java:949)
> 	at
org.apache.openjpa.kernel.QueryImpl.deleteInMemory(QueryImpl.java:1018)
> 	... 11 more

--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

_______________________________________________________________________
Notice:  This email message, together with any attachments, may contain
information  of  BEA Systems,  Inc.,  its subsidiaries  and  affiliated
entities,  that may be confidential,  proprietary,  copyrighted  and/or
legally privileged, and is intended solely for the use of the individual
or entity named in this message. If you are not the intended recipient,
and have received this message in error, please immediately return this
by email and then delete it.

Mime
View raw message