[Hibernate-JIRA] Created: (HHH-5576) Reading and querying against date values with Criteria API causing error
by Radosław Smogura (JIRA)
Reading and querying against date values with Criteria API causing error
------------------------------------------------------------------------
Key: HHH-5576
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-5576
Project: Hibernate Core
Issue Type: Bug
Affects Versions: 3.6.0.CR1
Environment: PostgreSQL 8.4
Reporter: Radosław Smogura
An Entity that has Date field, is then searched against value from this field, this causes to throw PSQL error :Caused by: org.postgresql.util.PSQLException: ERROR: operator does not exist: date = bytea
Wskazówka: No operator matches the given name and argument type(s). You might need to add explicit type casts.
Pozycja: 119
at org.postgresql.core.v3.QueryExecutorImpl.receiveErrorResponse(QueryExecutorImpl.java:2062)
at org.postgresql.core.v3.QueryExecutorImpl.processResults(QueryExecutorImpl.java:1795)
at org.postgresql.core.v3.QueryExecutorImpl.execute(QueryExecutorImpl.java:257)
at org.postgresql.jdbc2.AbstractJdbc2Statement.execute(AbstractJdbc2Statement.java:479)
at org.postgresql.jdbc2.AbstractJdbc2Statement.executeWithFlags(AbstractJdbc2Statement.java:367)
at org.postgresql.jdbc2.AbstractJdbc2Statement.executeQuery(AbstractJdbc2Statement.java:271)
at sun.reflect.GeneratedMethodAccessor256.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.postgresql.ds.jdbc23.AbstractJdbc23PooledConnection$StatementHandler.invoke(AbstractJdbc23PooledConnection.java:455)
at $Proxy243.executeQuery(Unknown Source)
at com.sun.gjc.spi.jdbc40.PreparedStatementWrapper40.executeQuery(PreparedStatementWrapper40.java:641)
at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:208)
at org.hibernate.loader.Loader.getResultSet(Loader.java:1953)
at org.hibernate.loader.Loader.doQuery(Loader.java:802)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:274)
at org.hibernate.loader.Loader.doList(Loader.java:2533)
Error is probably caused, because the return type of Date filed is java.sql.Date or java.sql.Timestamp (this last works).
I will attach sample application.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 8 months
[Hibernate-JIRA] Created: (HHH-5575) keyword end in mapped field can result to SQLERROR SQLSTATE=42702
by nimo stephan (JIRA)
keyword end in mapped field can result to SQLERROR SQLSTATE=42702
-----------------------------------------------------------------
Key: HHH-5575
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-5575
Project: Hibernate Core
Issue Type: Bug
Environment: JBOSS AS 6 M4
Reporter: nimo stephan
I have a property "end" which is mapped as a column:
@Entity
public class Times implements Serializable{
@Id
private Integer idTimes;
..
// TODO: DO NOT USE "END" it can return a JPA-Bug !! SQLSTATE=42702
@Temporal(TemporalType.TIMESTAMP)
private Date end;
..
@OneToMany(mappedBy = "leadTime", fetch=FetchType.EAGER)
private Set<OtherTimes> otherTimes;
..
}
which has a relation to OtherTimes:
public class OtherTimes implements Serializable{
@Id
private Integer idOtherTimes;
..
// TODO: DO NOT USE "END" it can return a JPA-Bug !! SQLSTATE=42702
@Temporal(TemporalType.TIMESTAMP)
private Date end;
..
..
}
Now, I want to retrieve times via "myBean.getTimes()". Hibernate generates this query which brings a SQL-ERROR:
select
times0_.ID as ID1_18_3_,
end as end18_3_,
end as end8_0_,
othertimes0_.ID as ID4_8_0_,
from
SCHEMA.TIMES times0_
left outer join
SCHEMA.OTHERTIMES othertimes1_
on times0_.IDTIMES=othertimes0.ID_TIMES
where
times0_.IDTIMES=?
It throws this exception:
Caused by: org.hibernate.exception.SQLGrammarException: could not load an entity: [com.Times#1]
at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:92)
at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:66)
at org.hibernate.loader.Loader.loadEntity(Loader.java:1937)
at org.hibernate.loader.entity.AbstractEntityLoader.load(AbstractEntityLoader.java:86)
at org.hibernate.loader.entity.EntityLoader.loadByUniqueKey(EntityLoader.java:160)
at org.hibernate.persister.entity.AbstractEntityPersister.loadByUniqueKey(AbstractEntityPersister.java:1777)
at org.hibernate.type.EntityType.loadByUniqueKey(EntityType.java:674)
at org.hibernate.type.EntityType.resolve(EntityType.java:434)
at org.hibernate.engine.TwoPhaseLoad.initializeEntity(TwoPhaseLoad.java:140)
at org.hibernate.loader.Loader.initializeEntitiesAndCollections(Loader.java:898)
at org.hibernate.loader.Loader.doQuery(Loader.java:773)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:270)
at org.hibernate.loader.Loader.loadEntity(Loader.java:1933)
at org.hibernate.loader.entity.AbstractEntityLoader.load(AbstractEntityLoader.java:86)
at org.hibernate.loader.entity.AbstractEntityLoader.load(AbstractEntityLoader.java:76)
at org.hibernate.persister.entity.AbstractEntityPersister.load(AbstractEntityPersister.java:3270)
at org.hibernate.event.def.DefaultLoadEventListener.loadFromDatasource(DefaultLoadEventListener.java:496)
at org.hibernate.event.def.DefaultLoadEventListener.doLoad(DefaultLoadEventListener.java:477)
at org.hibernate.event.def.DefaultLoadEventListener.load(DefaultLoadEventListener.java:227)
at org.hibernate.event.def.DefaultLoadEventListener.proxyOrLoad(DefaultLoadEventListener.java:285)
at org.hibernate.event.def.DefaultLoadEventListener.onLoad(DefaultLoadEventListener.java:152)
at org.hibernate.impl.SessionImpl.fireLoad(SessionImpl.java:1080)
at org.hibernate.impl.SessionImpl.internalLoad(SessionImpl.java:1028)
at org.hibernate.type.EntityType.resolveIdentifier(EntityType.java:623)
at org.hibernate.type.EntityType.resolve(EntityType.java:431)
at org.hibernate.engine.TwoPhaseLoad.initializeEntity(TwoPhaseLoad.java:140)
at org.hibernate.loader.Loader.initializeEntitiesAndCollections(Loader.java:898)
at org.hibernate.loader.Loader.doQuery(Loader.java:773)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:270)
at org.hibernate.loader.Loader.doList(Loader.java:2294)
at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2172)
at org.hibernate.loader.Loader.list(Loader.java:2167)
at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:448)
at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:363)
at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:196)
at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1258)
at org.hibernate.impl.QueryImpl.list(QueryImpl.java:102)
at org.hibernate.ejb.QueryImpl.getResultList(QueryImpl.java:241)
... 182 more
Caused by: com.ibm.db2.jcc.b.nm: DB2 SQL Error: SQLCODE=-203, SQLSTATE=42702, SQLERRMC=END, DRIVER=3.50.152
at com.ibm.db2.jcc.b.wc.a(wc.java:579)
at com.ibm.db2.jcc.b.wc.a(wc.java:57)
at com.ibm.db2.jcc.b.wc.a(wc.java:126)
at com.ibm.db2.jcc.b.tk.c(tk.java:1901)
at com.ibm.db2.jcc.b.tk.d(tk.java:1889)
at com.ibm.db2.jcc.b.tk.a(tk.java:1416)
at com.ibm.db2.jcc.t4.db.g(db.java:138)
at com.ibm.db2.jcc.t4.db.a(db.java:38)
at com.ibm.db2.jcc.t4.t.a(t.java:32)
at com.ibm.db2.jcc.t4.sb.h(sb.java:141)
at com.ibm.db2.jcc.b.tk.N(tk.java:1387)
at com.ibm.db2.jcc.b.uk.Kb(uk.java:2461)
at com.ibm.db2.jcc.b.uk.e(uk.java:3101)
at com.ibm.db2.jcc.b.uk.yb(uk.java:535)
at com.ibm.db2.jcc.b.uk.executeQuery(uk.java:509)
at org.jboss.resource.adapter.jdbc.WrappedPreparedStatement.executeQuery(WrappedPreparedStatement.java:342)
at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:208)
at org.hibernate.loader.Loader.getResultSet(Loader.java:1849)
at org.hibernate.loader.Loader.doQuery(Loader.java:718)
at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:270)
at org.hibernate.loader.Loader.loadEntity(Loader.java:1933)
So you see, instead of using this:
times0_.end as end18_3_,
othertimes0_.end as end8_0_,
Hibernate uses this:
end as end18_3_,
end as end8_0_,
which leads to a conflict!
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 8 months
[Hibernate-JIRA] Commented: (HHH-817) Projection aliases should not be applied to where-clause (Milosz Tylenda)
by Mark A. Ziesemer (JIRA)
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-817?page=co... ]
Mark A. Ziesemer commented on HHH-817:
--------------------------------------
It looks like this missed 3.5.6. Will there be a 3.5.7? If so, can this please be included? Otherwise, when should we expect a final 3.6.0 release that includes this fix?
> Projection aliases should not be applied to where-clause (Milosz Tylenda)
> -------------------------------------------------------------------------
>
> Key: HHH-817
> URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-817
> Project: Hibernate Core
> Issue Type: Bug
> Components: core
> Affects Versions: 3.0.5, 3.5.5, 3.6.0.Beta3
> Environment: Oracle 9.2.0.6, Hibernate 3.0.5, Spring Framework 1.2.2 based application working on Jakarta Tomcat 5.0.28
> Reporter: Michal Jastak
> Assignee: Gail Badner
> Fix For: 3.6.0.Beta4
>
> Attachments: HHH-817.patch, HHH-817_3.3.2GA_17882.patch
>
>
> following java code:
> protected Entity loadEntityLightweight(Serializable entityId) throws DataAccessException {
> Criteria criteria = getSession().createCriteria(Entity.class);
> ProjectionList projectionList = Projections.projectionList();
> projectionList.add(Property.forName(BaseEntity.PROP_ID), BaseEntity.PROP_ID);
> projectionList.add(Property.forName(BaseEntity.PROP_TYPE), BaseEntity.PROP_TYPE);
> criteria.setProjection(projectionList);
> criteria.add(Restrictions.eq(BaseEntity.PROP_ID, entityId));
> criteria.setResultTransformer(new AliasToBeanResultTransformer(Entity.class));
> return (Entity) criteria.uniqueResult();
> }
> generates following SQL query:
> select this_.id as y0_, this_.type as y1_ from entities this_ left outer join facilities this_1_ on this_.id=this_1_.id left outer join users this_2_ on this_.id=this_2_.id left outer join addresses address2_ on this_.address_id=address2_.id left outer join entities entity3_ on this_2_.employer_id=entity3_.id left outer join facilities entity3_1_ on entity3_.id=entity3_1_.id left outer join users entity3_2_ on entity3_.id=entity3_2_.id where y0_=?
> y0_ = ? expression in where clause is causing a 904 error on Oracle 9:
> ORA-00904: "Y0_": invalid identifier
> hibernate dialect: org.hibernate.dialect.Oracle9Dialect
> mapping for Entity class:
> <?xml version="1.0"?>
> <!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
> "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
> <hibernate-mapping default-lazy="false" default-cascade="save-update">
>
> <class name="Entity" table="entities" mutable="true">
> <id name="id" type="java.lang.Long" unsaved-value="null">
> <generator class="sequence">
> <param name="sequence">entities_id_seq</param>
> </generator>
> </id>
> <many-to-one name="address" class="Address" column="address_id" />
> ...
> <!--
> - Facilities
> -->
> <joined-subclass name="Facility" table="facilities">
> <key column="id" />
> ...
> <set name="users" inverse="true" lazy="true">
> <key column="facility_id" />
> <one-to-many class="User" />
> </set>
> </joined-subclass>
> <!--
> - Users
> -->
> <joined-subclass name="User" table="users" dynamic-insert="true" dynamic-update="true">
> <key column="id" />
> <many-to-one name="employer" class="Entity" column="employer_id" cascade="none" />
> ...
> <set name="userAuthorities" inverse="true" cascade="all-delete-orphan">
> <key column="user_id" />
> <one-to-many class="Authority" />
> </set>
> </joined-subclass>
> </class>
> </hibernate-mapping>
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 8 months
[Hibernate-JIRA] Created: (HHH-5563) JndiInfinispanRegionFactory creates region with a stopped cache, if region previously existed
by Paul Ferraro (JIRA)
JndiInfinispanRegionFactory creates region with a stopped cache, if region previously existed
---------------------------------------------------------------------------------------------
Key: HHH-5563
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-5563
Project: Hibernate Core
Issue Type: Bug
Components: caching (L2)
Affects Versions: 3.6.0.Beta4, 3.5.5
Reporter: Paul Ferraro
Attachments: patch.txt
Using JndiInfinispanRegionFactory, closing a hibernate session factory triggers the destruction of all associated cache regions and stops the backing caches, though not the cache manager itself (Due to HHH-5512). If the session factory is restarted (e.g. the same application is redeployed), CacheManager.getCache(...) will return the already existing cache, but with a TERMINATED status. Consequently, when determining the cache instance for a given region, the region factory must always validate the status of the cache, starting it if necessary.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 8 months
[Hibernate-JIRA] Created: (HHH-5552) Infinispan cache regions need to load entities and keys using application classloader.
by Paul Ferraro (JIRA)
Infinispan cache regions need to load entities and keys using application classloader.
--------------------------------------------------------------------------------------
Key: HHH-5552
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-5552
Project: Hibernate Core
Issue Type: Bug
Components: caching (L2)
Affects Versions: 3.6.0.Beta4, 3.5.5
Reporter: Paul Ferraro
Priority: Critical
While testing hibernate-infinispan, I see ClassNotFoundExceptions when the jgroups receiver thread attempts to deserialize an entity PK (in this case within the BaseRegion cache listener). Deserialization throw a CNFE since the custom key is not known to the context classloader of the jgroups up handler. It would appear that lazy deserialization is not sufficient to prevent this. Consequently, I think we need to reproduce the classloader handling from the jbosscache provider. That is, store a reference to the application classloader and swap thread context classloaders any time a key or an entity needs to be deserialized.
2010-09-10 13:46:53,339 ERROR [org.infinispan.interceptors.InvocationContextInterceptor] (Incoming-2,null) Execution error: : org.infinispan.CacheException: Caught exception invoking method public void org.hibernate.cache.infinispan.impl.BaseRegion.entryModified(org.infinispan.notifications.cachelistener.event.CacheEntryModifiedEvent) on listener instance org.hibernate.cache.infinispan.query.QueryResultsRegionImpl@70099d73
at org.infinispan.notifications.AbstractListenerImpl$ListenerInvocation$1.run(AbstractListenerImpl.java:179) [:4.1.1.CR0]
at org.infinispan.util.concurrent.WithinThreadExecutor.execute(WithinThreadExecutor.java:47) [:4.1.1.CR0]
at org.infinispan.notifications.AbstractListenerImpl$ListenerInvocation.invoke(AbstractListenerImpl.java:189) [:4.1.1.CR0]
at org.infinispan.notifications.cachelistener.CacheNotifierImpl.notifyCacheEntryModified(CacheNotifierImpl.java:146) [:4.1.1.CR0]
at org.infinispan.commands.write.PutKeyValueCommand.perform(PutKeyValueCommand.java:108) [:4.1.1.CR0]
at org.infinispan.interceptors.CallInterceptor.handleDefault(CallInterceptor.java:72) [:4.1.1.CR0]
at org.infinispan.commands.AbstractVisitor.visitPutKeyValueCommand(AbstractVisitor.java:57) [:4.1.1.CR0]
at org.infinispan.commands.write.PutKeyValueCommand.acceptVisitor(PutKeyValueCommand.java:76) [:4.1.1.CR0]
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118) [:4.1.1.CR0]
at org.infinispan.interceptors.ReplicationInterceptor.handleCrudMethod(ReplicationInterceptor.java:107) [:4.1.1.CR0]
at org.infinispan.interceptors.ReplicationInterceptor.visitPutKeyValueCommand(ReplicationInterceptor.java:78) [:4.1.1.CR0]
at org.infinispan.commands.write.PutKeyValueCommand.acceptVisitor(PutKeyValueCommand.java:76) [:4.1.1.CR0]
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118) [:4.1.1.CR0]
at org.infinispan.interceptors.LockingInterceptor.visitPutKeyValueCommand(LockingInterceptor.java:198) [:4.1.1.CR0]
at org.infinispan.commands.write.PutKeyValueCommand.acceptVisitor(PutKeyValueCommand.java:76) [:4.1.1.CR0]
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118) [:4.1.1.CR0]
at org.infinispan.interceptors.base.CommandInterceptor.handleDefault(CommandInterceptor.java:132) [:4.1.1.CR0]
at org.infinispan.commands.AbstractVisitor.visitPutKeyValueCommand(AbstractVisitor.java:57) [:4.1.1.CR0]
at org.infinispan.commands.write.PutKeyValueCommand.acceptVisitor(PutKeyValueCommand.java:76) [:4.1.1.CR0]
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118) [:4.1.1.CR0]
at org.infinispan.interceptors.MarshalledValueInterceptor.visitPutKeyValueCommand(MarshalledValueInterceptor.java:116) [:4.1.1.CR0]
at org.infinispan.commands.write.PutKeyValueCommand.acceptVisitor(PutKeyValueCommand.java:76) [:4.1.1.CR0]
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118) [:4.1.1.CR0]
at org.infinispan.interceptors.TxInterceptor.visitPrepareCommand(TxInterceptor.java:82) [:4.1.1.CR0]
at org.infinispan.commands.tx.PrepareCommand.acceptVisitor(PrepareCommand.java:120) [:4.1.1.CR0]
at org.infinispan.interceptors.base.CommandInterceptor.invokeNextInterceptor(CommandInterceptor.java:118) [:4.1.1.CR0]
at org.infinispan.interceptors.InvocationContextInterceptor.handleAll(InvocationContextInterceptor.java:57) [:4.1.1.CR0]
at org.infinispan.interceptors.InvocationContextInterceptor.handleDefault(InvocationContextInterceptor.java:38) [:4.1.1.CR0]
at org.infinispan.commands.AbstractVisitor.visitPrepareCommand(AbstractVisitor.java:105) [:4.1.1.CR0]
at org.infinispan.commands.tx.PrepareCommand.acceptVisitor(PrepareCommand.java:120) [:4.1.1.CR0]
at org.infinispan.interceptors.InterceptorChain.invoke(InterceptorChain.java:273) [:4.1.1.CR0]
at org.infinispan.commands.tx.PrepareCommand.perform(PrepareCommand.java:111) [:4.1.1.CR0]
at org.infinispan.remoting.InboundInvocationHandlerImpl.handle(InboundInvocationHandlerImpl.java:81) [:4.1.1.CR0]
at org.infinispan.remoting.transport.jgroups.CommandAwareRpcDispatcher.executeCommand(CommandAwareRpcDispatcher.java:176) [:4.1.1.CR0]
at org.infinispan.remoting.transport.jgroups.CommandAwareRpcDispatcher.handle(CommandAwareRpcDispatcher.java:148) [:4.1.1.CR0]
at org.jgroups.blocks.RequestCorrelator.handleRequest(RequestCorrelator.java:575) [:2.10.0.GA]
at org.jgroups.blocks.RequestCorrelator.receiveMessage(RequestCorrelator.java:486) [:2.10.0.GA]
at org.jgroups.blocks.RequestCorrelator.receive(RequestCorrelator.java:362) [:2.10.0.GA]
at org.jgroups.blocks.MessageDispatcher$ProtocolAdapter.up(MessageDispatcher.java:771) [:2.10.0.GA]
at org.jgroups.blocks.mux.MuxUpHandler.up(MuxUpHandler.java:136) [:2.10.0.GA]
at org.jgroups.JChannel.up(JChannel.java:1453) [:2.10.0.GA]
at org.jgroups.stack.ProtocolStack.up(ProtocolStack.java:887) [:2.10.0.GA]
at org.jgroups.protocols.pbcast.FLUSH.up(FLUSH.java:483) [:2.10.0.GA]
at org.jgroups.protocols.pbcast.STREAMING_STATE_TRANSFER.up(STREAMING_STATE_TRANSFER.java:265) [:2.10.0.GA]
at org.jgroups.protocols.FRAG2.up(FRAG2.java:188) [:2.10.0.GA]
at org.jgroups.protocols.FC.up(FC.java:474) [:2.10.0.GA]
at org.jgroups.protocols.pbcast.GMS.up(GMS.java:888) [:2.10.0.GA]
at org.jgroups.protocols.VIEW_SYNC.up(VIEW_SYNC.java:171) [:2.10.0.GA]
at org.jgroups.protocols.pbcast.STABLE.up(STABLE.java:234) [:2.10.0.GA]
at org.jgroups.protocols.UNICAST.up(UNICAST.java:309) [:2.10.0.GA]
at org.jgroups.protocols.pbcast.NAKACK.handleMessage(NAKACK.java:877) [:2.10.0.GA]
at org.jgroups.protocols.pbcast.NAKACK.up(NAKACK.java:671) [:2.10.0.GA]
at org.jgroups.protocols.BARRIER.up(BARRIER.java:120) [:2.10.0.GA]
at org.jgroups.protocols.VERIFY_SUSPECT.up(VERIFY_SUSPECT.java:132) [:2.10.0.GA]
at org.jgroups.protocols.FD.up(FD.java:266) [:2.10.0.GA]
at org.jgroups.protocols.FD_SOCK.up(FD_SOCK.java:270) [:2.10.0.GA]
at org.jgroups.protocols.MERGE2.up(MERGE2.java:210) [:2.10.0.GA]
at org.jgroups.protocols.Discovery.up(Discovery.java:281) [:2.10.0.GA]
at org.jgroups.protocols.PING.up(PING.java:67) [:2.10.0.GA]
at org.jgroups.stack.Protocol.up(Protocol.java:371) [:2.10.0.GA]
at org.jgroups.protocols.TP.passMessageUp(TP.java:1009) [:2.10.0.GA]
at org.jgroups.protocols.TP.access$100(TP.java:56) [:2.10.0.GA]
at org.jgroups.protocols.TP$IncomingPacket.handleMyMessage(TP.java:1549) [:2.10.0.GA]
at org.jgroups.protocols.TP$IncomingPacket.run(TP.java:1531) [:2.10.0.GA]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110) [:1.6.0_20]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603) [:1.6.0_20]
at java.lang.Thread.run(Thread.java:636) [:1.6.0_20]
Caused by: org.infinispan.CacheException: Unable to unmarshall value
at org.infinispan.marshall.MarshalledValue.deserialize(MarshalledValue.java:114) [:4.1.1.CR0]
at org.infinispan.marshall.MarshalledValue.get(MarshalledValue.java:167) [:4.1.1.CR0]
at org.infinispan.notifications.cachelistener.event.EventImpl.getKey(EventImpl.java:66) [:4.1.1.CR0]
at org.hibernate.cache.infinispan.impl.BaseRegion.handleEvictAllModification(BaseRegion.java:264) [:3.5.6-SNAPSHOT]
at org.hibernate.cache.infinispan.impl.BaseRegion.entryModified(BaseRegion.java:260) [:3.5.6-SNAPSHOT]
at sun.reflect.GeneratedMethodAccessor271.invoke(Unknown Source) [:1.6.0_20]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [:1.6.0_20]
at java.lang.reflect.Method.invoke(Method.java:616) [:1.6.0_20]
at org.infinispan.notifications.AbstractListenerImpl$ListenerInvocation$1.run(AbstractListenerImpl.java:175) [:4.1.1.CR0]
... 66 more
Caused by: java.lang.ClassNotFoundException: org.jboss.test.cluster.clusteredentity.classloader.AccountHolderPK from BaseClassLoader@620968f9{vfs:///home/paul/jboss/as/infinispan-int/build/target/jboss-6.0.0-SNAPSHOT/server/cluster-udp-1/conf/jboss-service.xml}
at org.jboss.classloader.spi.base.BaseClassLoader.loadClass(BaseClassLoader.java:480) [jboss-classloader.jar:2.2.0.Alpha7]
at java.lang.ClassLoader.loadClass(ClassLoader.java:266) [:1.6.0_20]
at java.lang.Class.forName0(Native Method) [:1.6.0_20]
at java.lang.Class.forName(Class.java:264) [:1.6.0_20]
at org.jboss.marshalling.AbstractClassResolver.loadClass(AbstractClassResolver.java:135) [:]
at org.jboss.marshalling.AbstractClassResolver.resolveClass(AbstractClassResolver.java:116) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadClassDescriptor(RiverUnmarshaller.java:845) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1247) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:272) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:209) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.readFields(RiverUnmarshaller.java:1610) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1526) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1175) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:272) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:209) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.readFields(RiverUnmarshaller.java:1610) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1526) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1175) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:272) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:209) [:]
at org.jboss.marshalling.AbstractObjectInput.readObject(AbstractObjectInput.java:36) [:]
at org.infinispan.marshall.MarshallUtil.unmarshallMap(MarshallUtil.java:65) [:4.1.1.CR0]
at org.infinispan.marshall.exts.MapExternalizer.readObject(MapExternalizer.java:78) [:4.1.1.CR0]
at org.infinispan.marshall.jboss.ConstantObjectTable$ExternalizerAdapter.readObject(ConstantObjectTable.java:266) [:4.1.1.CR0]
at org.infinispan.marshall.jboss.ConstantObjectTable.readObject(ConstantObjectTable.java:253) [:4.1.1.CR0]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:351) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:209) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.readFields(RiverUnmarshaller.java:1610) [:]
at org.jboss.marshalling.river.RiverObjectInputStream.defaultReadObject(RiverObjectInputStream.java:73) [:]
at org.hibernate.cache.QueryKey.readObject(QueryKey.java:192) [:3.5.6-SNAPSHOT]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [:1.6.0_20]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) [:1.6.0_20]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [:1.6.0_20]
at java.lang.reflect.Method.invoke(Method.java:616) [:1.6.0_20]
at org.jboss.marshalling.reflect.SerializableClass.callReadObject(SerializableClass.java:224) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doInitSerializable(RiverUnmarshaller.java:1513) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadNewObject(RiverUnmarshaller.java:1175) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:272) [:]
at org.jboss.marshalling.river.RiverUnmarshaller.doReadObject(RiverUnmarshaller.java:209) [:]
at org.jboss.marshalling.AbstractObjectInput.readObject(AbstractObjectInput.java:36) [:]
at org.infinispan.marshall.jboss.GenericJBossMarshaller.objectFromObjectStream(GenericJBossMarshaller.java:162) [:4.1.1.CR0]
at org.infinispan.marshall.VersionAwareMarshaller.objectFromByteBuffer(VersionAwareMarshaller.java:111) [:4.1.1.CR0]
at org.infinispan.marshall.AbstractMarshaller.objectFromByteBuffer(AbstractMarshaller.java:49) [:4.1.1.CR0]
at org.infinispan.marshall.MarshalledValue.deserialize(MarshalledValue.java:111) [:4.1.1.CR0]
... 74 more
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 8 months
[Hibernate-JIRA] Created: (HHH-5482) Enver Auditing: Audit Join table is missing columns or behaving incorrectly on a @ManyToOne mapping
by Mohan K (JIRA)
Enver Auditing: Audit Join table is missing columns or behaving incorrectly on a @ManyToOne mapping
---------------------------------------------------------------------------------------------------
Key: HHH-5482
URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-5482
Project: Hibernate Core
Issue Type: Bug
Components: envers
Affects Versions: 3.3.2
Environment: Hibernate: 3.3.2.GA; Envers: 1.2.2.GA; jbpm:4.1; hibernate.jpa: 3.4.0.GA
Database: MS SQL Server 2008
Reporter: Mohan K
Attachments: ManyToOne_Audit_Issue.zip
Trying to audit the Many table on the @ManyToOne relationship. The generated Audit Join table has REVTYPE and other columns missing.
Scenario:
We are using a join table to establish the Many to One relationship and we would like to Audit this join table for any changes.
As a test case: We have Person Table (person_id) & Address Table (address_id) and PersonAddress table (Join Table). Each Address can have 0 or more persons.
Our requirement is to Audit Person table and in turn PersonAddress join table for any mapping changes with respect to Person.
However the PersonAddress_Audit table that enver/hibernate creates seems to have person_id, REV columns only. We were expecting to see two other columns - address_id and REVTYPE.
Is this a bug or is there something that we are not doing right?
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators....
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
13 years, 8 months