You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
(32) |
Jun
(175) |
Jul
(209) |
Aug
(302) |
Sep
(287) |
Oct
(339) |
Nov
(314) |
Dec
(329) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
(479) |
Feb
(389) |
Mar
(599) |
Apr
(307) |
May
(390) |
Jun
(300) |
Jul
(410) |
Aug
(458) |
Sep
(299) |
Oct
(315) |
Nov
(363) |
Dec
(529) |
2005 |
Jan
(568) |
Feb
(434) |
Mar
(1004) |
Apr
(823) |
May
(767) |
Jun
(763) |
Jul
(854) |
Aug
(862) |
Sep
(560) |
Oct
(853) |
Nov
(763) |
Dec
(731) |
2006 |
Jan
(776) |
Feb
(608) |
Mar
(657) |
Apr
(424) |
May
(559) |
Jun
(440) |
Jul
(448) |
Aug
(58) |
Sep
|
Oct
(17) |
Nov
(16) |
Dec
(8) |
2007 |
Jan
(1) |
Feb
(8) |
Mar
(2) |
Apr
(5) |
May
(3) |
Jun
(3) |
Jul
(3) |
Aug
(16) |
Sep
(10) |
Oct
(4) |
Nov
(4) |
Dec
(4) |
2008 |
Jan
(8) |
Feb
(1) |
Mar
(1) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
2009 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
|
Nov
|
Dec
|
From: David D. (JIRA) <no...@at...> - 2006-07-28 19:43:38
|
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-1794?page=comments#action_23767 ] David Donn commented on HHH-1794: --------------------------------- This issue also occurs when doing something like "select new SomeDTO(a, b) from A a join a.b b". b will always be null. > HQL query (list) that SELECTs instances mixed with scalars returns NULLs (instance mappings are in a one-to-one relation) > -------------------------------------------------------------------------------------------------------------------------- > > Key: HHH-1794 > URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1794 > Project: Hibernate3 > Type: Bug > Components: core > Versions: 3.1.3 > Environment: Hibernate 3.1.3 > Postgres 8.1.2 > Java 1.5.0_06 > Reporter: Conor Tee > Attachments: hibernate-scalar-problem.tar.gz > > > Given that "a" is a table whose id is reflected in table "b" as a PRIMARY FOREIGN KEY. > Mapping a->b and b->a with the appropriate "one-to-one" mappings (I hope), then > "select a, b from A a join a.b b" > returns "a" and "b" instances correctly.. > However: (this is where I see the problem) > "select a, b, 'Some scalar' from A a join a.b b" or "select a, a.B, 'Some scalar' from A a" > returns "a" and the "scalar" correctly, but returns NULL for b! > Attached is a working example with a README, Postgres schema build script and ant "build & run" script -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Emmanuel B. (JIRA) <no...@at...> - 2006-07-28 19:41:17
|
session.lock(LockMode.FORCE) can lead to NPE -------------------------------------------- Key: HHH-1958 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1958 Project: Hibernate3 Type: Bug Components: core Versions: 3.2.0.cr3 Reporter: Emmanuel Bernard Assigned to: Emmanuel Bernard Fix For: 3.2.0.ga -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Emmanuel B. (JIRA) <no...@at...> - 2006-07-28 19:40:31
|
OF part of MEMBER OF is optional --------------------------------- Key: HHH-1947 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1947 Project: Hibernate3 Type: Bug Components: core Versions: 3.2.0.cr3 Reporter: Emmanuel Bernard Priority: Blocker Fix For: 3.2.0.ga entity_expression [NOT] MEMBER [OF] collection_valued_path_expression -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Daniel P. (JIRA) <no...@at...> - 2006-07-28 19:25:39
|
hbm2java task: meta support needed for class level annotations -------------------------------------------------------------- Key: HBX-713 URL: http://opensource.atlassian.com/projects/hibernate/browse/HBX-713 Project: Hibernate Tools Type: Bug Components: hbm2java Versions: 3.2beta6 Environment: hibernate tools 3.2 beta 6 JBoss 4.0.4.GA with EJB3 Reporter: Daniel Pocock We use hbm2java to create EJB3 entity beans from hbm files. It would be really useful to use the `meta' element to insert additional class level annotations. Is someone already working on such a feature, or should I submit a patch? Here is an example of what I would like to do: <meta attribute="extra-import">org.jboss.seam.annotations.Name</meta> <meta attributre="class-annotation">@Name("myObject")</meta> such that the following code would be generated: import javax.ejb.Entity; import org.jboss.seam.annotations.Name; @Entity @Name("myObject") public class MyObject .... -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Emmanuel B. (JIRA) <no...@at...> - 2006-07-28 19:14:56
|
[ http://opensource.atlassian.com/projects/hibernate/browse/ANN-382?pa= ge=3Dall ] Emmanuel Bernard updated ANN-382: --------------------------------- Fix Version: 3.2.0 > Exception raising : Strange behaviour depending on package names > ---------------------------------------------------------------- > > Key: ANN-382 > URL: http://opensource.atlassian.com/projects/hibernate/browse/A= NN-382 > Project: Hibernate Annotations > Type: Bug > Environment: Hibernate's annotations packaged in JBoss EJB 3.0 RC8- FD > Microsoft SQL Server 2000 > Reporter: Pierre Four=C3=A8s > Fix For: 3.2.0 > Attachments: BugEJB3.zip > > > As described in hibernate forum (http://forum.hibernate.org/viewtopic.php= ?t=3D960763) and discussed with Emmanuel, I encounter a strange behaviour w= ith annotations depending of my package's names. > Supposing hibernate load classes by package alphabetical order; if it get= the "parent" class first all works fine, if it get the "child" class first= , it raise an exception !=20 > Here is a subset of my classes, cleaned of getters, setters and all unrel= ated things, then followed by the exception stack :=20 > /////////////////////////////////////////////// > package fr.ifis.entity.field.card; > import java.io.Serializable; > import javax.persistence.Embeddable; > import javax.persistence.Entity; > import javax.persistence.Id; > import javax.persistence.ManyToOne; > import fr.ifis.entity.project.Card; > @Entity > public class CardField { > @Id > private PrimaryKey primaryKey =3D new PrimaryKey(); > =20 > // cardtmp is a trick used in order to wait for http://opensource.atla= ssian.com/projects/hibernate/browse/ANN-381 resolution=20 > @ManyToOne > private Card cardtmp; > @Embeddable > private class PrimaryKey implements Serializable { > =20 > @ManyToOne(optional =3D false) > private Card card; > =20 > @ManyToOne(optional =3D false) > private CardKey key; > } > }=20 > /////////////////////////////////////////////// > package fr.ifis.entity.field.card; > import javax.persistence.Entity; > import javax.persistence.GeneratedValue; > import javax.persistence.Id; > @Entity > public class CardKey { > @Id > @GeneratedValue > private int id; > }=20 > /////////////////////////////////////////////// > package fr.ifis.entity.project; > import java.io.Serializable; > import java.util.Set; > import javax.persistence.CascadeType; > import javax.persistence.Embeddable; > import javax.persistence.Entity; > import javax.persistence.FetchType; > import javax.persistence.Id; > import javax.persistence.ManyToOne; > import javax.persistence.OneToMany; > import fr.ifis.entity.field.card.CardField; > @Entity > public class Card { > @Id > private CardPrimaryKey primaryKey =3D new CardPrimaryKey(); > =20 > @OneToMany(cascade=3DCascadeType.ALL, fetch=3DFetchType.EAGER, mappedB= y=3D"cardtmp") // > private Set<CardField> fields; > =20 > @Embeddable > private class CardPrimaryKey implements Serializable { > =20 > @ManyToOne(optional =3D false) > private Project project; > =20 > //An other @ManyToOne is also present in the real model > //The problem still occurs even when i remove this relation, it was= no use to kept it for describe the problem > } > }=20 > /////////////////////////////////////////////// > package fr.ifis.entity.project; > import javax.persistence.Entity; > import javax.persistence.GeneratedValue; > import javax.persistence.Id; > @Entity > public class Project { > @Id > @GeneratedValue > private int id; > }=20 > /////////////////////////////////////////////// > [java] ERROR 29-06 19:42:18,272 (AbstractController.java:incrementSt= ate:350) -Error installing to Start: name=3Dpersistence.units:unitName=3DR= efonte state=3DCreate > [java] org.hibernate.MappingException: Foreign key (FK6771BFAA1845E8= B:CardField [])) must have same number of columns as the referenced primary= key (Card [project_id]) > [java] at org.hibernate.mapping.ForeignKey.alignColumns(ForeignKey.j= ava:90) > [java] at org.hibernate.mapping.ForeignKey.alignColumns(ForeignKey.j= ava:73) > [java] at org.hibernate.cfg.Configuration.secondPassCompileForeignKe= ys(Configuration.java:1182) > [java] at org.hibernate.cfg.Configuration.secondPassCompile(Configur= ation.java:1089) > [java] at org.hibernate.cfg.AnnotationConfiguration.secondPassCompil= e(AnnotationConfiguration.java:302) > [java] at org.hibernate.cfg.Configuration.buildMappings(Configuratio= n.java:1034) > [java] at org.hibernate.ejb.Ejb3Configuration.buildMappings(Ejb3Conf= iguration.java:1015) > [java] at org.hibernate.ejb.EventListenerConfigurator.configure(Even= tListenerConfigurator.java:154) > [java] at org.hibernate.ejb.Ejb3Configuration.createEntityManagerFac= tory(Ejb3Configuration.java:751) > [java] at org.hibernate.ejb.Ejb3Configuration.createContainerEntityM= anagerFactory(Ejb3Configuration.java:350) > [java] at org.hibernate.ejb.HibernatePersistence.createContainerEnti= tyManagerFactory(HibernatePersistence.java:119) > [java] at org.jboss.ejb3.entity.PersistenceUnitDeployment.start(Pers= istenceUnitDeployment.java:264) > [java] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method= ) > [java] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAc= cessorImpl.java:39) > [java] at sun.reflect.DelegatingMethodAccessorImpl.invoke(Delegating= MethodAccessorImpl.java:25) > [java] at java.lang.reflect.Method.invoke(Method.java:585) > [java] at org.jboss.reflect.plugins.introspection.ReflectionUtils.in= voke(ReflectionUtils.java:55) > [java] at org.jboss.reflect.plugins.introspection.ReflectMethodInfoI= mpl.invoke(ReflectMethodInfoImpl.java:107) > [java] at org.jboss.joinpoint.plugins.BasicMethodJoinPoint.dispatch(= BasicMethodJoinPoint.java:66) > [java] at org.jboss.kernel.plugins.dependency.KernelControllerContex= tActions.dispatchJoinPoint(KernelControllerContextActions.java:100) > [java] at org.jboss.kernel.plugins.dependency.KernelControllerContex= tActions$LifecycleAction.installAction(KernelControllerContextActions.java:= 582) > [java] at org.jboss.kernel.plugins.dependency.KernelControllerContex= tActions$KernelControllerContextAction.install(KernelControllerContextActio= ns.java:175) > [java] at org.jboss.dependency.plugins.AbstractControllerContextActi= ons.install(AbstractControllerContextActions.java:51) > [java] at org.jboss.dependency.plugins.AbstractControllerContext.ins= tall(AbstractControllerContext.java:226) > [java] at org.jboss.dependency.plugins.AbstractController.install(Ab= stractController.java:593) > [java] at org.jboss.dependency.plugins.AbstractController.incrementS= tate(AbstractController.java:346) > [java] at org.jboss.dependency.plugins.AbstractController.resolveCon= texts(AbstractController.java:438) > [java] at org.jboss.dependency.plugins.AbstractController.resolveCon= texts(AbstractController.java:379) > [java] at org.jboss.dependency.plugins.AbstractController.install(Ab= stractController.java:225) > [java] at org.jboss.dependency.plugins.AbstractController.install(Ab= stractController.java:151) > [java] at org.jboss.kernel.plugins.dependency.AbstractKernelControll= er.install(AbstractKernelController.java:79) > [java] at org.jboss.kernel.plugins.dependency.AbstractKernelControll= er.install(AbstractKernelController.java:73) > [java] at org.jboss.ejb3.MCKernelAbstraction.install(MCKernelAbstrac= tion.java:91) > [java] at org.jboss.ejb3.Ejb3Deployment.startPersistenceUnits(Ejb3De= ployment.java:626) > [java] at org.jboss.ejb3.Ejb3Deployment.start(Ejb3Deployment.java:47= 5) > [java] at org.jboss.ejb3.embedded.EJB3StandaloneDeployer.start(EJB3S= tandaloneDeployer.java:460) > [java] at org.jboss.ejb3.embedded.EJB3StandaloneBootstrap.scanClassp= ath(EJB3StandaloneBootstrap.java:291) > [java] at fr.ifis.Main.main(Unknown Source) > /////////////////////////////////////////////// > Indeed, depending on the package names I get or not an excpetion ! > It doesn't work with the package fr.ifis.entity.project but if I rename t= he package in fr.ifis.entity.aproject and then move it "before" the field.c= ard package, all works fine. > In order to facilitate the identification of the problem, I also include = as attachement the eclipse project of this problem repport. > In order to keep reasonable the size of the attachement, I did not includ= ed the libraries nor the configuration files for launch ejb3-embedded. Thos= es files are issued from the project simple-deployment included in JBoss EJ= B 3.0 RC8-FD. The only change i've done was to specify in embedded-jboss-be= ans.xml the properties of my database. > Regards, > Pierre. --=20 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= .jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Jacob B. (JIRA) <no...@at...> - 2006-07-28 17:50:18
|
Double methods generated in dao layer for named queries with pojo names starting with the same name --------------------------------------------------------------------------------------------------- Key: HBX-714 URL: http://opensource.atlassian.com/projects/hibernate/browse/HBX-714 Project: Hibernate Tools Type: Bug Environment: Wondows Xp, Eclipse 3.2 Hibernate tools 3.2.beta6a, Ant 1.6.5, JDK 1.5.0_06 Reporter: Jacob Bergoo Priority: Critical This is the file for my named queries: <?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> <query name="com.mycompany.business.model.AppUser.findByUsername"> from AppUser where userName=:username <query-param name="userName" type="string" /> </query> <query name="com.mycompany.business.model.AppUserRole.findByUserRole"> from AppUserRole where userRole=:userRole <query-param name="userRole" type="string" /> </query> </hibernate-mapping> This Queries is for two different pojos and I want them to end up in the corresponding dao classes. But becouse they have a name that is similar... AppUser and AppUserRole this means that both methods ends up in AppUserDao and one in AppUserRoleDao.... I have tried this also with other classes that share that same name prefix and I have the same behavior there... -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Eric S. (JIRA) <no...@at...> - 2006-07-28 15:23:21
|
Interceptor.afterTransactionCompletion not called with JTATransaction (CacheSynchronization.hibernateTransaction not set) ------------------------------------------------------------------------------------------------------------------------- Key: HHH-1956 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1956 Project: Hibernate3 Type: Bug Components: core Versions: 3.1.2 Environment: JBoss 4.0.3SP1 under Windows XP Reporter: Eric Sword interceptor.afterTransactionCompletion should be invoked in SessionImpl.afterTransactionCompletion, but it is only called if the tx parameter is not null. When running under a JTA environment, that parameter will always be null. This is the stack which leads to the call (line numbers are from v3.1.2 code): org.hibernate.impl.SessionImpl.afterTransactionCompletion(boolean, org.hibernate.Transaction) line: 442 org.hibernate.jdbc.JDBCContext.afterTransactionCompletion(boolean, org.hibernate.Transaction) line: 205 org.hibernate.transaction.CacheSynchronization.afterCompletion(int) line: 85 org.jboss.tm.TransactionImpl.doAfterCompletion() line: 1508 org.jboss.tm.TransactionImpl.completeTransaction() line: 1180 org.jboss.tm.TransactionImpl.commit() line: 359 org.jboss.tm.TxManager.commit() line: 224 org.jboss.tm.usertx.client.ServerVMClientUserTransaction.commit() line: 126 org.hibernate.transaction.JTATransaction.commit() line: 146 The problem is that the hibernateTransaction member variable of the CacheSynchronization object is never set. Here is the call stack for how that object is created: org.hibernate.transaction.CacheSynchronization.<init>(org.hibernate.transaction.TransactionFactory$Context, org.hibernate.jdbc.JDBCContext, javax.transaction.Transaction, org.hibernate.Transaction) line: 34 org.hibernate.jdbc.JDBCContext.registerSynchronizationIfPossible() line: 149 org.hibernate.transaction.JTATransaction.begin() line: 102 org.hibernate.impl.SessionImpl.beginTransaction() line: 1309 com.osc.util.hibernate.HibernateManager.getSession(org.hibernate.Interceptor) line: 204 You can see in the JDBCContext.registerSynchronizationIfPossible() method that the parameter to set the transaction is always null, even though the JDBCContext object does have a reference to the hibernateTransaction at that point. The CacheSynchronization only uses that reference for beforeTransactionCompletion and afterTransactionCompletion calls. The beforeTransactionCompletion works because the SessionImpl.beforeTransactionCompletion call doesn't check if the tx is null, while the afterTransactionCompletion does. -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Paras D. (JIRA) <no...@at...> - 2006-07-28 12:52:27
|
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-1902?page=comments#action_23796 ] Paras Dhawan commented on HHH-1902: ----------------------------------- A test case cannot be given to you as it also requires all the mapping classes and code of our query parser But I will try to explain you the scenario... actually we are giving a complex attribute in the select list e.g. city.state.country.[region,country].population such type of attributes are resolved by our query parser the meaning of such attributes is city is containing an object of state (many to one) and state contains an object of country (again many to one), region contains an object of country (one to many) and we want the population of region such attributes form a subquery ... which is formed by our query parser.... we also want to order the results thus an order by clause is added on the same attribute city.state.country.[region,country].population The query parser forms a sub query and assigns an alias 'sqry1' as the same column is added in the order by clause also thus this alias is added in the order by clause the query form like this (query is similar to this query) select (select SUM(servicecha3_.ChargeAmount) from Services service2_, ServiceCharges servicecha3_ where transports1_.TransportServiceId=service2_.ServiceId and service2_.ServiceId=servicecha3_.serviceGroupTablePKId) as col_0_0_ from Challans challan0_ left outer join TransportServices transports1_ on challan0_.TransportServiceId=transports1_.TransportServiceId left outer join Services transports1_1_ on transports1_.TransportServiceId=transports1_1_.ServiceId order by _sqry1 now the hibernate replaces our alias from sqry1 to col_0_0_ but it does not replaces this alias in the order by clause... thus the alias sqry1 becomes undefined now and it gives an error Thus hibernate is just replacing our alias where it is formed but not at the place where we are using it > Alias Problem... Hibernate is replacing our alias at one place but not at another place > --------------------------------------------------------------------------------------- > > Key: HHH-1902 > URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1902 > Project: Hibernate3 > Type: Bug > Components: query-hql > Versions: 3.0.3 > Environment: Hibernate 3.0.3 > Database Platform : MSSQL Server 2000 > Reporter: Paras Dhawan > > > I have a query which contains a sub query in the select list... I have defined an alias of the sub query as _sqry1 now I am putting an Order By clause in the query.... Order By is on the result of the sub query and I have given the alias of the sub query in the Order By clause > My Query is which i am giving to Hibernate is > SELECT (SELECT SUM(_0_ServiceCharge_0_service.chargeAmount) FROM Service AS _0_service , ServiceCharge AS _0_ServiceCharge_0_service WHERE _transportService_Challan = _0_service AND _0_service = _0_ServiceCharge_0_service.service) AS _sqry1 FROM Challan AS _Challan LEFT OUTER JOIN _Challan.transportService AS _transportService_Challan ORDER BY _sqry1 > Now the problem is that Hibernate is replacing my aliases.... it replaced my alias of the sub query from _sqry1 to col_0_0_ .... it replaced this alias in the select list but not in the Order By clause... i.e. it replaced the alias where I defined it but it did not replaced the alias where I used it.... so the place where I am using the alias it is giving an error as undefined alias > The generated SQL by Hibernate: > select (select SUM(servicecha3_.ChargeAmount) from Services service2_, ServiceCharges servicecha3_ where transports1_.TransportServiceId=service2_.ServiceId and service2_.ServiceId=servicecha3_.serviceGroupTablePKId) as col_0_0_ from Challans challan0_ left outer join TransportServices transports1_ on challan0_.TransportServiceId=transports1_.TransportServiceId left outer join Services transports1_1_ on transports1_.TransportServiceId=transports1_1_.ServiceId order by _sqry1 > when I manually replaced my alias in the Order By clause then my query run successfully > Either Hibernate should not replace my alias, even if it is replacing then it must replace all the occurences > I cannot use criteria, I cannot use named queries, i cannot use native sql because my queries are formed at run time, I have to specify a HQL only... This is bug in Hibernate > Hibernate version: 3.0.5 > Name and version of the database that I am using: > MS SQL Server 2000 > Full stack trace of any exception that occurs: > Exception in thread "main" org.hibernate.exception.SQLGrammarException: could not execute query > at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:67) > at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43) > at org.hibernate.loader.Loader.doList(Loader.java:2148) > at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2029) > at org.hibernate.loader.Loader.list(Loader.java:2024) > at org.hibernate.loader.hql.QueryLoader.list(QueryLoader.java:375) > at org.hibernate.hql.ast.QueryTranslatorImpl.list(QueryTranslatorImpl.java:308) > at org.hibernate.engine.query.HQLQueryPlan.performList(HQLQueryPlan.java:153) > at org.hibernate.impl.SessionImpl.list(SessionImpl.java:1106) > at org.hibernate.impl.QueryImpl.list(QueryImpl.java:79) > at com.daffodilwoods.framework.utils.HibernateUtil.main(HibernateUtil.java:296) > Caused by: java.sql.SQLException: [DataDirect][SQLServer JDBC Driver][SQLServer]Invalid column name '_sqry1'. > at com.ddtek.jdbc.base.BaseExceptions.createException(Unknown Source) > at com.ddtek.jdbc.base.BaseExceptions.getException(Unknown Source) > at com.ddtek.jdbc.sqlserver.tds.TDSRequest.processErrorToken(Unknown Source) > at com.ddtek.jdbc.sqlserver.tds.TDSRequest.processReplyToken(Unknown Source) > at com.ddtek.jdbc.sqlserver.tds.TDSRPCRequest.processReplyToken(Unknown Source) > at com.ddtek.jdbc.sqlserver.tds.TDSRequest.processReply(Unknown Source) > at com.ddtek.jdbc.sqlserver.tds.TDSRPCNonCursorExecuteRequest.submitPrepare(Unknown Source) > at com.ddtek.jdbc.sqlserver.tds.TDSRPCExecuteRequest.doPrepExec(Unknown Source) > at com.ddtek.jdbc.sqlserver.tds.TDSRPCExecuteRequest.execute(Unknown Source) > at com.ddtek.jdbc.sqlserver.SQLServerImplStatement.execute(Unknown Source) > at com.ddtek.jdbc.base.BaseStatement.commonExecute(Unknown Source) > at com.ddtek.jdbc.base.BaseStatement.executeQueryInternal(Unknown Source) > at com.ddtek.jdbc.base.BasePreparedStatement.executeQuery(Unknown Source) > at org.hibernate.jdbc.AbstractBatcher.getResultSet(AbstractBatcher.java:139) > at org.hibernate.loader.Loader.getResultSet(Loader.java:1669) > at org.hibernate.loader.Loader.doQuery(Loader.java:662) > at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loader.java:224) > at org.hibernate.loader.Loader.doList(Loader.java:2145) > ... 8 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Emmanuel B. (JIRA) <no...@at...> - 2006-07-28 12:31:08
|
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-1947?page=comments#action_23773 ] Emmanuel Bernard commented on HHH-1947: --------------------------------------- test added to HqlParserTest.testEjbqlExtensions() > OF part of MEMBER OF is optional > --------------------------------- > > Key: HHH-1947 > URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1947 > Project: Hibernate3 > Type: Bug > Components: core > Versions: 3.2.0.cr3 > Reporter: Emmanuel Bernard > Priority: Blocker > Fix For: 3.2.0.ga > > > entity_expression [NOT] MEMBER [OF] collection_valued_path_expression -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: David H. (JIRA) <no...@at...> - 2006-07-28 12:30:34
|
[ http://opensource.atlassian.com/projects/hibernate/browse/ANN-261?page=all ] David Hay updated ANN-261: -------------------------- Attachment: hibernate-annotation-3.2.0.CR2-fk2.patch Attaching updated patch that adds ForeignKey support for ManyToMany relationships. ForeignKey annotation now supports "inverseName" to define the foreign key on the non-owning side of the relationship. > Allow specifying foreign key constraint name using annotations > -------------------------------------------------------------- > > Key: ANN-261 > URL: http://opensource.atlassian.com/projects/hibernate/browse/ANN-261 > Project: Hibernate Annotations > Type: Improvement > Components: binder > Versions: 3.1beta8 > Reporter: Paul Barry > Priority: Minor > Attachments: hibernate-annotation-3.2.0.CR2-fk2.patch, hibernate-annotations-3.2.0.CR1-fk.patch, hibernate-annotations-fk.patch > > > Using hbm.xml configuration for many-to-one, there is a foreign-key property that allows you to specify the name of the FK constraint. It would be nice if there was something similar for annotations, such as @ManyToOne ( constraintName = "FK_WHATEVER"). Also, a sensible default would be nice to, for example FK_TABLE_NAME_COLUMN_NAME, rather than FK20708CF6792111. I know Oracle has a 30 char limit for constraint names, so there would have to me some logic to find a way to abbreviate it. -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Max R. A. (JIRA) <no...@at...> - 2006-07-28 12:22:20
|
[ http://opensource.atlassian.com/projects/hibernate/browse/HBX-709?page=comments#action_23795 ] Max Rydahl Andersen commented on HBX-709: ----------------------------------------- it is in releng module of jbosside. I recommend try and talk about this on the jboss ide maling list or dev forum since it is actually there the packaging occurs. It will be much appreciated. > Start distributing an eclipse Hibernate Tools runtime only JAR > -------------------------------------------------------------- > > Key: HBX-709 > URL: http://opensource.atlassian.com/projects/hibernate/browse/HBX-709 > Project: Hibernate Tools > Type: Task > Reporter: Darryl Miles > Attachments: feature.xml > > > http://forum.hibernate.org/viewtopic.php?t=962374 > Start to pickup and use Eclipse/WTP versioning within the features.xml/ > Plan of action as I see it: > * Copy features/org.eclipse.* and features.org.apache.* files as well as pre-requisite plugins/* when packaging. > * Move <plugin ...> into <import ...> in features/org.hibernate.eclipse.feature_3.2.0.beta6a/feature.xml (see attached sample of this working for me) > * Modify build and packaging process to now create two JARs. > JAR one contains (this is the runtime only JAR): > features/org.hibernate.eclipse.feature* > plugins/org.hibernate.eclipse* > plugins/org.jboss.ide.eclipse.freemarker* > JAR two contains (this is the equivalent of what is distrubuted now, hibernate tools, with WTP/XSD/GEF/JEM pre-requisites, without Eclipse Platform) > All the files in JAR one above, plus > plugins/org.eclipse.gef* > plugins/org.eclipse.wst.xml_core.feature.* > plugins/org.eclipse.wst.common_core.feature* > plugins/org.eclipse.wst.common_ui.feature* > plugins/org.apache.xerces.feature* > plugins/org.eclipse.xsd* > plugins/org.eclipse.jem* > plugins/org.eclipse.wst.xml_ui.feature* > plugins/org.eclipse.emf* > features/org.eclipse.gef* > features/org.eclipse.wst.xml_core.feature_* > features/org.eclipse.wst.common_core.feature_* > features/org.eclipse.wst.common_ui.feature_* > features/org.apache.xerces.feature_* > features/org.eclipse.xsd_* > features/org.eclipse.jem_* > features/org.eclipse.wst.xml_ui.feature_* > features/org.eclipse.emf_* > By removing the <plugin ..> declarations from the hibernate JAR it stops the JAR claiming it is the authorative source for that plugin to the update manager. By including the original features/ files from the original authorative source means that if a user installs pre-requisites (or has pre-requisites already installed) when they use JAR two, and restart Eclipse will automatically pickup and use the lastest installed version of WTP/XSD/EMF/GEF/JEM compatible with hibernate tools. > This has the effect is automatically upgrading the version of pre-requisites when multiple versions are found. But in the event the users version of pre-requisites is too old or non-existant then the ones in the JAR two will be picked up and used. > If the re-packaged version of freemarker is also being used inside other JBOSS plugins, then I would suggest a seperate feature/org.jboss.ide.eclipse.freemarker*/feature.xml be provided and all plugins built on top are then to pickup that with an <import ...> declaration. If hibernate tools is the only user of freemarker then leading it inside hibernate tools is fine. -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: David H. (JIRA) <no...@at...> - 2006-07-28 10:04:51
|
[ http://opensource.atlassian.com/projects/hibernate/browse/ANN-261?page=comments#action_23787 ] David Hay commented on ANN-261: ------------------------------- Latest patch is misnamed. Should be applied to CR1, not CR2 > Allow specifying foreign key constraint name using annotations > -------------------------------------------------------------- > > Key: ANN-261 > URL: http://opensource.atlassian.com/projects/hibernate/browse/ANN-261 > Project: Hibernate Annotations > Type: Improvement > Components: binder > Versions: 3.1beta8 > Reporter: Paul Barry > Priority: Minor > Attachments: hibernate-annotation-3.2.0.CR2-fk2.patch, hibernate-annotations-3.2.0.CR1-fk.patch, hibernate-annotations-fk.patch > > > Using hbm.xml configuration for many-to-one, there is a foreign-key property that allows you to specify the name of the FK constraint. It would be nice if there was something similar for annotations, such as @ManyToOne ( constraintName = "FK_WHATEVER"). Also, a sensible default would be nice to, for example FK_TABLE_NAME_COLUMN_NAME, rather than FK20708CF6792111. I know Oracle has a 30 char limit for constraint names, so there would have to me some logic to find a way to abbreviate it. -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Jens S. (JIRA) <no...@at...> - 2006-07-28 07:33:10
|
[ http://opensource.atlassian.com/projects/hibernate/browse/HB-534?page=comments#action_23765 ] Jens Schumacher commented on HB-534: ------------------------------------ This issue was marked as closed. Any information about which version of Hibernate contains the patch? Cheers, Jens > Table schema use in DatabaseMetadata > ------------------------------------ > > Key: HB-534 > URL: http://opensource.atlassian.com/projects/hibernate/browse/HB-534 > Project: Hibernate2 > Type: Bug > Components: core > Versions: 2.1 beta 4 > Environment: Hibernate 2.1 beta 4, Oracle 8i > Reporter: Adrien > Attachments: DatabaseMetadata.java, HB-534_patch.txt, TableMetadata.java > > > When using SchemaUpdate, the DatabaseMetaData.getTableMetadata() looks for a table with the correct table name in any database schema and it take the first one it found. This behavior is uncorrect if I have a table existing in different schemas. > The correct behavior would be to first look in the schema with the login name and after in any schema. > user1.article > user2.article > I connected whith user2, DatabaseMetaData should first look for user2.article, then if not found to %.article. > Adrien -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Simon V. (JIRA) <no...@at...> - 2006-07-28 06:49:17
|
Query.iterate() results differ from Query.list().iterator() ----------------------------------------------------------- Key: HHH-1946 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1946 Project: Hibernate3 Type: Bug Components: query-hql Versions: 3.1.3 Environment: Hibernate 3.1.3 Sun JVM 1.5.0_06 Windows XP Reporter: Simon Vos Priority: Critical While trying to migrate our code base from hibernate 2.1.8 to hibernate 3.1.3 I came across a weird problem. In one method a hibernate query is created to retrieve some results from the database, I know that there are three corresponding results in the database for this query. The code used for this is: rsIterator = query.iterate(); while (rsIterator.hasNext()) { Relationship current = (Relationship) rsIterator.next(); NaturalPerson person = (NaturalPerson) sess.get(NaturalPerson.class, new Niss(current.getSpouseNiss()).toLong()); if (person != null) { current.setSpouseFirstName(person.getFirstName()); current.setSpouseLastName(person.getLastName()); } else log.info("No naturalPerson object could be retrieved for the person with niss number " + current.getSpouseNiss().toString()); relations.add(current); } In hibernate 2.1.8 this method worked correctly and it added 3 results to the relations object. But while migrating one of my tests failed, because this method returned only 2 results. Then I tried using query.list().iterator() instead of query.iterate() and this gave me the correct three results.. -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Maarten W. (JIRA) <no...@at...> - 2006-07-28 00:59:16
|
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-1954?page=all ] Maarten Winkels updated HHH-1954: --------------------------------- Attachment: proxy-evict.patch This one-line fix sets the session of a proxy to NULL when evicting. This solves the problem and all other tests run fine. > Proxies are never unassociated (evicted) from a session > ------------------------------------------------------- > > Key: HHH-1954 > URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1954 > Project: Hibernate3 > Type: Bug > Versions: 3.2.0.cr3 > Reporter: Maarten Winkels > Attachments: Person.hbm.xml, Person.java, ProxyEvictTest.java, proxy-evict.patch > > > When evicting (either directly or by cascade) a proxy from a session, the proxy is removed from an internal map (proxiesByKey), but the proxy's lazy initializer still has reference to the session. This allows for lazy initialization of a proxy even after the proxy is evicted. This seems semantically incorrect: The documentation of LazyInitializer.getSession() reads: "Get the session, if this proxy is attached" an proxy evicted from a session should cleary not remain attached to the session. > The current implementation leads to concurrent modification exceptions, when one thread detaches entities from one session and another attaches these entities to another. The method AbstractLazyInitializer.isConnectedToSession() is called when locking a proxy to a session. This will search the old session for the proxy (in the containsProxy() call). When another thread is manipulating this sessions proxy ByLey map, a concurrent modification exception will occure. > Note that each session is used in a thread-safe context by the application! When reassociating a proxy to the new session, hibernate breaks the thread-safety by querying the other session. -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Maarten W. (JIRA) <no...@at...> - 2006-07-28 00:52:19
|
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-1954?page=all ] Maarten Winkels updated HHH-1954: --------------------------------- Attachment: ProxyEvictTest.java Person.java Person.hbm.xml The attached testcase shows the behaviour. It also shows the difference in behaviour when evicting a lazy collection or a proxy. > Proxies are never unassociated (evicted) from a session > ------------------------------------------------------- > > Key: HHH-1954 > URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1954 > Project: Hibernate3 > Type: Bug > Versions: 3.2.0.cr3 > Reporter: Maarten Winkels > Attachments: Person.hbm.xml, Person.java, ProxyEvictTest.java > > > When evicting (either directly or by cascade) a proxy from a session, the proxy is removed from an internal map (proxiesByKey), but the proxy's lazy initializer still has reference to the session. This allows for lazy initialization of a proxy even after the proxy is evicted. This seems semantically incorrect: The documentation of LazyInitializer.getSession() reads: "Get the session, if this proxy is attached" an proxy evicted from a session should cleary not remain attached to the session. > The current implementation leads to concurrent modification exceptions, when one thread detaches entities from one session and another attaches these entities to another. The method AbstractLazyInitializer.isConnectedToSession() is called when locking a proxy to a session. This will search the old session for the proxy (in the containsProxy() call). When another thread is manipulating this sessions proxy ByLey map, a concurrent modification exception will occure. > Note that each session is used in a thread-safe context by the application! When reassociating a proxy to the new session, hibernate breaks the thread-safety by querying the other session. -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Maarten W. (JIRA) <no...@at...> - 2006-07-28 00:46:20
|
Proxies are never unassociated (evicted) from a session ------------------------------------------------------- Key: HHH-1954 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1954 Project: Hibernate3 Type: Bug Versions: 3.2.0.cr3 Reporter: Maarten Winkels When evicting (either directly or by cascade) a proxy from a session, the proxy is removed from an internal map (proxiesByKey), but the proxy's lazy initializer still has reference to the session. This allows for lazy initialization of a proxy even after the proxy is evicted. This seems semantically incorrect: The documentation of LazyInitializer.getSession() reads: "Get the session, if this proxy is attached" an proxy evicted from a session should cleary not remain attached to the session. The current implementation leads to concurrent modification exceptions, when one thread detaches entities from one session and another attaches these entities to another. The method AbstractLazyInitializer.isConnectedToSession() is called when locking a proxy to a session. This will search the old session for the proxy (in the containsProxy() call). When another thread is manipulating this sessions proxy ByLey map, a concurrent modification exception will occure. Note that each session is used in a thread-safe context by the application! When reassociating a proxy to the new session, hibernate breaks the thread-safety by querying the other session. -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: David Ng (JIRA) <no...@at...> - 2006-07-28 00:31:27
|
Problem with hibernate proxy object and ClassMetaData ----------------------------------------------------- Key: HHH-1953 URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1953 Project: Hibernate3 Type: Bug Versions: 3.1.2 Environment: Tested environment: - Hibernate 3.1.2 - Hibernate 3.1.3 - Postgresql 8.1 - Jdk 1.5.0_06 - Windows XP SP2 and Linux Reporter: David Ng Priority: Critical Hi, The problem can be summarised as follow: - If an hibernate entity object has proxy attribute is defined inside class node of hbm.xml file, ClassMetaData.getPropertyValue() of any property will throw IllegalArgumentException; - Regardless whether Reflection API is used or hibernate.cglib.use_reflection_optimizer is either set to true or false; - If the proxy attribute is not defined, ClassMetaData::getPropertyValue() / ClassMetaData::getPropertyValues() returns the values successfully; and - Accessing the TsRecStat property by invoking TsPassword::getTsRecStat() does not cause exception to be thrown in any of the case. My question: - If reflection API should not be used to access the property value, shouldn't hibernate ClassMetaData API be used to access the property value? 2 postings have been made in regard to this on hibernate forum: http://forum.hibernate.org/viewtopic.php?t=955828 http://forum.hibernate.org/viewtopic.php?t=958029 ======================================================================================================================== THE TEST CODE: public void testAccessingTsPasswordProxyWithClassMetaDataAPI() { Session currentSession = null; Transaction transaction = null; try { ClassMetadata passwordClassMetaData = m_sessionFactory.getClassMetadata( TsPassword.class ); currentSession = m_sessionFactory.openSession(); transaction = currentSession.beginTransaction(); Query query = currentSession.createQuery( "FROM TsPassword AS p" ); Iterator it = query.iterate(); while( it.hasNext() ) { Object obj = it.next(); ITsPassword itspassword = (ITsPassword) obj; Date tsExpiryTimestamp = itspassword.getTsExpiryTimestamp(); passwordClassMetaData.getPropertyValue( itspassword, "TsRecStat", EntityMode.POJO ); Object expiryFromPasswordInterface = passwordClassMetaData.getPropertyValue( itspassword, "TsExpiryTimestamp", EntityMode.POJO ); assertEquals( "Expiry timestamp from interface", tsExpiryTimestamp, expiryFromPasswordInterface ); Object propertyValue = passwordClassMetaData.getPropertyValue( obj, "TsExpiryTimestamp", EntityMode.POJO ); assertEquals( "Expiry timestamp from raw object", tsExpiryTimestamp, propertyValue ); } transaction.commit(); } catch( HibernateException he ) { he.printStackTrace(); fail( "Hibernate exception occurred." ); if( transaction != null ) { transaction.rollback(); } } catch( Exception e ) { e.printStackTrace(); fail( "Something else exception occured." ); if( transaction != null ) { transaction.rollback(); } } finally { if( currentSession != null ) { currentSession.close(); } } } Line 78 is passwordClassMetaData.getPropertyValue( itspassword, "TsRecStat", EntityMode.POJO ); The exception: IllegalArgumentException in class: com.tokuii.baseapp.conf.redbull.v1.data.TsPassword, getter method of property: TsRecStat org.hibernate.PropertyAccessException: IllegalArgumentException occurred calling getter of com.tokuii.baseapp.conf.redbull.v1.data.TsPassword.TsRecStat at org.hibernate.property.BasicPropertyAccessor$BasicGetter.get(BasicPropertyAccessor.java:171) at org.hibernate.tuple.AbstractEntityTuplizer.getPropertyValue(AbstractEntityTuplizer.java:270) at org.hibernate.tuple.AbstractEntityTuplizer.getPropertyValue(AbstractEntityTuplizer.java:280) at org.hibernate.persister.entity.AbstractEntityPersister.getPropertyValue(AbstractEntityPersister.java:3252) at com.tokuii.tests.component.hibernate.HibernateProxyTest.testAccessingTsPasswordProxyWithClassMetaDataAPI(Hibe rnateProxyTest.java:78) Caused by: java.lang.IllegalArgumentException: object is not an instance of declaring class at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:585) at org.hibernate.property.BasicPropertyAccessor$BasicGetter.get(BasicPropertyAccessor.java:145) ... 50 more Hbm.xml: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD//EN" "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd"> <hibernate-mapping> <class name="com.tokuii.baseapp.conf.redbull.v1.data.TsPassword" table="TsPassword" proxy="com.tokuii.system.ITsPassword"> <id name="Id" type="long" unsaved-value="0"> <generator class="native"/> </id> <version column="TsVersion" name="TsVersion"/> <many-to-one name="TsCreateUser" class="com.tokuii.baseapp.conf.redbull.v1.data.TsUser"/> <many-to-one name="TsModifyUser" class="com.tokuii.baseapp.conf.redbull.v1.data.TsUser"/> <property name="TsCreateTimestamp" type="timestamp" column="TsCreateTimestamp" not-null="false"/> <property name="TsModifyTimestamp" type="timestamp" column="TsModifyTimestamp" not-null="false"/> <property name="TsRecStat" type="java.lang.String" column="TsRecStat" not-null="false"/> <property name="TsSysRowState" type="java.lang.String" column="TsSysRowState" not-null="false"/> <property name="TsExpiryTimestamp" type="timestamp" column="TsExpiryTimestamp" not-null="false"/> <property name="TsPassword" type="java.lang.String" column="TsPassword" not-null="false" length="50"/> <property name="TsPwChangeRestriction" type="java.lang.Boolean" column="TsPwChangeRestriction" not-null="false"/> <property name="TsPwValidity" type="java.lang.String" column="TsPwValidity" not-null="false"/> </class> </hibernate-mapping> The TsPassword.java: public class TsPassword implements com.tokuii.system.ITsPassword { private java.lang.Long m_Id; private int m_TsVersion = 1; private com.tokuii.system.ITsUser m_TsCreateUser; private com.tokuii.system.ITsUser m_TsModifyUser; private java.util.Date m_TsCreateTimestamp; private java.util.Date m_TsModifyTimestamp; private java.lang.String m_TsRecStat = "A"; private java.lang.String m_TsSysRowState = "P"; private java.util.Date m_TsExpiryTimestamp; private java.lang.String m_TsPassword; // Natural Identifier private java.lang.Boolean m_TsPwChangeRestriction; private java.lang.String m_TsPwValidity; private com.tokuii.system.ITsUser m_TsUserId; // Natural Identifier private java.util.Set m_TsPasswordIdTsUser; /** Non-persistent field. */ private java.util.Map m_NonDBFields; public TsPassword() { } public java.lang.Long getId() { return m_Id; } public void setId(java.lang.Long newId) { m_Id = newId; } public int getTsVersion() { return m_TsVersion; } public void setTsVersion(int newTsVersion) { m_TsVersion = newTsVersion; } public Object getNonDBField(String fieldName) { synchronized (this) { if (m_NonDBFields == null) { return null; } return m_NonDBFields.get(fieldName); } } public void setNonDBField(String fieldName, Object value) { synchronized (this) { if (m_NonDBFields == null) { m_NonDBFields = new java.util.HashMap(); } m_NonDBFields.put(fieldName, value); } } public com.tokuii.system.ITsUser getTsCreateUser() { return m_TsCreateUser; } public void setTsCreateUser(com.tokuii.system.ITsUser newTsCreateUser) { m_TsCreateUser = newTsCreateUser; } public com.tokuii.system.ITsUser getTsModifyUser() { return m_TsModifyUser; } public void setTsModifyUser(com.tokuii.system.ITsUser newTsModifyUser) { m_TsModifyUser = newTsModifyUser; } public java.util.Date getTsCreateTimestamp() { return m_TsCreateTimestamp; } public void setTsCreateTimestamp(java.util.Date newTsCreateTimestamp) { m_TsCreateTimestamp = newTsCreateTimestamp; } public java.util.Date getTsModifyTimestamp() { return m_TsModifyTimestamp; } public void setTsModifyTimestamp(java.util.Date newTsModifyTimestamp) { m_TsModifyTimestamp = newTsModifyTimestamp; } public java.lang.String getTsRecStat() { return m_TsRecStat; } public void setTsRecStat(java.lang.String newTsRecStat) { m_TsRecStat = newTsRecStat; } public java.lang.String getTsSysRowState() { return m_TsSysRowState; } public void setTsSysRowState(java.lang.String newTsSysRowState) { m_TsSysRowState = newTsSysRowState; } public java.util.Date getTsExpiryTimestamp() { return m_TsExpiryTimestamp; } public void setTsExpiryTimestamp(java.util.Date newTsExpiryTimestamp) { m_TsExpiryTimestamp = newTsExpiryTimestamp; } public java.lang.String getTsPassword() { return m_TsPassword; } public void setTsPassword(java.lang.String newTsPassword) { m_TsPassword = newTsPassword; } public java.lang.Boolean getTsPwChangeRestriction() { return m_TsPwChangeRestriction; } public void setTsPwChangeRestriction(java.lang.Boolean newTsPwChangeRestriction) { m_TsPwChangeRestriction = newTsPwChangeRestriction; } public java.lang.String getTsPwValidity() { return m_TsPwValidity; } public void setTsPwValidity(java.lang.String newTsPwValidity) { m_TsPwValidity = newTsPwValidity; } public com.tokuii.system.ITsUser getTsUserId() { return m_TsUserId; } public void setTsUserId(com.tokuii.system.ITsUser newTsUserId) { m_TsUserId = newTsUserId; } public java.util.Set getTsPasswordIdTsUser() { synchronized (this) { if (m_TsPasswordIdTsUser == null) { m_TsPasswordIdTsUser = new java.util.HashSet(); } } return m_TsPasswordIdTsUser; } public void setTsPasswordIdTsUser(java.util.Set newTsPasswordIdTsUser) { m_TsPasswordIdTsUser = newTsPasswordIdTsUser; } public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } final TsPassword that = (TsPassword) o; if (m_TsPassword != null ? !m_TsPassword.equals(that.m_TsPassword) : that.m_TsPassword != null) { return false; } Object thisId = m_TsUserId != null ? m_TsUserId.getId() : null; Object thatId = that.m_TsUserId != null ? that.m_TsUserId.getId() : null; if (thisId != null ? !thisId.equals(thatId) : thatId != null) { return false; } return true; } public int hashCode() { int result = 0; result = 29 * result + (m_TsPassword != null ? m_TsPassword.hashCode() : 0); result = 29 * result + (m_TsUserId != null && m_TsUserId.getId() != null ? m_TsUserId.getId().hashCode() : 0); return result; } } The interface: public interface ITsPassword extends java.io.Serializable { java.lang.Long getId(); void setId( java.lang.Long aLong ); int getTsVersion(); void setTsVersion( int index ); java.lang.Object getNonDBField( java.lang.String elementLinkName ); void setNonDBField( java.lang.String elementLinkName, java.lang.Object object ); com.tokuii.system.ITsUser getTsCreateUser(); void setTsCreateUser( com.tokuii.system.ITsUser iTsUser ); java.util.Date getTsCreateTimestamp(); void setTsCreateTimestamp( java.util.Date date ); com.tokuii.system.ITsUser getTsModifyUser(); void setTsModifyUser( com.tokuii.system.ITsUser iTsUser ); java.util.Date getTsModifyTimestamp(); void setTsModifyTimestamp( java.util.Date date ); java.lang.String getTsRecStat(); void setTsRecStat( java.lang.String elementLinkName ); java.lang.String getTsSysRowState(); void setTsSysRowState( java.lang.String elementLinkName ); java.util.Date getTsExpiryTimestamp(); void setTsExpiryTimestamp( java.util.Date date ); java.lang.String getTsPassword(); void setTsPassword( java.lang.String elementLinkName ); java.lang.Boolean getTsPwChangeRestriction(); void setTsPwChangeRestriction( java.lang.Boolean aBoolean ); java.lang.String getTsPwValidity(); void setTsPwValidity( java.lang.String elementLinkName ); com.tokuii.system.ITsUser getTsUserId(); void setTsUserId( com.tokuii.system.ITsUser iTsUser ); java.util.Set getTsPasswordIdTsUser(); void setTsPasswordIdTsUser( java.util.Set set ); } -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Emmanuel B. (JIRA) <no...@at...> - 2006-07-27 23:08:39
|
[ http://opensource.atlassian.com/projects/hibernate/browse/ANN-381?pa= ge=3Dall ] Emmanuel Bernard updated ANN-381: --------------------------------- Fix Version: 3.2.0 > Make possible to specify an @EmbeddedId's field in a @OneToMany's mappedB= y property > -------------------------------------------------------------------------= ---------- > > Key: ANN-381 > URL: http://opensource.atlassian.com/projects/hibernate/browse/A= NN-381 > Project: Hibernate Annotations > Type: Improvement > Components: binder > Environment: Hibernate's annotations packaged in JBoss EJB 3.0 RC8- FD > Microsoft SQL Server 2000 > Reporter: Pierre Four=C3=A8s > Fix For: 3.2.0 > > > As described in hibernate forum (http://forum.hibernate.org/viewtopic.php= ?t=3D960763) and discussed with Emmanuel, it would be very nice to be able = to specify in an @OneToMany's mappedBy property the field of an @EmbeddedId= . > For example, i would like to be able run this example : > @Entity > public class Card { > @OneToMany(cascade=3DCascadeType.ALL, fetch=3DFetchType.EAGER, mappedB= y=3D"primaryKey.card") > private Set<CardField> fields;=20 > } > @Entity > public class CardField implements Field { > @EmbeddedId > private PrimaryKey primaryKey =3D new PrimaryKey(); > =20 > @Embeddable > class PrimaryKey implements Serializable { > @ManyToOne(optional =3D false) > private Card card; > =20 > @ManyToOne(optional =3D false) > private Key key; > } > } > @Entity > public class Key {} --=20 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= .jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Darryl M. (JIRA) <no...@at...> - 2006-07-27 22:57:26
|
[ http://opensource.atlassian.com/projects/hibernate/browse/HBX-709?page=comments#action_23764 ] Darryl Miles commented on HBX-709: ---------------------------------- I'm no guru but believe I have some limited understanding, so dont shoot me. No it does not. Your update site has a site.xml descriptor file which catalogues everything that is available from that update site, each downloadable item may contain one or more features. This way you can bundle prerequisites as now and provide a runtime only JAR from the same site at the same time, even multiple versions of things at the same time. The update manage will work out the best fit archive to download (and if it doesn't that a bug). This means someone with a suitable base version of WTP installed that uses the update site, the UI should automatically pick the runtime only JAR to install. But someone with just Eclipse Platform and no WTP, the UI should automaticially pick the runtime+prerequsites JAR to install. I dont think its worth the headache of exploding all all the features. Ideally each version of a unique feature would be in its own JAR. This way fine grained downloading and installing can be performed by the update manager and extra versions of pre-requisites are not installed on the system at all. This is only a problem say if you are 1 prerequisite missing you can end up downloading JAR two and installing everything in it just to get access to that one feature. But I dont believe anything gets broken when that happens so maybe we should not worry about it at all. Hibernate tools users there are 3 groups (as I see it): * Those with no Eclipse runtime installed [all in one jar] * Those with Eclipse runtime installed (but without WTP and its prerequisites) [HBX runtime + prerequisites, JAR two] * Those with Eclipse runtime + WTP installed [HBX runtime only, JAR one] Obviously the first group does not apply to the update manager and I'm not even sure if there is an all-in-one for download even on sourceforge. The other two can be distrubuted from the same update site (when packaged appropiately for update site deployment) and an equivalent JAR can be created in each two forms to put up on sourceforge. I would like to see a change of name take place so the current filename is used for the HBX runtime only and a new named archive (maybe with "-incdeps" in the filename). Or if thats a headache a new naming scheme for both to make everyone pick. (maybe "-runtime" in the name). Maybe you can point me in the direction of the ANT tasks and procedure that is used to create a distribution and the update site artifacts ? > Start distributing an eclipse Hibernate Tools runtime only JAR > -------------------------------------------------------------- > > Key: HBX-709 > URL: http://opensource.atlassian.com/projects/hibernate/browse/HBX-709 > Project: Hibernate Tools > Type: Task > Reporter: Darryl Miles > Attachments: feature.xml > > > http://forum.hibernate.org/viewtopic.php?t=962374 > Start to pickup and use Eclipse/WTP versioning within the features.xml/ > Plan of action as I see it: > * Copy features/org.eclipse.* and features.org.apache.* files as well as pre-requisite plugins/* when packaging. > * Move <plugin ...> into <import ...> in features/org.hibernate.eclipse.feature_3.2.0.beta6a/feature.xml (see attached sample of this working for me) > * Modify build and packaging process to now create two JARs. > JAR one contains (this is the runtime only JAR): > features/org.hibernate.eclipse.feature* > plugins/org.hibernate.eclipse* > plugins/org.jboss.ide.eclipse.freemarker* > JAR two contains (this is the equivalent of what is distrubuted now, hibernate tools, with WTP/XSD/GEF/JEM pre-requisites, without Eclipse Platform) > All the files in JAR one above, plus > plugins/org.eclipse.gef* > plugins/org.eclipse.wst.xml_core.feature.* > plugins/org.eclipse.wst.common_core.feature* > plugins/org.eclipse.wst.common_ui.feature* > plugins/org.apache.xerces.feature* > plugins/org.eclipse.xsd* > plugins/org.eclipse.jem* > plugins/org.eclipse.wst.xml_ui.feature* > plugins/org.eclipse.emf* > features/org.eclipse.gef* > features/org.eclipse.wst.xml_core.feature_* > features/org.eclipse.wst.common_core.feature_* > features/org.eclipse.wst.common_ui.feature_* > features/org.apache.xerces.feature_* > features/org.eclipse.xsd_* > features/org.eclipse.jem_* > features/org.eclipse.wst.xml_ui.feature_* > features/org.eclipse.emf_* > By removing the <plugin ..> declarations from the hibernate JAR it stops the JAR claiming it is the authorative source for that plugin to the update manager. By including the original features/ files from the original authorative source means that if a user installs pre-requisites (or has pre-requisites already installed) when they use JAR two, and restart Eclipse will automatically pickup and use the lastest installed version of WTP/XSD/EMF/GEF/JEM compatible with hibernate tools. > This has the effect is automatically upgrading the version of pre-requisites when multiple versions are found. But in the event the users version of pre-requisites is too old or non-existant then the ones in the JAR two will be picked up and used. > If the re-packaged version of freemarker is also being used inside other JBOSS plugins, then I would suggest a seperate feature/org.jboss.ide.eclipse.freemarker*/feature.xml be provided and all plugins built on top are then to pickup that with an <import ...> declaration. If hibernate tools is the only user of freemarker then leading it inside hibernate tools is fine. -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Emmanuel B. (JIRA) <no...@at...> - 2006-07-27 22:38:14
|
[ http://opensource.atlassian.com/projects/hibernate/browse/ANN-36?page=all ] Emmanuel Bernard updated ANN-36: -------------------------------- Fix Version: 3.2.0 > @DiscriminatorColumn > -------------------- > > Key: ANN-36 > URL: http://opensource.atlassian.com/projects/hibernate/browse/ANN-36 > Project: Hibernate Annotations > Type: Improvement > Components: binder > Versions: 3.1beta3 > Reporter: Emmanuel Bernard > Assignee: Emmanuel Bernard > Priority: Trivial > Fix For: 3.2.0 > Attachments: patch.zip > > > @DiscriminatorColumn( > type="", > force=false, > insert=true, > formula=@Formula(...) > ) > //not sure about type -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Mike D. (JIRA) <no...@at...> - 2006-07-27 17:29:26
|
[ http://opensource.atlassian.com/projects/hibernate/browse/HHH-1713?page=all ] Mike Dillon updated HHH-1713: ----------------------------- Attachment: AbstractEntityPersister.java.patch Updated patch from SVN trunk of Hibernate3. > AbstractEntityPersister causes an exception when a row in a joined table is missing with fetch="select" > ------------------------------------------------------------------------------------------------------- > > Key: HHH-1713 > URL: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1713 > Project: Hibernate3 > Type: Bug > Components: core > Versions: 3.1.3, 3.2.0 cr1 > Environment: Hibernate 3.1.3, 3.2.0cr1 > Oracle 9i (using odjbc14.jar from Oracle 10.1.0.4) > Reporter: Mike Dillon > Priority: Minor > Attachments: AbstractEntityPersister.java.patch, AbstractEntityPersister.java.patch, BasicEntityPersister.patch > > > When using the <join> mapping, the behavior of AbstractEntityPersister when the joined row is missing is not consistent between fetch="join" and fetch="select". > When fetch="join" and the row is missing, the AbstractEntityPersister simply sets all the outer joined fields to null since that's what comes back from the database. However, when fetch="select" and the row is missing, an SQLException is thrown. The reason is that the call to ResultSet.next() is not checked to see if a row is available before calling ResultSet.getXXXX(). In our Oracle enviroment, this resulted in a cryptic JDBC error about an "Exhausted Resultset". > The fix is to check the return value of ResultSet.next(). I have attached a patch with a proposed fix for this issue. To be consistent with the current behavior of fetch="join", it explicitly sets all fields that come from the "sequential select" to null when the select does not produce any rows. This contradicts the hibernate-mapping DTD which says that the "optional" attribute on <join> defaults to false, but since that attribute is undocumented and the current implementation doesn't seem to respect this attribute even when fetch="join", I decided to be consistent with the actual semantics of fetch="join". > The behavior of the optional attibute probably needs to be fixed in both cases, but I didn't address that with my patch. It seems that optional only works as advertised when Hibernate is able to produce a query with a single polymorphic join and can use an inner join instead of a left outer join. > My patch was created against Hibernate 3.1.3, but I looked at the same code in 3.2.0cr1 and it has not changed. -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Emmanuel B. (JIRA) <no...@at...> - 2006-07-27 13:38:23
|
[ http://opensource.atlassian.com/projects/hibernate/browse/ANN-261?page=all ] Emmanuel Bernard updated ANN-261: --------------------------------- Fix Version: 3.2.0 > Allow specifying foreign key constraint name using annotations > -------------------------------------------------------------- > > Key: ANN-261 > URL: http://opensource.atlassian.com/projects/hibernate/browse/ANN-261 > Project: Hibernate Annotations > Type: Improvement > Components: binder > Versions: 3.1beta8 > Reporter: Paul Barry > Priority: Minor > Fix For: 3.2.0 > Attachments: hibernate-annotation-3.2.0.CR2-fk2.patch, hibernate-annotations-3.2.0.CR1-fk.patch, hibernate-annotations-fk.patch > > > Using hbm.xml configuration for many-to-one, there is a foreign-key property that allows you to specify the name of the FK constraint. It would be nice if there was something similar for annotations, such as @ManyToOne ( constraintName = "FK_WHATEVER"). Also, a sensible default would be nice to, for example FK_TABLE_NAME_COLUMN_NAME, rather than FK20708CF6792111. I know Oracle has a 30 char limit for constraint names, so there would have to me some logic to find a way to abbreviate it. -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Guido L. (JIRA) <no...@at...> - 2006-07-27 11:13:13
|
[ http://opensource.atlassian.com/projects/hibernate/browse/ANN-339?page=comments#action_23788 ] Guido Laures commented on ANN-339: ---------------------------------- I can not see that this has been fixed. I hav the same error still in CR1. > @OrderBy does not work when an association table is involved > ------------------------------------------------------------ > > Key: ANN-339 > URL: http://opensource.atlassian.com/projects/hibernate/browse/ANN-339 > Project: Hibernate Annotations > Type: Bug > Components: binder > Versions: 3.1.0.Beta10 > Reporter: Emmanuel Bernard > Assignee: Emmanuel Bernard > Fix For: 3.2.0.cr1 > > -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |
From: Emmanuel B. (JIRA) <no...@at...> - 2006-07-27 11:02:46
|
[ http://opensource.atlassian.com/projects/hibernate/browse/ANN-369?page=all ] Emmanuel Bernard updated ANN-369: --------------------------------- Fix Version: 3.2.0 > @CollectionOfElements on a Map uses reserved word "key" as column name > ---------------------------------------------------------------------- > > Key: ANN-369 > URL: http://opensource.atlassian.com/projects/hibernate/browse/ANN-369 > Project: Hibernate Annotations > Type: Bug > Components: binder > Versions: 3.2.0.cr1 > Environment: Hibernate 3.2.0cr1, MySQL 5 > Reporter: Martin > Assignee: Emmanuel Bernard > Fix For: 3.2.0 > Attachments: dont_use_key_for_maps.diff > > > This annotation > [User.java] > @CollectionOfElements > public Map<String, String> getMisc() > results in this create table statement: > create table User_misc (User_id bigint not null, element varchar(255), key varchar(255), primary key (User_id, key)) type=InnoDB > But "KEY" is a reserved word, so MySQL won't create that table. The default column name should either change or be enclosed by backticks. -- 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.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira |