[Hibernate] Mail list migration complete
Migration of the Hibernate email lists to their new hosting home is now complete. As of today, automated emails have been fully cut over: JIRA - [EMAIL PROTECTED] SVN - [EMAIL PROTECTED] CruiseControl - hibernate-dev@lists.jboss.org For the past 2 weeks or so I have been monitoring both of the dev lists. As of next week, that will stop and I will only continue to subscribe to hibernate-dev@lists.jboss.org The [EMAIL PROTECTED] is new and we'll see how it goes. It is supposed to be used for general announcements, release notifications, etc. For example, I intend to send release announcements to both [EMAIL PROTECTED] and [EMAIL PROTECTED] Thanks! Steve - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] Session.replicate() into IDENTITY table ?
Not sure if anyone replied to this yet or not, so I'll throw my $0.02 into the discussion. I think all that is needed is to better allow definition of what is to occur during replication in the method call. For example, consider the changing the signature from accepting a ReplicationMode to accepting a (new) ReplicationStrategy, where ReplicationStrategy is defined something like: ReplicationStrategy { /** * How should we react when we encounter a pre-existing row * in the target database? * p/ * TODO: probably rename the ReplicationMode class to MergeMode */ public ReplicationMode getMergeMode() ... /** * When replicating an entity which does not yet occur in the * target database, should we enforce that the target data * we are about to create have the same identifier value? */ public boolean forceIdentiferRetention() ... } Also, there has been some discussion about moving the replicate functionality from the Session interface to the StatelessSession interface which would be a good point in time to introduce such changes. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Darryl Miles Sent: Tuesday, August 01, 2006 12:47 PM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] Session.replicate() into IDENTITY table ? A while ago I highlighted a problem with the differences between the documented API and what Hibernate actually does and I'm seeking to an open discussion about the merits and problems to renaming the current #replicate() function to #replicateOrSave() to better identify what it actually does. This is so that a hole can be left open to implement a real #replicate() function which makes contact guarantees that the primary key / OID will be identical even in IDENTITY tables in the replicated object or otherwise it throws an exception. There should also be a feature enquiry function to allow the API programmer to ask the underlying Hibernate implementation to verify if a replication on identity table will work. This would account for JDBC driver vendors and versions and the realtime SQL database server vendor and version. http://www.mail-archive.com/hibernate-devel@lists.sourceforge.net/msg052 30.html http://forum.hibernate.org/viewtopic.php?t=949574highlight= http://www.hibernate.org/hib_docs/v3/api/org/hibernate/Session.html#repl icate(java.lang.Object,%20org.hibernate.ReplicationMode) RFC Darryl - Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDE V ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] instrument tasks
So Scott has finished up HHH-1931 in regards to the cglib instrumentation task. The underlying issue was that the javassist and cglib versions did slightly different things in regards to instrumenting field access. Javassist only instrumented access to fields which are declared on the class being transformed; cglib transformed ever field access. Both are actually valuable approaches in different situations. For the time being, the cglib based task was made to not instrument access to fields declared outside the transforming class. I think the opposite approach is valuable when the field's owner is also being instrumented. So another capability to add here is for both of the instrument tasks to be able to instrument access to fields which are declared outside the class being transformed currently as long as the declaring class is also being transformed. Another capability that I would like to see would be to limit instrumentation to only fields which are defined in a Hibernate mapping. Currently the instrument tasks do not know anything about the mappings, so the first change to allow this would be facilitate the passing or definition of a Configuration into the tasks. The tools already have such a task used in their ant task stacks. So we would need to decide whether it makes more sense to move the instrument tasks over to the tools subproject, or to consume the configuration/ sub task from tools into core and make use of it from the instrument tasks. - Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDEV ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] derby support
I am working on enhancing Derby support a little bit, but have run into an issue with their syntax that I am unable to figure out. I was hoping someone on this list was familiar enough with Derby to point me in the right direction. Specifically, I am trying to properly deal with the manner in which Derby (and also DB2 largely) expects columns to be referenced in certain clauses. For example, because Hibernate always aliases columns in the select clause, derby requires that those aliases be used in certain later clauses. The query I am trying to work through right now is as follows: select model0_.name as col_0_0_, count(*) as col_1_0_ from Model model0_ group by model0_.name having count(*) 1 However, I get errors from Derby when passing this to the DB: ERROR 42X04: Column 'MODEL0_.COL_0_0_' is either not in any table in the FROM list or appears within a join specification and is outside the scope of the join specification or appears in a HAVING clause and is not in the GROUP BY list. If this is a CREATE or ALTER TABLE statement then 'MODEL0_.COL_0_0_' is not a column in the target table. If the having clause is removed, the query parses fine; I have tried various incantations regarding how to define the having clause without avail. This query seems taken almost verbatim from their reference docs, yet I cannot get this to work... http://db.apache.org/derby/docs/10.1/ref/rrefselectexpression.html Any thoughts? - Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDEV ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] Roadmap - components
I guess it depends on which pieces of code you are thinking about specifically in regards to Criteria. For example, for the most part users really should not ever need explicit types any longer when dealing with HQL queries because of the changes I have recently put in place regarding looking at the context in which that typed node is used and inferring the proper type based on that; they only ever really need to use a specific type when wanting to do something out of the ordinary (like binding a DateType value to a parameter anticipated as a TimestampType). Would be great to include similar code into Criteria queries; native sql queries would be much tougher. At any rate, I've decided to hold off on this until something other than a minor point release (3.3 maybe?) since it also requires some changes to how the Configuration stuff works). -Original Message- From: Max Andersen Sent: Tuesday, July 25, 2006 12:35 PM To: Steve Ebersole Cc: Hibernate development Subject: Re: [Hibernate] Roadmap - components Regarding handling users migration of code then I guess (one of) the worst parts is where users have query/criteria building code that does not have direct access to the session or sessionfactory, but e.g. only have the Query or Criteria. They would have a hard time migrating code since they can't rely on Hibernate.xxx for getting a proper Type. Could be made easier if query and criteria could tell which session they are from ? /max Well this is just one pre-requisite for cleaning up how components are modeled. Specifically, the piece I want to clean up is the fact that components are currently handled differently than any other mapping construct. When components are being parsed and bound (during config time) they require construction of and access to things that are typically only available after SF construction (runtime) for all other mapping contructs. This mis-alignment causes some goofiness in the way ComponentTypes are built and, even more importantly, some goofiness in some of the things upon which ComponentTypes currently depend. Yes, one of these is how bytecode providers are handled. Another is PropertyAccessors. Yet another is ComponentTuplizers. -Original Message- From: Max Andersen Sent: Monday, July 24, 2006 2:18 AM To: Steve Ebersole; Hibernate development Subject: Re: [Hibernate] Roadmap - components So that leaves the option of having Types be aware of the session factory. Which upon further reflection is not as bad as it sounds, because really there are only a few Type implementations that even need access to the session factory at all in any of these methods (sqlTypes(), etc exluded). These would be limited to mainly the EntityType subclasses, the ComponentType subclasses, and the CollectionType subclasses. The essential point being that none of the primitive/simple types are in this category... Sounds fair. The one wrinkle in this approach is the various type factory methods on the o.h.Hibernate class. These would need to change signature, or go away. I guess we could limit these changes to be only for those who really needed or would it be better to just get it over with. Still, *alot* of code will break for this :( (luckily it is compile-detectable) Is it worth doing this for sessionfactory scoped types ? Do we get more out of this than sf-controllable bytecode provider ? (I guess some of the issues regarding overriding the default types would also get in here) Could we somehow allow both possibilities for the sake of compability ? And I know Christian will love us for changing this so close to the book release ;) /max -Original Message- From: Max Andersen Sent: Monday, July 17, 2006 10:51 AM To: Steve Ebersole; Hibernate development Subject: Re: [Hibernate] Roadmap - components point taken. Well Type and UserType do not necessarily need to be in synch in this particular regard. We could conceivably change Type and then later (i.e. as part of a major release) change the UserType API to align it. After all the whole point of the UserType stuff was to insulate the user from changes in the underlying Type system... -Original Message- From: Max Andersen Sent: Monday, July 17, 2006 10:43 AM To: Steve Ebersole; Hibernate development Subject: Re: [Hibernate] Roadmap - components On Mon, 17 Jul 2006 17:41:25 +0200, Steve Ebersole [EMAIL PROTECTED] wrote: Type is *NOT* a public API... but UserType is - don't they need access to this info too ? /max -Original Message- From: Max Andersen Sent: Monday, July 17, 2006 10:38 AM To: Steve Ebersole; Hibernate development Subject: Re: [Hibernate] Roadmap - components ...but requires changes to public API so probably best suited for 3.3. Regarding the component related changes mentioned in the previous email... As I mentioned a lot of the pre-requisite work has already been performed
[Hibernate] Roadmap - HQL
Regarding the HQL translator related changes mentioned in the previous email... Mainly, this is involving a fairly large scale refactoring of the Antlr grammars and the associated code. The first aspect was previously discussed on this list, so I won't go into all the gory details. Basically, the current Antlr-based translator translates an HQL query in 3 phases where each phase is represented by one of the grammars. As part of the refactoring, it was decided to move to a 4 phase approach. Essentially, the old second phase will be split out into 2 separate phases (that's slightly simplified, but the basic gist). Another aspect was overall simplification of the AST trees. This is work that has been on going, separated out on the HQL_ANTLR_2 branch in SVN. The focus of the work on that branch thus far has been the first and second phases. This was all being done in an effort to add specific new capabilities to HQL as well as make it easier moving forward to add even more new stuff. For example, one of the new features (that is essentially done on that branch) is the capability to perform ad hoc joining. Another is UNION and MINUS capabilities. Another thing that was done was to change the manner in which property paths are resolved. The previous version delegated to the individual nodes that made up the path after the entire path had been recognized. That put a lot of responsibility on the nodes in terms of knowing where they were located within the overall statement structure since that has a bearing on how the path resolution needs to be handled. I am not completely satisfied with some of the details about how this is currently being done on the branch, but it's pretty close to how I see this being done in the eventual solution. The one thing that is causing serious issues with the current approach is index operators; they throw a hugely gigantic monkey wrench into that processing currently :( - Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDEV ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] Connection Handling in Isolater
Yep. This has already been fixed for almost two months now in SVN ;) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED] Sent: Thursday, July 20, 2006 8:35 AM To: hibernate-devel@lists.sourceforge.net Cc: [EMAIL PROTECTED] Subject: [Hibernate] Connection Handling in Isolater Hi all, I think org.hibernate.engine.transaction.Isolater is not handling connections properly: The method JdbcDelegate is currently implemented as follows: public static class JdbcDelegate implements Delegate { ... public void delegateWork(IsolatedWork work) throws HibernateException { Connection connection = null; try { connection = session.getBatcher().openConnection(); ... } ... } finally { if ( wasAutoCommit ) { try { connection.setAutoCommit( true ); } catch( Throwable ignore ) { log.trace( was unable to reset connection back to auto-commit ); } session.getBatcher().closeConnection( connection ); } } } } This means that the connection will only be closed if wasAutoCommit==true but I think it should be closed in any circumstance: public static class JdbcDelegate implements Delegate { ... public void delegateWork(IsolatedWork work) throws HibernateException { Connection connection = null; try { connection = session.getBatcher().openConnection(); ... } ... } finally { if ( wasAutoCommit ) { try { connection.setAutoCommit( true ); } catch( Throwable ignore ) { log.trace( was unable to reset connection back to auto-commit ); } } session.getBatcher().closeConnection( connection ); } } } What do you think ? -- Feel free - 10 GB Mailbox, 100 FreeSMS/Monat ... Jetzt GMX TopMail testen: http://www.gmx.net/de/go/topmail - Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDE V ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel - Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDEV ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] FW: [Hibernate-commits] Hibernate Code SVN: r10125 - branches/Branch_3_2
FYI... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of [EMAIL PROTECTED] Sent: Wednesday, July 19, 2006 9:12 AM To: [EMAIL PROTECTED] Subject: [Hibernate-commits] Hibernate Code SVN: r10125 - branches/Branch_3_2 Author: [EMAIL PROTECTED] Date: 2006-07-19 10:11:50 -0400 (Wed, 19 Jul 2006) New Revision: 10125 Added: branches/Branch_3_2/Hibernate3/ Log: branched 3.2 Copied: branches/Branch_3_2/Hibernate3 (from rev 10124, trunk/Hibernate3) - Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDE V ___ hibernate-commits mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-commits - Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT business topics through brief surveys -- and earn cash http://www.techsay.com/default.php?page=join.phpp=sourceforgeCID=DEVDEV ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] Roadmap
Now that 3.2.0.ga is imminent, here are the things which are currently underway, or which I would like to start soon: 1) Antlr query translator redesign. The original Antlr-based translator was a great first cut and showed us the usefulness of Antlr for this task; in many ways it ways a learning experience. Now, it is time to take those experiences and redesign how the translator works in a few areas and to add some significant enhancements. This will be the subject of a separate email a little later. This work is already well underway on a separate branch in SVN. 2) Adding the notion of a component persister. The goal here is to move most of the logic off of ComponentType to a persister managed by the session factory. The impetus being twofold: a) certain hibernate configuration parameters are currently considered global because of the way ComponentType currently works; the two most annoying being 'hibernate.bytecode.use_reflection_optimizer' and 'hibernate.bytecode.provider'. These changes would allow both of those settings to become session factory scoped values. b) general code cleanup and encapsulation; this aligns with how entities are managed by the EntityTypes. More about this in a later email also. Note that many pre-requisite changes for this have already been made on HEAD (i.e. the inclusion of the o.h.tuple.ComponentMetamodel). 3) Redefine how CacheProvider/Cache work. The main goal here is to have CacheProvider be able to create Cache instances configured for how Hibernate uses the different second level (L2) cache regions. There are 4 regions types each with slightly different usage semantics: a) entity data cache - used to cache entity tuple state b) collection cache - used to cache collection state c) query cache - used to cache query results d) invalidation or timestamps cache 4) Criteria API enhancements: a) I'd like to get everything that is currently possible in HQL as a capability in Criteria queries. Ideally, I'd like to re-use some of the changes being made to the Antlr query translator to facilitate these enhancements. b) statistics collection - the only real possibility I see here is to expose the ability to name criteria queries and expose the stats based on the given name. 5) Completion of the EntityMode and Tuplizer capabilities. This has been hanging around for a while now. There are a couple of specific things we need to finish off here: a) we know that recognizing the concrete type of polymorphic associations is completely broken when using the dom4j entity mode. This is because we currently do not require that node names be unique and we also do not require that the DOM node contain any type of discrimination value. Need to decide on the approach that allows this to work and that is hopefully non-invasive. b) allow user defined entity modes. The infrastructure for allowing this is now in place in HEAD. However, there are currently a lot of places in the code base that assume the entity modes are enums and do == type comparisions. We either need to change all those, or somehow make the user register their custom entity modes. Plus the DTD then needs to be updated to support this. Another thing to discuss is whether these should be bundled in the 3.2.x series, or to go with a 3.3.x. I personally vote to go with a 3.3.x series as 3.2.x was essentially targetting JPA-related work. If we agree for 3.3, then I'll branch HEAD off onto a 3.2 specific branch and we can start to use HEAD for 3.3 work. Thoughts? - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] Roadmap - components
Type is *NOT* a public API... -Original Message- From: Max Andersen Sent: Monday, July 17, 2006 10:38 AM To: Steve Ebersole; Hibernate development Subject: Re: [Hibernate] Roadmap - components ...but requires changes to public API so probably best suited for 3.3. Regarding the component related changes mentioned in the previous email... As I mentioned a lot of the pre-requisite work has already been performed on HEAD. I also took the opportunity to refactor the packaging of the org.hibernate.tuple package. Specifically, most of the pre-requisite work was the introduction of the o.h.t.component.ComponentMetamodel class. Currently, ComponentType just uses this new class directly. What needs to happen next, then, is for the introduction of a org.hibernate.persister.component.ComponentPersister which is managed as part of the session factory much like the other persisters. ComponentType will then need to look up its corresponding ComponentPersister based on a role name and use the capabilities of that persister. The pattern here is very similar to EntityType/EntityPersister. The difficulty I ran into though was that ComponentType would then require access to the session factory (in order to locate the persister) from within methods where it is currently not passed a reference to the session factory (specifically, this was methods like isSame(), isEqual(), compare(), getHashCode(), etc). This gets to more general discussions we have had in the past regarding the scoping of Types. The solution is one of two things: 1) Devise some sort of scoping scheme where Types can unequivocally be bound to a session factory. This is obviously difficult given the current Hibernate.LONG, Hibernate.STRING, etc static references. One thought here would be splitting types (and their interface appropriately) to define static Types and scoped Types... 2) Modify the Type interface to accept either a session or a session factory/entity mode combo for most methods (would not really matter for methods like sqlTypes(), etc) As I mentioned before this then allows us to make the 'hibernate.bytecode.provider' and 'hibernate.bytecode.use_reflection_optimizer'. Down the road, it also allows us to implement discrimination-based inheritance for components. - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] Roadmap - components
Well Type and UserType do not necessarily need to be in synch in this particular regard. We could conceivably change Type and then later (i.e. as part of a major release) change the UserType API to align it. After all the whole point of the UserType stuff was to insulate the user from changes in the underlying Type system... -Original Message- From: Max Andersen Sent: Monday, July 17, 2006 10:43 AM To: Steve Ebersole; Hibernate development Subject: Re: [Hibernate] Roadmap - components On Mon, 17 Jul 2006 17:41:25 +0200, Steve Ebersole [EMAIL PROTECTED] wrote: Type is *NOT* a public API... but UserType is - don't they need access to this info too ? /max -Original Message- From: Max Andersen Sent: Monday, July 17, 2006 10:38 AM To: Steve Ebersole; Hibernate development Subject: Re: [Hibernate] Roadmap - components ...but requires changes to public API so probably best suited for 3.3. Regarding the component related changes mentioned in the previous email... As I mentioned a lot of the pre-requisite work has already been performed on HEAD. I also took the opportunity to refactor the packaging of the org.hibernate.tuple package. Specifically, most of the pre-requisite work was the introduction of the o.h.t.component.ComponentMetamodel class. Currently, ComponentType just uses this new class directly. What needs to happen next, then, is for the introduction of a org.hibernate.persister.component.ComponentPersister which is managed as part of the session factory much like the other persisters. ComponentType will then need to look up its corresponding ComponentPersister based on a role name and use the capabilities of that persister. The pattern here is very similar to EntityType/EntityPersister. The difficulty I ran into though was that ComponentType would then require access to the session factory (in order to locate the persister) from within methods where it is currently not passed a reference to the session factory (specifically, this was methods like isSame(), isEqual(), compare(), getHashCode(), etc). This gets to more general discussions we have had in the past regarding the scoping of Types. The solution is one of two things: 1) Devise some sort of scoping scheme where Types can unequivocally be bound to a session factory. This is obviously difficult given the current Hibernate.LONG, Hibernate.STRING, etc static references. One thought here would be splitting types (and their interface appropriately) to define static Types and scoped Types... 2) Modify the Type interface to accept either a session or a session factory/entity mode combo for most methods (would not really matter for methods like sqlTypes(), etc) As I mentioned before this then allows us to make the 'hibernate.bytecode.provider' and 'hibernate.bytecode.use_reflection_optimizer'. Down the road, it also allows us to implement discrimination-based inheritance for components. - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] Roadmap
Antlr3 is currently still beta. There are some very nice new features (like the tree construction rewrite rules). Not sure, we'll have to watch and see how it progresses. They also have an IDE for this series, btw ;) Well you say 3.3 is more appropriate for the antlr (#1) and tuplizer (#5) stuff, but the rest should be 3.2.x. But the Criteria stuff (#4) is dependant upon the antlr stuff. The cache provider changes I think are clearly inappropriate for a point release. So that just leaves a question about the component persisters. -Original Message- From: Max Andersen Sent: Monday, July 17, 2006 9:50 AM To: Steve Ebersole; Hibernate development Subject: Re: [Hibernate] Roadmap 1) Antlr query translator redesign. The original Antlr-based translator was a great first cut and showed us the usefulness of Antlr for this task; in many ways it ways a learning experience. Now, it is time to take those experiences and redesign how the translator works in a few areas and to add some significant enhancements. This will be the subject of a separate email a little later. This work is already well underway on a separate branch in SVN. This is probably out-of-the-question, but here it goes: Have you looked into if antlr3 could help us in anyway ? One thing I understood from their release notes is that they now have a clear distinction between generationtime and runtime resulting in a smaller footprint and easier isolation. 2) Adding the notion of a component persister. The goal here is to move most of the logic off of ComponentType to a persister managed by the session factory. The impetus being twofold: a) certain hibernate configuration parameters are currently considered global because of the way ComponentType currently works; the two most annoying being 'hibernate.bytecode.use_reflection_optimizer' and 'hibernate.bytecode.provider'. These changes would allow both of those settings to become session factory scoped values. b) general code cleanup and encapsulation; this aligns with how entities are managed by the EntityTypes. More about this in a later email also. Note that many pre-requisite changes for this have already been made on HEAD (i.e. the inclusion of the o.h.tuple.ComponentMetamodel). in context of wether this should go to 3.3 or 3.2 then a) could be a sentiment for 3.2.something ? 4) Criteria API enhancements: a) I'd like to get everything that is currently possible in HQL as a capability in Criteria queries. Ideally, I'd like to re-use some of the changes being made to the Antlr query translator to facilitate these enhancements. +1 for everything currently possible in HQL. b) statistics collection - the only real possibility I see here is to expose the ability to name criteria queries and expose the stats based on the given name. sounds fair enough. 5) Completion of the EntityMode and Tuplizer capabilities. This has been hanging around for a while now. There are a couple of specific things we need to finish off here: a) we know that recognizing the concrete type of polymorphic associations is completely broken when using the dom4j entity mode. This is because we currently do not require that node names be unique and we also do not require that the DOM node contain any type of discrimination value. Need to decide on the approach that allows this to work and that is hopefully non-invasive. b) allow user defined entity modes. The infrastructure for allowing this is now in place in HEAD. However, there are currently a lot of places in the code base that assume the entity modes are enums and do == type comparisions. We either need to change all those, or somehow make the user register their custom entity modes. Plus the DTD then needs to be updated to support this. all sounds good. Another thing to discuss is whether these should be bundled in the 3.2.x series, or to go with a 3.3.x. I personally vote to go with a 3.3.x series as 3.2.x was essentially targetting JPA-related work. If we agree for 3.3, then I'll branch HEAD off onto a 3.2 specific branch and we can start to use HEAD for 3.3 work. starting 3.3 sounds like a plan for the antlr changes and entitymode. /max Thoughts? - Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED
[Hibernate] Hibernate 3.2.0.cr3 released
Hibernate version 3.2.0.cr3 has just been released. The download and notes are available from http://sourceforge.net/project/showfiles.php?group_id=40712package_id=1 27784release_id=430157 This is mainly a minor bug-fix release, although there are further enhancements and fixes for JPA compliance as well as some batch fetching efficiency improvements and component-related enhancements to HQL. Be sure to check out the changelog for all the details. Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] Plan for 3.1.x JIRA issues?
I'll look at other issues after JPA work is complete. The hope is to release the final 3.2.0 CR after that work is complete. So I would expect anything else to be bundled into 3.2 point releases. The DTD thing is an obvious typo and is trivial to fix, so I'll correct that. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Josh Moore Sent: Wednesday, June 21, 2006 3:29 PM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] Plan for 3.1.x JIRA issues? Is there a procedure for having 3.1.x issues moved to 3.2? Two tickets from the 3.1.2/3.1.3 days, in particular, that I've been watching for months still haven't been assigned. If there's anything I need to do to have them apply to the 3.2 branch (more than adding a comment such as cloning), please let me know. Specifically they are: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1401 which outlines a fairly large problem with session.merge() while using versions. Test case included. http://opensource.atlassian.com/projects/hibernate/browse/HHH-1507 which points to a simple typo in hibernate-mapping-3.0.dtd, that forces us to patch every release. Thanks, Josh Moore The Openmicroscopy Environment All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] New error on Annotation query
On Oracle10g it actually returns String for both of the scalars. Not sure what you want to have happen here. The ResultSetMetaData explicitly reports columnType = 12 (java.sql.Types.VARCHAR) for both of these columns. It's not like I can return numerics for all columnType = 12 auto-discoveries... -Original Message- From: Emmanuel Bernard [mailto:[EMAIL PROTECTED] Sent: Wednesday, June 21, 2006 4:59 PM To: Steve Ebersole Cc: Hibernate development Subject: Re: [Hibernate] New error on Annotation query My description was too generic. I've updated the GeneralTest by adding a SpaceShip class. It now fails with the error I encountered. Steve Ebersole wrote: I just ran this on Oracle-10g and HSQLDB and both worked fine for me. On Oracle, the discovered types were BigDecimalType and BigDecimalType. On HSQLDB, the discovered types were BigIntegerType and BigDecimalType -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Wednesday, June 21, 2006 3:55 PM To: Max Andersen; Emmanuel Bernard Cc: Hibernate development Subject: Re: [Hibernate] New error on Annotation query I am creating a similar test in the core testsuite and see if I can reproduce. -Original Message- From: Max Andersen Sent: Wednesday, June 21, 2006 3:53 PM To: Emmanuel Bernard; Steve Ebersole Cc: Hibernate development Subject: Re: [Hibernate] New error on Annotation query This should be controlled by calls to Dialect.registerHibernateType() and whatever the underlying db returns. This has not changed afaik. /max The initial issue is fixed, But now I do have some weird type conversion using HSQLDB (didn't tried the other ones). basically I do have public Dimension() { private int length; private int width; } ints are converted into INTEGER types at the DB level, fine The following native SQL query, mapped using scalar autodiscovery select length * width as surface, length * width * 10 as volume ... returns String for the first argument and Double for the second The same query used to return BigInteger for the first one and BigDecimal for the second. Steve Ebersole wrote: Try it again from SVN. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Sunday, June 18, 2006 10:21 PM To: Hibernate development Subject: [Hibernate] New error on Annotation query Has something changed that I haven't propagated in my code? org.hibernate.HibernateException: cannot perform autodiscovery on queries with non-scalar results at org.hibernate.loader.custom.CustomLoader$NonScalarResultColumnProcessor. performDiscovery(CustomLoader.java:453) at org.hibernate.loader.custom.CustomLoader.autoDiscoverTypes(CustomLoader. java:511) at org.hibernate.loader.Loader.getResultSet(Loader.java:1677) at org.hibernate.loader.Loader.doQuery(Loader.java:662) at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loade r.java:224) at org.hibernate.loader.Loader.doList(Loader.java:2144) at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2028) at org.hibernate.loader.Loader.list(Loader.java:2023) at org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:290) at org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1695) at org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:142 ) at org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:150) at org.hibernate.test.annotations.query.QueryTest.testNativeQueryAndComposi tePKAndComponents(QueryTest.java:195) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:25) at org.hibernate.test.annotations.TestCase.runTest(TestCase.java:67) at com.intellij.rt.execution.junit2.JUnitStarter.main(JUnitStarter.java:32) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:25) at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90) @NamedNativeQuery(name = compositekey, query = select name, model, speed, lname as lastn, fname as firstn, length, width, length * width as surface, length * width *10 as volume from SpaceShip, resultSetMapping = compositekey) } @SqlResultSetMapping(name = compositekey, entities = @EntityResult(entityClass
Re: [Hibernate] New error on Annotation query
Actually, I just tested with HSQLDB. For me, HSQLDB is *also* returning columnType = 12 for both of those scalars (and Hibernate then returns Strings for both)... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Thursday, June 22, 2006 3:37 PM To: Hibernate development Subject: Re: [Hibernate] New error on Annotation query On Oracle10g it actually returns String for both of the scalars. Not sure what you want to have happen here. The ResultSetMetaData explicitly reports columnType = 12 (java.sql.Types.VARCHAR) for both of these columns. It's not like I can return numerics for all columnType = 12 auto-discoveries... -Original Message- From: Emmanuel Bernard [mailto:[EMAIL PROTECTED] Sent: Wednesday, June 21, 2006 4:59 PM To: Steve Ebersole Cc: Hibernate development Subject: Re: [Hibernate] New error on Annotation query My description was too generic. I've updated the GeneralTest by adding a SpaceShip class. It now fails with the error I encountered. Steve Ebersole wrote: I just ran this on Oracle-10g and HSQLDB and both worked fine for me. On Oracle, the discovered types were BigDecimalType and BigDecimalType. On HSQLDB, the discovered types were BigIntegerType and BigDecimalType -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Wednesday, June 21, 2006 3:55 PM To: Max Andersen; Emmanuel Bernard Cc: Hibernate development Subject: Re: [Hibernate] New error on Annotation query I am creating a similar test in the core testsuite and see if I can reproduce. -Original Message- From: Max Andersen Sent: Wednesday, June 21, 2006 3:53 PM To: Emmanuel Bernard; Steve Ebersole Cc: Hibernate development Subject: Re: [Hibernate] New error on Annotation query This should be controlled by calls to Dialect.registerHibernateType() and whatever the underlying db returns. This has not changed afaik. /max The initial issue is fixed, But now I do have some weird type conversion using HSQLDB (didn't tried the other ones). basically I do have public Dimension() { private int length; private int width; } ints are converted into INTEGER types at the DB level, fine The following native SQL query, mapped using scalar autodiscovery select length * width as surface, length * width * 10 as volume ... returns String for the first argument and Double for the second The same query used to return BigInteger for the first one and BigDecimal for the second. Steve Ebersole wrote: Try it again from SVN. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Sunday, June 18, 2006 10:21 PM To: Hibernate development Subject: [Hibernate] New error on Annotation query Has something changed that I haven't propagated in my code? org.hibernate.HibernateException: cannot perform autodiscovery on queries with non-scalar results at org.hibernate.loader.custom.CustomLoader$NonScalarResultColumnProcessor. performDiscovery(CustomLoader.java:453) at org.hibernate.loader.custom.CustomLoader.autoDiscoverTypes(CustomLoader. java:511) at org.hibernate.loader.Loader.getResultSet(Loader.java:1677) at org.hibernate.loader.Loader.doQuery(Loader.java:662) at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loade r.java:224) at org.hibernate.loader.Loader.doList(Loader.java:2144) at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2028) at org.hibernate.loader.Loader.list(Loader.java:2023) at org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:290) at org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1695) at org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:142 ) at org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:150) at org.hibernate.test.annotations.query.QueryTest.testNativeQueryAndComposi tePKAndComponents(QueryTest.java:195) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:25) at org.hibernate.test.annotations.TestCase.runTest(TestCase.java:67) at com.intellij.rt.execution.junit2.JUnitStarter.main(JUnitStarter.java:32) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:25) at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90
Re: [Hibernate] New error on Annotation query
Try it again from SVN. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Sunday, June 18, 2006 10:21 PM To: Hibernate development Subject: [Hibernate] New error on Annotation query Has something changed that I haven't propagated in my code? org.hibernate.HibernateException: cannot perform autodiscovery on queries with non-scalar results at org.hibernate.loader.custom.CustomLoader$NonScalarResultColumnProcessor. performDiscovery(CustomLoader.java:453) at org.hibernate.loader.custom.CustomLoader.autoDiscoverTypes(CustomLoader. java:511) at org.hibernate.loader.Loader.getResultSet(Loader.java:1677) at org.hibernate.loader.Loader.doQuery(Loader.java:662) at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loade r.java:224) at org.hibernate.loader.Loader.doList(Loader.java:2144) at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2028) at org.hibernate.loader.Loader.list(Loader.java:2023) at org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:290) at org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1695) at org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:142 ) at org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:150) at org.hibernate.test.annotations.query.QueryTest.testNativeQueryAndComposi tePKAndComponents(QueryTest.java:195) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:25) at org.hibernate.test.annotations.TestCase.runTest(TestCase.java:67) at com.intellij.rt.execution.junit2.JUnitStarter.main(JUnitStarter.java:32) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:25) at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90) @NamedNativeQuery(name = compositekey, query = select name, model, speed, lname as lastn, fname as firstn, length, width, length * width as surface, length * width *10 as volume from SpaceShip, resultSetMapping = compositekey) } @SqlResultSetMapping(name = compositekey, entities = @EntityResult(entityClass = org.hibernate.test.annotations.query.SpaceShip.class, fields = { @FieldResult(name = name, column = name), @FieldResult(name = model, column = model), @FieldResult(name = speed, column = speed), @FieldResult(name = dimensions.width, column = width), @FieldResult(name = captain.lastname, column = lastn), @FieldResult(name = dimensions.length, column = length), @FieldResult(name = captain.firstname, column = firstn) }), columns = [EMAIL PROTECTED](name = surface), @ColumnResult(name = volume)}) ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] New error on Annotation query
I am creating a similar test in the core testsuite and see if I can reproduce. -Original Message- From: Max Andersen Sent: Wednesday, June 21, 2006 3:53 PM To: Emmanuel Bernard; Steve Ebersole Cc: Hibernate development Subject: Re: [Hibernate] New error on Annotation query This should be controlled by calls to Dialect.registerHibernateType() and whatever the underlying db returns. This has not changed afaik. /max The initial issue is fixed, But now I do have some weird type conversion using HSQLDB (didn't tried the other ones). basically I do have public Dimension() { private int length; private int width; } ints are converted into INTEGER types at the DB level, fine The following native SQL query, mapped using scalar autodiscovery select length * width as surface, length * width * 10 as volume ... returns String for the first argument and Double for the second The same query used to return BigInteger for the first one and BigDecimal for the second. Steve Ebersole wrote: Try it again from SVN. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Sunday, June 18, 2006 10:21 PM To: Hibernate development Subject: [Hibernate] New error on Annotation query Has something changed that I haven't propagated in my code? org.hibernate.HibernateException: cannot perform autodiscovery on queries with non-scalar results at org.hibernate.loader.custom.CustomLoader$NonScalarResultColumnProcessor. performDiscovery(CustomLoader.java:453) at org.hibernate.loader.custom.CustomLoader.autoDiscoverTypes(CustomLoader. java:511) at org.hibernate.loader.Loader.getResultSet(Loader.java:1677) at org.hibernate.loader.Loader.doQuery(Loader.java:662) at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loade r.java:224) at org.hibernate.loader.Loader.doList(Loader.java:2144) at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2028) at org.hibernate.loader.Loader.list(Loader.java:2023) at org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:290) at org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1695) at org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:142 ) at org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:150) at org.hibernate.test.annotations.query.QueryTest.testNativeQueryAndComposi tePKAndComponents(QueryTest.java:195) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:25) at org.hibernate.test.annotations.TestCase.runTest(TestCase.java:67) at com.intellij.rt.execution.junit2.JUnitStarter.main(JUnitStarter.java:32) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:25) at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90) @NamedNativeQuery(name = compositekey, query = select name, model, speed, lname as lastn, fname as firstn, length, width, length * width as surface, length * width *10 as volume from SpaceShip, resultSetMapping = compositekey) } @SqlResultSetMapping(name = compositekey, entities = @EntityResult(entityClass = org.hibernate.test.annotations.query.SpaceShip.class, fields = { @FieldResult(name = name, column = name), @FieldResult(name = model, column = model), @FieldResult(name = speed, column = speed), @FieldResult(name = dimensions.width, column = width), @FieldResult(name = captain.lastname, column = lastn), @FieldResult(name = dimensions.length, column = length), @FieldResult(name = captain.firstname, column = firstn) }), columns = [EMAIL PROTECTED](name = surface), @ColumnResult(name = volume)}) ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- -- Max Rydahl Andersen callto
Re: [Hibernate] New error on Annotation query
I just ran this on Oracle-10g and HSQLDB and both worked fine for me. On Oracle, the discovered types were BigDecimalType and BigDecimalType. On HSQLDB, the discovered types were BigIntegerType and BigDecimalType -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Wednesday, June 21, 2006 3:55 PM To: Max Andersen; Emmanuel Bernard Cc: Hibernate development Subject: Re: [Hibernate] New error on Annotation query I am creating a similar test in the core testsuite and see if I can reproduce. -Original Message- From: Max Andersen Sent: Wednesday, June 21, 2006 3:53 PM To: Emmanuel Bernard; Steve Ebersole Cc: Hibernate development Subject: Re: [Hibernate] New error on Annotation query This should be controlled by calls to Dialect.registerHibernateType() and whatever the underlying db returns. This has not changed afaik. /max The initial issue is fixed, But now I do have some weird type conversion using HSQLDB (didn't tried the other ones). basically I do have public Dimension() { private int length; private int width; } ints are converted into INTEGER types at the DB level, fine The following native SQL query, mapped using scalar autodiscovery select length * width as surface, length * width * 10 as volume ... returns String for the first argument and Double for the second The same query used to return BigInteger for the first one and BigDecimal for the second. Steve Ebersole wrote: Try it again from SVN. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Sunday, June 18, 2006 10:21 PM To: Hibernate development Subject: [Hibernate] New error on Annotation query Has something changed that I haven't propagated in my code? org.hibernate.HibernateException: cannot perform autodiscovery on queries with non-scalar results at org.hibernate.loader.custom.CustomLoader$NonScalarResultColumnProcessor. performDiscovery(CustomLoader.java:453) at org.hibernate.loader.custom.CustomLoader.autoDiscoverTypes(CustomLoader. java:511) at org.hibernate.loader.Loader.getResultSet(Loader.java:1677) at org.hibernate.loader.Loader.doQuery(Loader.java:662) at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loade r.java:224) at org.hibernate.loader.Loader.doList(Loader.java:2144) at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2028) at org.hibernate.loader.Loader.list(Loader.java:2023) at org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:290) at org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1695) at org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:142 ) at org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:150) at org.hibernate.test.annotations.query.QueryTest.testNativeQueryAndComposi tePKAndComponents(QueryTest.java:195) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:25) at org.hibernate.test.annotations.TestCase.runTest(TestCase.java:67) at com.intellij.rt.execution.junit2.JUnitStarter.main(JUnitStarter.java:32) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:25) at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90) @NamedNativeQuery(name = compositekey, query = select name, model, speed, lname as lastn, fname as firstn, length, width, length * width as surface, length * width *10 as volume from SpaceShip, resultSetMapping = compositekey) } @SqlResultSetMapping(name = compositekey, entities = @EntityResult(entityClass = org.hibernate.test.annotations.query.SpaceShip.class, fields = { @FieldResult(name = name, column = name), @FieldResult(name = model, column = model), @FieldResult(name = speed, column = speed), @FieldResult(name = dimensions.width, column = width), @FieldResult(name = captain.lastname, column = lastn), @FieldResult(name = dimensions.length, column = length), @FieldResult(name = captain.firstname, column = firstn) }), columns = [EMAIL PROTECTED](name = surface), @ColumnResult(name = volume)}) ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel All the advantages of Linux Managed Hosting
Re: [Hibernate] New error on Annotation query
From my understanding in discussions with Max, auto-discovery is illegal once any returns have been defined/added. Max, can you clarify here? Thinking some more about it, maybe you just meant the column name discovery (as it should be possible to still auto-discover types in this scenario)? Also, in general, we need to make certain that these types of integration point tests are defined within the Hibernate test suite proper so that we can catch these discrepancies earlier... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Sunday, June 18, 2006 10:21 PM To: Hibernate development Subject: [Hibernate] New error on Annotation query Has something changed that I haven't propagated in my code? org.hibernate.HibernateException: cannot perform autodiscovery on queries with non-scalar results at org.hibernate.loader.custom.CustomLoader$NonScalarResultColumnProcessor. performDiscovery(CustomLoader.java:453) at org.hibernate.loader.custom.CustomLoader.autoDiscoverTypes(CustomLoader. java:511) at org.hibernate.loader.Loader.getResultSet(Loader.java:1677) at org.hibernate.loader.Loader.doQuery(Loader.java:662) at org.hibernate.loader.Loader.doQueryAndInitializeNonLazyCollections(Loade r.java:224) at org.hibernate.loader.Loader.doList(Loader.java:2144) at org.hibernate.loader.Loader.listIgnoreQueryCache(Loader.java:2028) at org.hibernate.loader.Loader.list(Loader.java:2023) at org.hibernate.loader.custom.CustomLoader.list(CustomLoader.java:290) at org.hibernate.impl.SessionImpl.listCustomQuery(SessionImpl.java:1695) at org.hibernate.impl.AbstractSessionImpl.list(AbstractSessionImpl.java:142 ) at org.hibernate.impl.SQLQueryImpl.list(SQLQueryImpl.java:150) at org.hibernate.test.annotations.query.QueryTest.testNativeQueryAndComposi tePKAndComponents(QueryTest.java:195) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:25) at org.hibernate.test.annotations.TestCase.runTest(TestCase.java:67) at com.intellij.rt.execution.junit2.JUnitStarter.main(JUnitStarter.java:32) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.jav a:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessor Impl.java:25) at com.intellij.rt.execution.application.AppMain.main(AppMain.java:90) @NamedNativeQuery(name = compositekey, query = select name, model, speed, lname as lastn, fname as firstn, length, width, length * width as surface, length * width *10 as volume from SpaceShip, resultSetMapping = compositekey) } @SqlResultSetMapping(name = compositekey, entities = @EntityResult(entityClass = org.hibernate.test.annotations.query.SpaceShip.class, fields = { @FieldResult(name = name, column = name), @FieldResult(name = model, column = model), @FieldResult(name = speed, column = speed), @FieldResult(name = dimensions.width, column = width), @FieldResult(name = captain.lastname, column = lastn), @FieldResult(name = dimensions.length, column = length), @FieldResult(name = captain.firstname, column = firstn) }), columns = [EMAIL PROTECTED](name = surface), @ColumnResult(name = volume)}) ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] Query failing
I'll take a look. That code block should only actually be executing on dot structures, which an alias is definitely not... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Friday, June 09, 2006 9:21 AM To: Emmanuel Bernard Cc: Hibernate development Subject: Re: [Hibernate] Query failing On Fri, 09 Jun 2006 16:16:44 +0200, Emmanuel Bernard [EMAIL PROTECTED] wrote: But it *is* working if item the alias is renamed i. yes, because you don't have a class named org.hibernate.ejb.test.i Note, i can't see why it actually tries to load org.hibernate.ejb.test.item and not just item. /max Max Rydahl Andersen wrote: No, this is a pure Hibernate EntityManager test, it has nothing to do with app servers. ah - i didn't see that getConstantValue thingy. that error is because of terrible windows that forces the classloaders to have case ignored for lookups ;) /max Max Rydahl Andersen wrote: I have seen similar NoClassDef when dealing with classloaders in eclipse. It looks like the current context thread might not be behaving as it should ? Does this happen only under GlassFish or ? (but weird that changing the alias makes a difference?) /max Steve, JPA compliance + the literal thing seems to give trouble to Query q = em.createQuery( select item from Item item where item.descr like 'Microk_oft mouse' escape 'k' ); |ava.lang.NoClassDefFoundError: item (wrong name: org/hibernate/ejb/test/Item) at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:620) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124) at java.net.URLClassLoader.defineClass(URLClassLoader.java:260) at java.net.URLClassLoader.access$100(URLClassLoader.java:56) at java.net.URLClassLoader$1.run(URLClassLoader.java:195) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:306) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268) at java.lang.ClassLoader.loadClass(ClassLoader.java:251) at org.hibernate.util.ReflectHelper.classForName(ReflectHelper.java:95) at org.hibernate.util.ReflectHelper.getConstantValue(ReflectHelper.java:128 ) at org.hibernate.hql.ast.QueryTranslatorImpl$JavaConstantConverter.handleDo tStructure(QueryTranslatorImpl.java:569) at org.hibernate.hql.ast.QueryTranslatorImpl$JavaConstantConverter.visit(Qu eryTranslatorImpl.java:564) at org.hibernate.hql.ast.util.NodeTraverser.visitDepthFirst(NodeTraverser.j ava:40) at org.hibernate.hql.ast.util.NodeTraverser.visitDepthFirst(NodeTraverser.j ava:41) at org.hibernate.hql.ast.util.NodeTraverser.visitDepthFirst(NodeTraverser.j ava:41) at org.hibernate.hql.ast.util.NodeTraverser.visitDepthFirst(NodeTraverser.j ava:42) at org.hibernate.hql.ast.util.NodeTraverser.traverseDepthFirst(NodeTraverse r.java:33) at org.hibernate.hql.ast.QueryTranslatorImpl.parse(QueryTranslatorImpl.java :254) at org.hibernate.hql.ast.QueryTranslatorImpl.doCompile(QueryTranslatorImpl. java:157) at org.hibernate.hql.ast.QueryTranslatorImpl.compile(QueryTranslatorImpl.ja va:111) at org.hibernate.engine.query.HQLQueryPlan.init(HQLQueryPlan.java:77) at org.hibernate.engine.query.HQLQueryPlan.init(HQLQueryPlan.java:56) at org.hibernate.engine.query.QueryPlanCache.getHQLQueryPlan(QueryPlanCache .java:71) at org.hibernate.impl.AbstractSessionImpl.getHQLQueryPlan(AbstractSessionIm pl.java:133) at org.hibernate.impl.AbstractSessionImpl.createQuery(AbstractSessionImpl.j ava:112) at org.hibernate.impl.SessionImpl.createQuery(SessionImpl.java:1623) at org.hibernate.ejb.AbstractEntityManagerImpl.createQuery(AbstractEntityMa nagerImpl.java:79) at org.hibernate.ejb.test.QueryTest.testEscapeCharacter(QueryTest.java:133) | Note that if I change the alias, it works. Query q = em.createQuery( select i from Item i where i.descr like 'Microk_oft mouse' escape 'k' ); -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] ___ hibernate-devel mailing
Re: [Hibernate] questions regarding development setup
Youre right. We should never have expected failure type tests in a test suite so that we can get back to things we know we want to fix. That is so crazy; what are we thinking here And as for a projects choice of how to define tests impacting that projects credibility in *your projects* mind Well, lets just say I now have a severe impacting regarding your projects credibility ;) From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Szczepan Faber Sent: Friday, June 09, 2006 11:08 AM To: Max Andersen Cc: hibernate-devel@lists.sourceforge.net Subject: Re: [Hibernate] questions regarding development setup The day you write a (needed and usefull!) unittest that is not possible in our current setup then lets talk ;) I've already created patch with couple testcases using same package layout on purpose. No reason to change what just works. reasons: every time the developer cannot unit test non-public method / class w/o public constructor. (every day :) ?) Anyway I will just contribute a patch and let's see what you say... PS Whatever you say, the failing tests / unreasonable test packaging just impact the project credibility. But it's just my opinion and my collegues. Thanks, Szczepan On 6/9/06, Max Rydahl Andersen [EMAIL PROTECTED] wrote: b) But what's the reason of making surprising test subpackage (I've never seen something like that)? You can still have integration/acceptance test cases in 'normal' package or even in different source folder. Unreasonable subpackage makes it hard to write real unit test, you cannot test non public methods, you cannot instantiate some classes etc. Don't you have a refactoring plan to remove test subpackage? No reason to change what just works. The day you write a (needed and usefull!) unittest that is not possible in our current setup then lets talk ;) /max Thanks, Szczepan On 6/8/06, Max Rydahl Andersen [EMAIL PROTECTED] wrote: 1. Why there are about 10 failing test after getting project from svn? a) if the method ends in FailureExpected, then it is an expected failure which represents a known bug/issue. To make the test pass, fix the bug ;) b) others depend on your db, but for the moment I only have failureExpected methods. 2. Why do you keep test files in strange org.hibernate.test package? Shouldn't it be same package as sources (e.g. org.hibernate...) Not strange at all and there is no need to have them in the same package. Alot of our tests is usecase based tests which does not fit 100% into the implmentation layout. -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
Re: [Hibernate] Query failing
Still not able to reproduce this... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Friday, June 09, 2006 9:44 AM To: Hibernate development Subject: Re: [Hibernate] Query failing I'll take a look. That code block should only actually be executing on dot structures, which an alias is definitely not... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Friday, June 09, 2006 9:21 AM To: Emmanuel Bernard Cc: Hibernate development Subject: Re: [Hibernate] Query failing On Fri, 09 Jun 2006 16:16:44 +0200, Emmanuel Bernard [EMAIL PROTECTED] wrote: But it *is* working if item the alias is renamed i. yes, because you don't have a class named org.hibernate.ejb.test.i Note, i can't see why it actually tries to load org.hibernate.ejb.test.item and not just item. /max Max Rydahl Andersen wrote: No, this is a pure Hibernate EntityManager test, it has nothing to do with app servers. ah - i didn't see that getConstantValue thingy. that error is because of terrible windows that forces the classloaders to have case ignored for lookups ;) /max Max Rydahl Andersen wrote: I have seen similar NoClassDef when dealing with classloaders in eclipse. It looks like the current context thread might not be behaving as it should ? Does this happen only under GlassFish or ? (but weird that changing the alias makes a difference?) /max Steve, JPA compliance + the literal thing seems to give trouble to Query q = em.createQuery( select item from Item item where item.descr like 'Microk_oft mouse' escape 'k' ); |ava.lang.NoClassDefFoundError: item (wrong name: org/hibernate/ejb/test/Item) at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:620) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124) at java.net.URLClassLoader.defineClass(URLClassLoader.java:260) at java.net.URLClassLoader.access$100(URLClassLoader.java:56) at java.net.URLClassLoader$1.run(URLClassLoader.java:195) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:188) at java.lang.ClassLoader.loadClass(ClassLoader.java:306) at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268) at java.lang.ClassLoader.loadClass(ClassLoader.java:251) at org.hibernate.util.ReflectHelper.classForName(ReflectHelper.java:95) at org.hibernate.util.ReflectHelper.getConstantValue(ReflectHelper.java:128 ) at org.hibernate.hql.ast.QueryTranslatorImpl$JavaConstantConverter.handleDo tStructure(QueryTranslatorImpl.java:569) at org.hibernate.hql.ast.QueryTranslatorImpl$JavaConstantConverter.visit(Qu eryTranslatorImpl.java:564) at org.hibernate.hql.ast.util.NodeTraverser.visitDepthFirst(NodeTraverser.j ava:40) at org.hibernate.hql.ast.util.NodeTraverser.visitDepthFirst(NodeTraverser.j ava:41) at org.hibernate.hql.ast.util.NodeTraverser.visitDepthFirst(NodeTraverser.j ava:41) at org.hibernate.hql.ast.util.NodeTraverser.visitDepthFirst(NodeTraverser.j ava:42) at org.hibernate.hql.ast.util.NodeTraverser.traverseDepthFirst(NodeTraverse r.java:33) at org.hibernate.hql.ast.QueryTranslatorImpl.parse(QueryTranslatorImpl.java :254) at org.hibernate.hql.ast.QueryTranslatorImpl.doCompile(QueryTranslatorImpl. java:157) at org.hibernate.hql.ast.QueryTranslatorImpl.compile(QueryTranslatorImpl.ja va:111) at org.hibernate.engine.query.HQLQueryPlan.init(HQLQueryPlan.java:77) at org.hibernate.engine.query.HQLQueryPlan.init(HQLQueryPlan.java:56) at org.hibernate.engine.query.QueryPlanCache.getHQLQueryPlan(QueryPlanCache .java:71) at org.hibernate.impl.AbstractSessionImpl.getHQLQueryPlan(AbstractSessionIm pl.java:133) at org.hibernate.impl.AbstractSessionImpl.createQuery(AbstractSessionImpl.j ava:112) at org.hibernate.impl.SessionImpl.createQuery(SessionImpl.java:1623) at org.hibernate.ejb.AbstractEntityManagerImpl.createQuery(AbstractEntityMa nagerImpl.java:79) at org.hibernate.ejb.test.QueryTest.testEscapeCharacter(QueryTest.java:133) | Note that if I change the alias, it works. Query q = em.createQuery( select i from Item i where i.descr like 'Microk_oft mouse' escape 'k' ); -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org
Re: [Hibernate] CacheProviders
Sure. Your provider could do whatever you wanted in terms of using XYZ for data caches, ABC for query caches, and DEF for general caches... Another one is an optimistic tree-cache for entity data caches, and a pessimistic tree-cache for the others. Etc... -Original Message- From: Max Andersen Sent: Thursday, June 01, 2006 7:06 AM To: Steve Ebersole; Hibernate development Subject: Re: [Hibernate] CacheProviders Additionally, we may want to split the Cache interface into separate interfaces also based on usage; this would only be intended to allow clearer definition of the capabilities allowed from each usage scenario. sounds like a good thing, code-readability/maintainability wise. Another nice benefit of this would be to allow mixed providers. Like imagine a clustered data cache along with a local query cache. +1. What about mixed providers in general ? e.g. being able to use EhCache for some entities and JBossCache for others ? -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Default to NoCacheProvider
That sounds reasonable. http://opensource.atlassian.com/projects/hibernate/browse/HHH-1795 -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Friday, May 26, 2006 5:16 PM To: Hibernate development Subject: [Hibernate] Default to NoCacheProvider Since EhCache now requires a configuration per session factory (rather than a configuration for all), we probably should change the default cache provider to NoCacheProvider to avoid useless WARN or even worse CacheException. --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid=107521bid=248729dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- All the advantages of Linux Managed Hosting--Without the Cost and Risk! Fully trained technicians. The highest number of Red Hat certifications in the hosting industry. Fanatical Support. Click to learn more http://sel.as-us.falkag.net/sel?cmd=lnkkid7521bid$8729dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] weak javax.persistence.Query interface
I think you are looking for [EMAIL PROTECTED] But kind of hard for them to change the persistence spec to add type to the setParameter() methods when JPA does not even have a notion of a type. So in your Hibernate request(s), then how do you propose that we allow users to bind parameters of user-defined type? Obviously Query.setParameter(String, Address) is not an option. No Hibernate's API is fine, thank you. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Juraj Burian Sent: Tuesday, May 23, 2006 6:40 AM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] weak javax.persistence.Query interface Problem definition: javax.persistence.Query interface has not defined typed setPrarameter methods. There exists valid queries that can't be parametrized properly via methods in javax.persistence.Query. details: in java.sql.PreparedStatement exists only two method for setting null values, namely setNull(int parameterIndex, int sqlType) setNull(int parameterIndex, int sqlType, String typeName). If we need pass valid null value into the query, these methods must be used. In hibernate Query interface (org.hibernate.Query) exists method Query setParameter(int position, Object val, Type type) that solve this problem. So, we need define more rich API in javax.persistence.Query interface to pass types into a Query. probably we need add methods : public Query setParameter(int position, Type value) public Query setParameter(String name, Type value), where Type is from Long, Boolean , in general NullableType see org.hibernate.type.NullableType. Problem is that fixes in EJB 3 specification are necessary. :-( remarks: org.hibernate.Query is not well object oriented. I mean that methods like setInteger, setBoolean ... should be marked obsolete and should be replaced with methods setParamater(int, int)/setParameter(String, int), setParameter(int, boolean)/setParameter(String boolean) ... in future releases. best regards JuBu p.s. sorry for my weak English ||| | ||| | --- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid0709bid3057dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] weak javax.persistence.Query interface
Perhaps it is a common problem, but one that stems from an interface defined by JSR-220. Guess what, Hibernate does not control the definition of that interface. Thus, whether you choose to believe it or not, such comments need to be directed at previously mentioned mailing list. As for your example, you are completely wrong. Hibernate can in fact determine the appropriate type, because the parameter is compared to a boolean constant. Not sure if you are aware but I changed the way in which Hibernate guesses the type of parameter values a few months ago. Before, it used to inspect the incoming parameter value to make that determination. That is no longer the case. Instead, it now uses the parsed structure of the query to make that guess. For example, in your example, :p is used at one point in a comparison to a boolean constant (:p = true), thus Hibernate knows to expect :p to be of boolean type. Who said Address was an entity? It could very well be a component. It could very well be a simple type even! The important point you are missing is that it is a non-jdk class, and thus there is very little that can be assumed about it. Why do you think setParameter(int, int) is better that setInteger(int, int)? I don't get it. You say something about binding null values later on, but that's rubbish since your setInteger(int, int) would obviously not work for null values either. Because it has the same name and thus is overloaded? I guess; I just don't see the clear benefit there. And I need to see a *clear* benefit before I go changing APIs that people have been using for over two years... -Original Message- From: Juraj Burian [mailto:[EMAIL PROTECTED] Sent: Tuesday, May 23, 2006 8:02 AM To: Steve Ebersole Cc: hibernate-devel@lists.sourceforge.net Subject: Re: [Hibernate] weak javax.persistence.Query interface Steve Ebersole wrote: I think you are looking for [EMAIL PROTECTED] May be, but in my opinion it is a common problem. But kind of hard for them to change the persistence spec to add type to the setParameter() methods when JPA does not even have a notion of a type. try realize select like: from X where ((:p is NULL) AND ( )) OR ((:p = true) AND()) OR((:p = false) AND(...)) p is a Boolean or null. Current (Hibernate) implementation of javax.persistence.Query can't create valid SQL select, because type is lost So in your Hibernate request(s), then how do you propose that we allow users to bind parameters of user-defined type? Obviously Query.setParameter(String, Address) is not an option. No Hibernate's API is fine, thank you. Discusion was only about NullableTypes, NOT about entities. Hibernate have pair of methods defined: public Query setEntity(int position, Object val) public Query setEntity(String name, Object val). Hibernate API is ok, but I mean that nullable types like Long, Numeric, Integer, Boolean need setParameter methods. it's a nice extension mothing more (in context of hibernate.Query). You must call: public Query setParameter(int position, Object val, Type type) if you want put null value correctly. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Juraj Burian Sent: Tuesday, May 23, 2006 6:40 AM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] weak javax.persistence.Query interface Problem definition: javax.persistence.Query interface has not defined typed setPrarameter methods. There exists valid queries that can't be parametrized properly via methods in javax.persistence.Query. details: in java.sql.PreparedStatement exists only two method for setting null values, namely setNull(int parameterIndex, int sqlType) setNull(int parameterIndex, int sqlType, String typeName). If we need pass valid null value into the query, these methods must be used. In hibernate Query interface (org.hibernate.Query) exists method Query setParameter(int position, Object val, Type type) that solve this problem. So, we need define more rich API in javax.persistence.Query interface to pass types into a Query. probably we need add methods : public Query setParameter(int position, Type value) public Query setParameter(String name, Type value), where Type is from Long, Boolean , in general NullableType see org.hibernate.type.NullableType. Problem is that fixes in EJB 3 specification are necessary. :-( remarks: org.hibernate.Query is not well object oriented. I mean that methods like setInteger, setBoolean ... should be marked obsolete and should be replaced with methods setParamater(int, int)/setParameter(String, int), setParameter(int, boolean)/setParameter(String boolean) ... in future releases. best regards JuBu p.s. sorry for my weak English ||| | ||| | --- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make
[Hibernate] RE: Looked at the new resolver code
Moving this to the public list... BTW, was thinking a little bit more about #2. So all-in-all I would much rather be able to go back to the PropertyReferenceSource approach I mentioned before. However, as I mentioned there was some trickiness to such an approach. The specific things I ran into (that I remember) were: 1) The fact that a property path needed to be immediately resolved to a join node structure when the property path occurred in the from-clause, whereas the resolution to a join node structure needed to be delayed until after further dereference in all other cases. 2) Application of join options (fetching, alias, etc) to property paths occurring in from-clauses. One thought was to find the proper abstractions between the different things that need to happen in the different cases and isolate them. I actually started down this path somewhat initially, but opted to rip it out just to get something that worked checked in. As of now, I am thinking the proper abstraction here might be: 1) Introducing an ImplicitJoinContext interface upon which the PropertyReferenceSource nodes can call into for resolution of the next path part. 2) Introduce a driver for this processing. The main key here is that there are slightly different semantics to how intermediate path parts need to be handled as compared to leaf path parts, and this driver would encapsulate that logic (see the essentially redundant logic in resolveCompoundPropertyReference() and handleExplicitPropertyJoin()). -Original Message- From: Joshua Davis [mailto:[EMAIL PROTECTED] Sent: Friday, May 12, 2006 3:44 PM To: Steve Ebersole Subject: Re: Looked at the new resolver code Thanks for that. RE: lhs - Okay, I was just a little confused by that when I first looked at it... it's still not what I would expect but I think that's just the nature of the 'english-like' grammar. For example, my first thought would be to expect FROM X JOIN Y = (FROM (JOIN X Y)) but because the kewords preced the tokens in one case, and not in the other that might be more trouble than it's worth. Or more likely... I just think of SQL in the wrong way. :) - Original Message From: Steve Ebersole [EMAIL PROTECTED] To: Joshua Davis [EMAIL PROTECTED] Sent: Friday, May 12, 2006 3:32:16 PM Subject: RE: Looked at the new resolver code (1) Yes, I really liked the notion of always having aliases. It made it much easier to see what is going on very succinctly. (2) Initially I had it that way. Both EntityPersisterReference and PropertyReference implemented a common interface (PropertyReferenceSource). The code gets really ugly though because there is a very seemingly minor difference between a property path in an explicit join and one that is not. That distinction was very difficult to implement in that approach. (3) Sure, 'lhs' is simply the left-hand-side of the join structure. So in from Animal a join a.offspring join a.mate, Animal a is the 'lhs' of both joins; or conversely, both a.offspring and a.mate share the same left-hand-side... Why have a have a 'lhs' on JoinNode? Because nodes don't know about their parents... (4) The join conditions have not been resolved from the metadata as of yet. They are irrelevant at this juncture. The only time they are needed is when we actually go to generate SQL. The piece that *is* missing is (a) ad hoc join conditions and (b) WITH clause conditions. -Original Message- From: Joshua Davis [mailto:[EMAIL PROTECTED] Sent: Thursday, May 11, 2006 5:23 AM To: Steve Ebersole Subject: Looked at the new resolver code I'm going on vacation next week so time has hard to come by, but I wanted to make sure I understand the new stuff before I go. In general, it looks very good. Here are the questions / comments I had: * I like the 'gen:n' fake aliases, that makes everything very clear. * I'm wondering if there is a simpler way to do what the PropertyPathPart classes do in HqlResolver. It seems like something that could be done as the tree is traversed, but... Maybe that would end up being more confusing. * The join nodes form a tree where the 'lhs' of the join seems to be it's parent, and the rhs is the first child. For example: Resolved AST : ( query ( SELECT_FROM ( from ( EntityPersisterReference {entity-name=org.hibernate.test.hql.Animal, alias=a} ( JoinNode {type=inner, source=implicit, fetch=false, lhs=a} ( EntityPersisterReference {entity-name=org.hibernate.test.hql.Animal, alias=gen:0} ( JoinNode {type=inner, source=implicit, fetch=false, lhs=gen:0} EntityPersisterReference {entity-name=org.hibernate.test.hql.Animal, alias=gen:1} ) ) ) ) ) ) ( where ( like ( gen:1.name gen:1 name ) '%weeble%' ) ) ) \-[QUERY] 'query' +-[SELECT_FROM] 'SELECT_FROM' | \-[FROM] 'from' | \-[ENTITY_PERSISTER_REF] 'org.hibernate.test.hql.Animal (a)' |\-[JOIN] 'join' {type=inner, source=implicit, fetch=false, lhs=a} | \-[ENTITY_PERSISTER_REF
RE: [Hibernate] Issue with pluggable functions
Sorry, my fault. I forgot that we added that call to your stuff. We really need this changed though to properly allow for (1) classic aggregation registration and (2) better user function registration. The other thing I could do is add back the old signature which would only be for your use, and which would not account for user-registered functions (planned feature). That work? From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Wednesday, May 10, 2006 9:05 AM To: Hibernate development Subject: [Hibernate] Issue with pluggable functions public static String renderWhereStringTemplate(String sqlWhereString, Dialect dialect, SQLFunctionRegistry functionRegistry) Breaks binary compatibility with Hibernate Annotations 3.2.0.CR1
RE: [Hibernate] Issue with pluggable functions
We used to implement a required feature of EJB3 that really does not make much sense ;) It allows you to have a map/many-to-many/map structure where the map-key comes from the target entity table (i.e. *not* the association table). At any rate, it probably will be added to core at some point; but it is very intensive to implement properly there, so we did it this way for the sake of getting the latest releases out. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Wednesday, May 10, 2006 9:57 AM To: Emmanuel Bernard; [EMAIL PROTECTED]; hibernate-devel@lists.sourceforge.net Subject: Re: [Hibernate] Issue with pluggable functions On Wed, 10 May 2006 16:45:02 +0200, Emmanuel Bernard [EMAIL PROTECTED] wrote: Yes at least we must not release another core version until we find a solution Again why are you using this function at *config* time ? What is this feature that is in annotations and not in the core ? Anyhow a workaround is: formulaString = Template.renderWhereStringTemplate( formulaString, $alias$, new HSQLDialect(), new SQLFunctionRegistry( new HSQLDialect(), Collections.EMPTY_LIST) ); which is just as much a hack like the existing dummy new HSQLDialect() you have ;) /max -Original Message- From: Max Rydahl Andersen [EMAIL PROTECTED] To: Emmanuel Bernard [EMAIL PROTECTED]; Hibernate development hibernate-devel@lists.sourceforge.net Sent: Wed May 10 09:24:46 2006 Subject: Re: [Hibernate] Issue with pluggable functions ...so I apparently did not have the latest-latest of annotations checkked out when i added this; sorry! Is it a show-stopper ? public static String renderWhereStringTemplate(String sqlWhereString, Dialect dialect, *SQLFunctionRegistry functionRegistry*) Breaks binary compatibility with Hibernate Annotations 3.2.0.CR1 -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid=120709bid=263057dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnkkid0709bid3057dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] Hibernate 3.2.0.cr2 released
Hibernate 3.2.0.CR2 has been released. Changes mainly represent further alignments with the latest EJB3 specifications. Two important ones to note in particular are (1) the ability to perform bulk operations via native-sql queries, avoiding the need to grab JDBC connections (2) alignment with the specification required return types for aggregation queries; this specifically required changes for COUNT, AVG, and SUM; see HHH-1538 for the details.
[Hibernate] bytecode libraries
So now that we have the BytecodeProvider abstraction, does it make sense to allow no lazy-load capabilities for simplistic apps? Something like a NoOpBytecodeProvider which performs no type of class enhancement? --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] bytecode libraries
Sure at some point. But this is still a new evolving API and too volatile for exposure... -Original Message- From: Emmanuel Bernard [mailto:[EMAIL PROTECTED] Sent: Thursday, March 23, 2006 10:13 AM To: Steve Ebersole Cc: Hibernate development Subject: Re: [Hibernate] bytecode libraries Any specific reason why hibernate.bytecode.provider does not consider the value as a class name (if the shortcuts cglib and javassist are not resolved)? That would solve your problem and put it to the users shoulders Steve Ebersole wrote: So now that we have the BytecodeProvider abstraction, does it make sense to allow no lazy-load capabilities for simplistic apps? Something like a NoOpBytecodeProvider which performs no type of class enhancement? --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=kkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] branchng/tagging subversion repo
http://svnbook.red-bean.com/ -Original Message- From: Max Andersen Sent: Wednesday, March 22, 2006 12:23 PM To: Emmanuel Bernard; Steve Ebersole Cc: Hibernate development Subject: Re: [Hibernate] branchng/tagging subversion repo ditto ;) You speak Chinese to me (no offense to the language, I just don't know it ;-) ). Is there any good snv how to I can use as a reference before tagging live? Steve Ebersole wrote: Given the current layout of the subversion repo, there is a little quirkiness to branching and tagging of which I wanted y'all to be aware. Namely, you need to do one of two things when doing the svn-copy: (1) svn-copy the *entire* project into the branch/tag; i.e. copy over all modules (2) do a separate add of the tag/branch directory (i.e., v313) and then do the svn-copy of your particular module into that directory. For HibernateExt, you'll probably even need to create the HibernateExt directory separately under the tag/branch directory This is all to ensure that the branch/tag directories maintain the same directory structure as the trunk for browsing purposes... --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=kkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel ___ Nouveau : téléphonez moins cher avec Yahoo! Messenger ! Découvez les tarifs exceptionnels pour appeler la France et l'international. Téléchargez sur http://fr.messenger.yahoo.com --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid=110944bid=241720dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] branchng/tagging subversion repo
BTW, I highly recommend TortoiseSVN. It makes tasks like this much easier (mainly because I do not need to remember the commands ;). Intellij SVN support has similar features, but I know not everyone uses that (and I have no clue about eclipse). -Original Message- From: Steve Ebersole Sent: Wednesday, March 22, 2006 12:54 PM To: Max Andersen; Emmanuel Bernard Cc: Hibernate development Subject: RE: [Hibernate] branchng/tagging subversion repo http://svnbook.red-bean.com/ -Original Message- From: Max Andersen Sent: Wednesday, March 22, 2006 12:23 PM To: Emmanuel Bernard; Steve Ebersole Cc: Hibernate development Subject: Re: [Hibernate] branchng/tagging subversion repo ditto ;) You speak Chinese to me (no offense to the language, I just don't know it ;-) ). Is there any good snv how to I can use as a reference before tagging live? Steve Ebersole wrote: Given the current layout of the subversion repo, there is a little quirkiness to branching and tagging of which I wanted y'all to be aware. Namely, you need to do one of two things when doing the svn-copy: (1) svn-copy the *entire* project into the branch/tag; i.e. copy over all modules (2) do a separate add of the tag/branch directory (i.e., v313) and then do the svn-copy of your particular module into that directory. For HibernateExt, you'll probably even need to create the HibernateExt directory separately under the tag/branch directory This is all to ensure that the branch/tag directories maintain the same directory structure as the trunk for browsing purposes... --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=kkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel ___ Nouveau : téléphonez moins cher avec Yahoo! Messenger ! Découvez les tarifs exceptionnels pour appeler la France et l'international. Téléchargez sur http://fr.messenger.yahoo.com --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid=110944bid=241720dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] branchng/tagging subversion repo
Given the current layout of the subversion repo, there is a little quirkiness to branching and tagging of which I wanted y'all to be aware. Namely, you need to do one of two things when doing the svn-copy: (1) svn-copy the *entire* project into the branch/tag; i.e. copy over all modules (2) do a separate add of the tag/branch directory (i.e., v313) and then do the svn-copy of your particular module into that directory. For HibernateExt, you'll probably even need to create the HibernateExt directory separately under the tag/branch directory This is all to ensure that the branch/tag directories maintain the same directory structure as the trunk for browsing purposes... --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] subversion repo layout
So we should talk about the layout of the subversion repository. We had talked about each project getting its own module in the repository with its own trunk/branches/tags structure. This is easy enough for the core stuff. But has implications for all of the current HibernateExt subprojects. Specifically, the biggest issue is the use of HibernateExt/common and how y'all want to deal with that (plus the dependency on core). Three options: (1) keep doing what you do now in terms of checking out each individually (2) use of svn:externals to link-in the common stuff (3) removal of common and reworking the builds --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] Hibernate 3.1.3 released
Hibernate 3.1.3 has just been released. This is mainly a bug-fix release. View the details at http://sourceforge.net/project/shownotes.php?release_id=403223group_id= 40712 Download bundles are available at http://sourceforge.net/project/showfiles.php?group_id=40712package_id=1 27784release_id=403223 --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] configuration.buildMapping made public in Hibernate 3.2
My new DDL generation stuff is using it. Although if I remember correctly, I only really needed it for testing purposes. Actually committing it was a mistake though. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Thursday, March 16, 2006 3:34 AM To: Hibernate development Subject: [Hibernate] configuration.buildMapping made public in Hibernate 3.2 Is that intentional ? Noone seem to use it. (I could definitly have used it earlier, but that were deemed non-public api) Just curious on why it suddenly were made public... Same thing seem to have happended with getEntityResolver() -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid=110944bid=241720dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] commit messages?
I've been getting them -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Thursday, March 16, 2006 3:20 AM To: Hibernate development Subject: [Hibernate] commit messages? Am I the only one not having received hibernate-commits messages lately ? The last one I have is from the 28.02... -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid=110944bid=241720dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] bug or feature: oracle deadlock due to missing foreign key index
Or, you could just specify an index on the many-to-one/: class name=Position ... ... many-to-one class=Order column=order_id index=IDX_FK_POSITION_ORDER .../ /class -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Woelke, Milan Sent: Tuesday, March 07, 2006 11:48 AM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] bug or feature: oracle deadlock due to missing foreign key index Hi, I have a problem with hibernate bundled with jboss 4.0.4 as ejb 3.0 persistence provider. Before you skip my post, as just a misguided user question, please continue to read. First a scenario: We have two classes Order and Position, which are part of a bidirectional OneToMany relationship. Deletes are cascaded from Order to Position. Hibernate generates for these two classes two tables, Order and Position, where Position has a foreign key constraint to the primary key of Order. Both tables have an index on their primary keys. If I try to delete two Orders concurrently a deadlock at the db-level occurs. Its easy to reproduce this behavior: session 1: delete from Position where order_id=4711; session 2: delete from Position where order_id=4712; session 1: delete from Order where id=4711; session 2: delete from Order where id=4712; session 1: DEADLOCK What happens on the db level is something like that: session 1: rowlock on the position row to be deleted sharelock on the order table session 2: rowlock on the position row to be deleted sharelock on the order table session 1: tries to aquire rowlock for the order row to be deleted, waits since there is a sharelock on the table by another session session 2: tries to aquire rowlock for the order row to be deleted, waits since there is a sharelock on the table by another session session 1: since the other session waits for this session to release its sharelock on order and this session waits for the other session to release its sharelock, oracle detects a deadlock, and rolls back session 1. To avoid this situation its necessary to create an index on all columns with a foreign key constraint on it. Oracle then doesnt lock the whole order table but just the row connected to the deleted positions. For more information see: http://www.akadia.com/services/ora_locks_survival_guide.html (chapter Referential Integrity Locks) So, Im asking: Is this a bug? Or am I missing something? If it is a bug, I have a solution: It would be necessary to overwrite getAddForeignKeyConstraintString of org.hibernate.dialect.Oracle9Dialect with something like that: public String getAddForeignKeyConstraintString(       String constraintName,       String[] foreignKey,       String referencedTable,       String[] primaryKey,       boolean referencesPrimaryKey   ){ String pureFK = super.getAddForeignKeyConstraintString(constraintName, foreignKey, referencedTable, primaryKey, referencesPrimaryKey); StringBuffer buffer = new StringBuffer(pureFK); buffer.append(, add index ().append(StringHelper.join(, , foreignKey)).append()); return buffer.toString(); } I guess I could do this myself, but I need some feedback to know that my analysis is correct. Also I dont know if such a solution would be acceptable for you. Ive posted this several times to different forums (one after one, im not doing any spam), but never received any replies to that. So please, please respond. Regards, Milan Wölke. --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=kkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Several Patches - sanity check?
The best approach is to first just describe the changes you are proposing at a high level here on this list (i.e. the theory). Then we can discuss the implementation details. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Gudlaugur Egilsson Sent: Thursday, March 02, 2006 10:37 AM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] Several Patches - sanity check? Hi dear Hibernate developers To begin with, thank you for an excellent ORM product. As a by-product of converting the schema definition of our database to hbm-xmls (the first step towards migrating to hibernate), as well as changing the format of our database bootstrap data from insert scripts to hibernate-style XML, I've done a number of modifications to Hibernate-core and Hibernate-tools. The impact areas are reverse engineering (e.g. retaining primary-key, foreign-key and index names), HBM parsing and DDL generation (e.g. support specification of foreign-key names) and replication (some issues with replicating nested XML entity elements in a single transaction). Now, obviously, me being a relative noob in hibernate, these changes are probably based on inadequate knowledge in some cases. I'm quite ready to correct the approach used, but I'm thinking it might be more efficient for everyone involved (especially me :-) to send a post to this list describing the changes I've made, and then submit a patch for each change when these changes have been reviewed by some of the developers. What is your preference in this matter? Thanks -Gulli --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=kkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] Hibernate 3.2 alpha1 released
Hibernate 3.2 alpha1 has just been released. The distribution can be obtained at http://sourceforge.net/project/showfiles.php?group_id=40712package_id=1 27784release_id=397557 There are some significant enhancements with this release so be sure to check the change-log. The biggest changes included pluggability of byte-code providers (cglib and javassist now supported) and integration with JBossCache's new optimistic locking features; in addition, 3.2 will be the basis for EJB3 persistence support moving forward, so work is being wrapped up there to ensure full compliance with the latest spec. --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] setfirstResult() / setMaxResult() and collection fetching
You could, and actually most of the needed code is already in place due to the feature of scrolling collection fetches. The main problem there is that it *only* works (in terms of what you are trying to achieve) provided you know for certain that the results are ordered correctly (namely, they must be ordered by the owning entity primarily such that all possible rows for a given owner are contiguous within the result set). And what about polymorphic queries? The cleanest solution is to fall back to subselect fetching in these cases; which, of course, has its own implementation difficulties. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Tuesday, February 28, 2006 7:12 PM To: Hibernate development Subject: [Hibernate] setfirstResult() / setMaxResult() and collection fetching Wouldn't it be possible to implement that through a scrollable resultset when a collection fetch is involved. This would limit the amount of data in memory. --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid=110944bid=241720dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] RE: Subversion move
The move is scheduled for Monday. Tomorrow I will be turning off commit access to the SF CVS repo. I apologize for needing to do it so far in advance, but I need to make sure it takes in time for a nightly CVS backup to grab a locked-down copy so that we do not miss any changes. Plus I have been having a very hard time actually grabbing the backup tarballs from SF as somehow the connections keep getting dropped on me in the midst of the download, so I want to build in some leeway for that as well. -Original Message- From: Steve Ebersole Sent: Tuesday, February 21, 2006 10:06 AM To: hibernate-devel@lists.sourceforge.net Subject: Subversion move The JBossLabs Subversion repo is ready for our move; speak now, or forever hold your peace ;) I need to know which HibernateExt stuff to move over; I believe there is an issue with moving everything over, right Max? Also, we need to decide on a date/time for the move. I propose early Friday (early my time - US Central). --- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnkkid0944bid$1720dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] LockMode.UPGRADE
The EJB3-persistence-spec requires that LockModeType.READ and LockModeType.WRITE acquire physical database update/exclusive locks for the duration of the current transaction. Currently we have mapped LockModeType.READ to LockMode.UPGRADE and LockModeType.WRITE to a new LockMode.FORCE (LockMode.FORCE essentially acts like LockMode.UPGRADE in the case of non-versioned entities). However, this is problematic in the way we currently apply locks against databases which do not support some form of SELECT ... FOR UPDATE (Sybase, SQLServer, and DB2 use different semantics, but are OK here). The dialects in question here are FrontBaseDialect, HSQLDialect, MckoiDialect, PointbaseDialect, RDMSOS2200Dialect, TimestenDialect (AFAIK, HSQLDB does not even support read-committed, so lets not even consider this one in this discussion). On these dialects, we currently silently fall back to not specifically acquiring any type of lock. The first question here is whether that is correct behavior. I'd actually be more inclined to throw an exception moving forward if the user requests a lock mode for which we cannot guarantee acquisition. However, this will cause compatibility issues for users relying on that old behavior. Secondly, EJB3 only requires that we actually support its version of lock() for versioned entities, but that we absolutely need to support it on versioned entities. That means that for the dialects mentioned above we need to do something different in order to acquire the appropriate database lock. The natural choice here is to perform an update to force an update or exclusive lock in the database. The question here is whether we should support this only for versioned entities, or whether we should expand this to include non-versioned entities as well in our implementation. If we choose to expand this support to non-versioned entities, the question becomes what columns do we update in order to acquire the lock? So, for LockMode.UPGRADE: 1) Should this be an error if we cannot guarantee a write lock in the database? Again, I say yes. 2) To what extent should we attempt to guarantee a write lock? Only in the case of versioned entities? Expand to non-versioned (and how)? --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Subversion move
Sure, I can get Damon to move all of it. I thought there was some stuff you could not move due to your eclipse work? -Original Message- From: Max Andersen Sent: Tuesday, February 21, 2006 11:19 AM To: Steve Ebersole; hibernate-devel@lists.sourceforge.net Subject: Re: [Hibernate] Subversion move On Tue, 21 Feb 2006 17:05:53 +0100, Steve Ebersole [EMAIL PROTECTED] wrote: The JBossLabs Subversion repo is ready for our move; speak now, or forever hold your peace ;) I need to know which HibernateExt stuff to move over; I believe there is an issue with moving everything over, right Max? Our goal for the first move were just to move as much as is, correct ? We don't want to move stuff around before we are at SVN (e.g. moving/making hibernate3 core a module on the same level as the others) So here is what I see we are going to copy verbatim on friday (note: I included CaveatEmptor and container here...even though i don't remember any svn-discussion about them) CaveatEmptor/ container/ Hibernate3/ HibernateExt/ common/ tools/ annotations/ ejb/ ejb-api/ metadata/ build.xml that will give us the exact same structure as before which we then could do the not-yet-planned rearranges in, correct ? For completeness what is missing from this list is: Hibernate/ Hibernate2/ HibernateExt/ org.hibernate.*/ console/ explorer/ hibern8ide/ validate/ avalon/ The org.hibernate.* we will move over to the jbosside structure in jboss cvs. Friday is ok by me. You will hear me scream when the svn just doesn't work ;) /max Also, we need to decide on a date/time for the move. I propose early Friday (early my time - US Central). --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Subversion move
I kinda ignore stuff from you mostly ;) -Original Message- From: Max Andersen Sent: Tuesday, February 21, 2006 3:34 PM To: Steve Ebersole; hibernate-devel@lists.sourceforge.net Subject: Re: [Hibernate] Subversion move On Tue, 21 Feb 2006 18:50:38 +0100, Steve Ebersole [EMAIL PROTECTED] wrote: Sure, I can get Damon to move all of it. I thought there was some stuff you could not move due to your eclipse work? Did you actually read my email ? :) It listed explicitly what should be copied and what should not be copied. I'll repeat it here again in a more short form: What should be copied: CaveatEmptor/ container/ Hibernate3/ HibernateExt/ common/ tools/ ejb/ ejb-api/ metadata/ build.xml What should not be copied: Hibernate/ Hibernate2/ HibernateExt/ org.hibernate.*/ console/ explorer/ hibern8ide/ validate/ avalon/ The org.hibernate.* we will move over to the jbosside structure in jboss /max -Original Message- From: Max Andersen Sent: Tuesday, February 21, 2006 11:19 AM To: Steve Ebersole; hibernate-devel@lists.sourceforge.net Subject: Re: [Hibernate] Subversion move On Tue, 21 Feb 2006 17:05:53 +0100, Steve Ebersole [EMAIL PROTECTED] wrote: The JBossLabs Subversion repo is ready for our move; speak now, or forever hold your peace ;) I need to know which HibernateExt stuff to move over; I believe there is an issue with moving everything over, right Max? Our goal for the first move were just to move as much as is, correct ? We don't want to move stuff around before we are at SVN (e.g. moving/making hibernate3 core a module on the same level as the others) So here is what I see we are going to copy verbatim on friday (note: I included CaveatEmptor and container here...even though i don't remember any svn-discussion about them) CaveatEmptor/ container/ Hibernate3/ HibernateExt/ common/ tools/ annotations/ ejb/ ejb-api/ metadata/ build.xml that will give us the exact same structure as before which we then could do the not-yet-planned rearranges in, correct ? For completeness what is missing from this list is: Hibernate/ Hibernate2/ HibernateExt/ org.hibernate.*/ console/ explorer/ hibern8ide/ validate/ avalon/ The org.hibernate.* we will move over to the jbosside structure in jboss cvs. Friday is ok by me. You will hear me scream when the svn just doesn't work ;) /max Also, we need to decide on a date/time for the move. I propose early Friday (early my time - US Central). --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Internal workings of Hibernate Cache
The keystone of that logic is the org.hibernate.cache.CacheConcurrencyStrategy. Have a look at the different implementations of that interface. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of shalon toy Sent: Tuesday, February 14, 2006 12:30 PM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] Internal workings of Hibernate Cache Does any one know of any document that explains the internals of hibernate second level cache workings. The hibernate docs do not have any information on how the default cahce (ehcache) implementation works. I was looking for some information, that would explain how hibernate determine's when to do an update/refresh/clear of the objects that its caching. Thanks for reading! -ES --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=kkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] jbosscache.jar
Ahh [EMAIL PROTECTED]@#E Sorry my fault. I commited the support for the new JBossCache optimistic locking model, but forgot to commit the new jar. Give me a sec... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Christian Bauer Sent: Friday, February 10, 2006 9:34 PM To: development Hibernate Subject: [Hibernate] jbosscache.jar I think the jbosscache.jar in Hibernate3/lib/ is outdated: compile: [javac] Compiling 104 source files to /Users/turin/work/remote/ hibernate/Hibernate3/build/classes [javac] /Users/turin/work/remote/hibernate/Hibernate3/src/org/ hibernate/cache/OptimisticTreeCache.java:14: package org.jboss.cache.optimistic does not exist --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Do antlr exception leak to users?
The thing that we discussed (and I have just not yet had time to implement) is actually converting QueryExceptions that contain antlr stuff during serialization by either writeReplace() or writeObject(). Initially we had discussed just stripping the cause in the case of antrl exception, but perhaps another option is to simply write a replacement for the antlr exception during writeObject() on the QueryException. Yet another option would be to handle this as we recognize antrl exceptions in the translator/parser and decompose that information. I don't think the stack trace of the antlr exceptions themselves are really that vital to users anyway so we could just log the antlr exceptions for debug purposes. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Tuesday, February 07, 2006 2:02 PM To: Scott M Stark; jboss-development@lists.sourceforge.net; Hibernate development Subject: Re: [Hibernate] Do antlr exception leak to users? On Tue, 07 Feb 2006 20:55:52 +0100, Scott M Stark [EMAIL PROTECTED] wrote: fixing the antlr exception svuid won't help us if the client is using an older version, right ? It will if the serialVersionUID is set to the implicit value from the previous version. This can be done if the version is still serializable compatible. which it isn't afaik. the antlr version started to include more data in the exception over time. calling printStackTrace() on every exception sounds overkill for me...and will turn basic logging into something very verbose. Should be no different from now as logging generally includes the cause. well, for me that is showing the exception message in a dialog in the ui I would be very disappointed to have a full stack trace in the message output. I understand the issue, but don't find the suggested solutions any good ;( Would be nice to have an option to have any exposed remote exception do the serialization of the cause. Would make it a non-issue where it actually matters. This can't be done without modifying the exception either via source or bytecode manipulation. And bytecode manipulation or simple modification of the exception in the jboss serialization/remoting layer have that option, correct ? -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Do antlr exception leak to users?
Well I think the distinction here is that Hibernate constitutes a hard dependency on Antlr. The users choice to use Oracle is completely within their control. -Original Message- From: Max Andersen Sent: Wednesday, February 08, 2006 8:41 AM To: Steve Ebersole; Scott M Stark; jboss-development@lists.sourceforge.net; Hibernate development Subject: Re: [Hibernate] Do antlr exception leak to users? Hi, antlr exceptions can probably be contained by some of the methods mentioned below - no problem. I'm just wondering what to do with other exceptions ? They will have the same/similar problem correct? e.g. a ocracle driver specific exception occurs which is pretty good to have as the cause...that will spill to other clients too. /max The thing that we discussed (and I have just not yet had time to implement) is actually converting QueryExceptions that contain antlr stuff during serialization by either writeReplace() or writeObject(). Initially we had discussed just stripping the cause in the case of antrl exception, but perhaps another option is to simply write a replacement for the antlr exception during writeObject() on the QueryException. Yet another option would be to handle this as we recognize antrl exceptions in the translator/parser and decompose that information. I don't think the stack trace of the antlr exceptions themselves are really that vital to users anyway so we could just log the antlr exceptions for debug purposes. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Tuesday, February 07, 2006 2:02 PM To: Scott M Stark; jboss-development@lists.sourceforge.net; Hibernate development Subject: Re: [Hibernate] Do antlr exception leak to users? On Tue, 07 Feb 2006 20:55:52 +0100, Scott M Stark [EMAIL PROTECTED] wrote: fixing the antlr exception svuid won't help us if the client is using an older version, right ? It will if the serialVersionUID is set to the implicit value from the previous version. This can be done if the version is still serializable compatible. which it isn't afaik. the antlr version started to include more data in the exception over time. calling printStackTrace() on every exception sounds overkill for me...and will turn basic logging into something very verbose. Should be no different from now as logging generally includes the cause. well, for me that is showing the exception message in a dialog in the ui I would be very disappointed to have a full stack trace in the message output. I understand the issue, but don't find the suggested solutions any good ;( Would be nice to have an option to have any exposed remote exception do the serialization of the cause. Would make it a non-issue where it actually matters. This can't be done without modifying the exception either via source or bytecode manipulation. And bytecode manipulation or simple modification of the exception in the jboss serialization/remoting layer have that option, correct ? -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] livelink collections server
What does the SQL look like to access this? -Original Message- From: Bompart Cedric [mailto:[EMAIL PROTECTED] Sent: Wednesday, February 08, 2006 3:40 AM To: Steve Ebersole; hibernate-devel@lists.sourceforge.net Subject: RE : [Hibernate] livelink collections server Hello, The livelink product handles n to n relationship without intermediate table but with a field with multiple values. Is it possible to instruct Hibernate to comply to this? if so how do I do it? via the dialect? Regards, Ced. Message d'origine De: Steve Ebersole [mailto:[EMAIL PROTECTED] Date: mar. 24.01.2006 17:58 À: Bompart Cedric; hibernate-devel@lists.sourceforge.net Cc: Objet: RE: [Hibernate] livelink collections server A custom Dialect should be enough, although you may need to appropriately set some configuration properties as well... The best thing to do is to simply try running the Hibernate test suite using your custom dialect; that'll give you an idea of what type/level of SQL support Hibernate is expecting that this particular database may/may not provide. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Bompart Cedric Sent: Tuesday, January 24, 2006 3:56 AM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] livelink collections server Hello, I'm just wondering what do I need to do to support another database vendor with Hibernate 3.1 ? The database is LiveLink Collections Server from OpenText (known previously as Basis) and they provide a JDBC driver. So far I've seen that I need to write a new implementation of org.hibernate.dialect.Dialect and what else ? any documentation related to that subject ? or anything to look at will be nice... :-) Regards, Ced. -- M. Cedric Bompart J2EE Architect THALES Suisse SA --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=kkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Release naming conventions
Yes, I plan to start using these conventions starting with 3.2. I'm not a big fan of all minor releases needing to append '.ga' (i.e. 3.1.3.ga.jar). I really wish there was a way to define ordering amongst qualifiers. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Christian Bauer Sent: Tuesday, February 07, 2006 11:44 AM To: development Hibernate; [EMAIL PROTECTED] Subject: [Hibernate] Release naming conventions JBoss finalized some naming conventions for release packages, and both Hibernate and NHibernate packages should follow these conventions. The benefit of this is stability and the ability to compare packages. As far as I can see, nothing much changes for Hibernate except that some of the confusion in the past around alpha/ beta/rc releases is avoided. http://wiki.jboss.org/wiki/Wiki.jsp?page=JBossProductVersioning --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] merge policy...
You should do it as part of every commit. It is far more painful to do large occasional merges. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Monday, February 06, 2006 4:08 AM To: Hibernate development Subject: [Hibernate] merge policy... Hi guys, What kind of merging should we do with respect to 3.1 and 3.2 for stuff that concerns both branches (like HHH-1453) ? On every commit or once-in-awhile ? -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] hibernate 3.2
BTW I have just branched cvs for the purposes of 3.2 development, as 3.2 is expected to introduce a number of API changes (mainly minor stuff in some of the extension APIs) and some different behaviors required for EJB3. The branch is named Branch_3_2 if you are interested... --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] hibernate 3.2
Actually yes I like that better. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Thursday, February 02, 2006 11:15 AM Cc: hibernate-devel@lists.sourceforge.net Subject: Re: [Hibernate] hibernate 3.2 Hadn't we choose to keep most advanced work on HEAD. In this case branch for 3.1.x? This is a very old discussion that seems to come out of my memory. Steve Ebersole wrote: BTW I have just branched cvs for the purposes of 3.2 development, as 3.2 is expected to introduce a number of API changes (mainly minor stuff in some of the extension APIs) and some different behaviors required for EJB3. The branch is named Branch_3_2 if you are interested... --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=kkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] hibernate 3.2
Well, I actually just switched it around. There is now a Branch_3_1 for 3.1.x development. 3.2 will progress on HEAD -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Haris Peco Sent: Thursday, February 02, 2006 12:07 PM To: hibernate-devel@lists.sourceforge.net Subject: Re: [Hibernate] hibernate 3.2 Steve, is 3.1 stuff in HEAD ? Thanks On Thursday 02 February 2006 04:35 pm, Steve Ebersole wrote: BTW I have just branched cvs for the purposes of 3.2 development, as 3.2 is expected to introduce a number of API changes (mainly minor stuff in some of the extension APIs) and some different behaviors required for EJB3. The branch is named Branch_3_2 if you are interested... --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd_ __ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid=103432bid=230486dat=121642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] Hibernate 3.1.2 released
Hibernate 3.1.2 has just been released: http://sourceforge.net/project/showfiles.php?group_id=40712package_id=1 27784release_id=388971 This release fixes, amongst other minor bugs/enhancements, bugs with Session closure checking, some potential bugs in HQL parameter binding, and issues with borrowed connections (i.e. Session.connection()) with agressive connection releasing. For a full list of changes, see the change log in the dist or check out: http://sourceforge.net/project/shownotes.php?release_id=388971group_id= 40712 --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Hibernate 3.1.2 released
LOL, I am still trying to checkout that beast ;) Thanks. -Original Message- From: Scott M Stark Sent: Saturday, January 28, 2006 10:24 AM To: Steve Ebersole; hibernate-devel@lists.sourceforge.net Subject: RE: [Hibernate] Hibernate 3.1.2 released This has been added to the repository.jboss.com contents and the org.jboss.test.hibernate.test.HibernateIntgUnitTestCase is now passing. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Saturday, January 28, 2006 6:47 AM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] Hibernate 3.1.2 released Hibernate 3.1.2 has just been released: http://sourceforge.net/project/showfiles.php?group_id=40712package_id=1 27784release_id=388971 This release fixes, amongst other minor bugs/enhancements, bugs with Session closure checking, some potential bugs in HQL parameter binding, and issues with borrowed connections (i.e. Session.connection()) with agressive connection releasing. For a full list of changes, see the change log in the dist or check out: http://sourceforge.net/project/shownotes.php?release_id=388971group_id= 40712 --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] livelink collections server
A custom Dialect should be enough, although you may need to appropriately set some configuration properties as well... The best thing to do is to simply try running the Hibernate test suite using your custom dialect; that'll give you an idea of what type/level of SQL support Hibernate is expecting that this particular database may/may not provide. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Bompart Cedric Sent: Tuesday, January 24, 2006 3:56 AM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] livelink collections server Hello, I'm just wondering what do I need to do to support another database vendor with Hibernate 3.1 ? The database is LiveLink Collections Server from OpenText (known previously as Basis) and they provide a JDBC driver. So far I've seen that I need to write a new implementation of org.hibernate.dialect.Dialect and what else ? any documentation related to that subject ? or anything to look at will be nice... :-) Regards, Ced. -- M. Cedric Bompart J2EE Architect THALES Suisse SA --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=kkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] bind variables Question
You want the user forum: http://forum.hibernate.org/ From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Srinivas Jadcharla Sent: Friday, January 20, 2006 3:20 PM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] bind variables Question Hi there, We are developing a hibernate(2.1.X) based application.We got a message from our DBA to use bind variables, not literals.What exactly that means.Here is my code ..What exactly i should do to use bind variables? try { Session session = HibernateSessionFactory.currentSession(); StringBuffer sql = new StringBuffer(); sql.append(from CswCaseParent1 as cp where (cp.clientSsnId = ').append(ssn) .append(' AND cp.clientPinId = ').append(pin) .append(') OR (cp.respondentSsnId = ').append(ssn) .append(' AND cp.respondentPinId =').append(pin).append(')); Query q1 = session.createQuery (sql.toString()); result = q1.list(); } Any help is much appreciated. -- Thanks Regards Srinivas 732-648-9421(Cell)
[Hibernate] Hibernate 3.1.1 released
Hibernate 3.1.1 has just been released including mainly bugfixes and minor improvements. For details check out the release notes: http://sourceforge.net/project/shownotes.php?release_id=386304group_id= 40712 Downloads are available at: http://sourceforge.net/project/showfiles.php?group_id=40712package_id=1 27784release_id=386304 --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnkkid3432bid#0486dat1642 ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Commit when updating db schema in hbm2ddl
Not all databases handle DDL the same in terms of transactional semantics. The simple (and most natural) solution is to bootstrap your SessionFactory (and thus run hbm2ddl) when the app deploys/starts-up, not on first access. From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Jan Janecek Sent: Friday, January 13, 2006 10:10 AM To: hibernate-devel@lists.sourceforge.net Subject: [Hibernate] Commit when updating db schema in hbm2ddl Hi, commit issued by hbm2ddl when updating database schema is fairly problematic. It failes when hbm2ddl is run in container managed bean. I have a framework that fairly well converts project in ejb3 to ejb2.1. Problem arises with injection of EntityManager. I implement this injection by an aspect. This aspect is invoked every time the field annotated with @javax.persistence.PersistenceContext is read. If it is read for the first time inside a CMP bean then hbm2ddl is run (and I want to have it run) but fails because of the mentioned commit statement. Is there a simple workaround (except for the obvious one - get the EntityManager inside a BMP bean for the first time)? Is issuing commit realy necessary at all? I've thought that ddl commands don't run in a transaction. Thanks for help, Jan PS: I'm sorry if this e-mail is inappropriate in this list but I've seen the same problem posted to the users list with no reply.
[Hibernate] Hibernate 3.1 final released
Hibernate 3.1 final has been released. It includes numerous bug-fixes and enhancements as well as upgrades to a few libraries. For details, check out the change log: http://sourceforge.net/project/shownotes.php?release_id=377721group_id= 40712 The release can be downloaded at: http://sourceforge.net/project/showfiles.php?group_id=40712package_id=1 27784release_id=377721. Starting with this release, MD5 checksums are made available along with the file releases. As always, please report bugs and/or enhancement requests via JIRA (http://opensource.atlassian.com/projects/hibernate). If you need help using Hibernate, please visit the user forums (http://forum.hibernate.org). Enjoy! --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_idv37alloc_id865op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] HQL UNION
Already planned: http://opensource.atlassian.com/projects/hibernate/browse/HHH-1050 -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Thursday, December 08, 2005 10:25 AM To: Hibernate development Subject: [Hibernate] HQL UNION I guess we should consider supporting UNION in HQL at least for report queries. It makes a lot of sense when you're working on report queries and customers have to fallback to plain JDBC for that. Since we probably some kind of mechanism for union already, why not push it even further... --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_id=7637alloc_id=16865op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_idv37alloc_id865op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Fwd: antlr 2.7.6rc1 available
Sweet, just in time ;) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Wednesday, December 07, 2005 2:55 PM To: Hibernate development Subject: [Hibernate] Fwd: antlr 2.7.6rc1 available updated antlr rc with our fixes included is now available from antlr. /max --- Forwarded message --- From: Terence Parr [EMAIL PROTECTED] To: ANTLR Interest [EMAIL PROTECTED] Cc: Subject: antlr 2.7.6rc1 available Date: Wed, 07 Dec 2005 19:15:03 +0100 http://www.antlr.org/download/antlr-2.7.6rc1.tar.gz enjoy...i'm sure I screwed up the release with all the config stuff, but please try it out. lib/antlr.jar is the jar you need. Ter -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_id=7637alloc_id=16865op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_idv37alloc_id865op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] 3.1 final
I plan on releasing 3.1 final next week, unless something unforeseen comes up. Please take a look at the JIRA issues assigned to you for inclusion in 3.1 to see if you will be able to complete them. Please let me know about any issues. http://opensource.atlassian.com/projects/hibernate/browse/HHH?report=com .atlassian.jira.plugin.system.project:roadmap-panel Thanks --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_idv37alloc_id865op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Timeout for tests
Can you give me the connection info to the various db instances? I'll try running these manually and see how long things are taking. Or have you tried this already? With Oracle for example, it is pretty important how the underlying database is setup in terms of how fast/slow the testsuite runs. In particular there is an option (the default) on the tablespace for whether or not to log operations. This logged information is then used in database recovery. But this logging really slows things down quite a bit. In my local environment, I created a dedicated tablespace where the hibernate tests occur and diable logging within this tablespace; this really sped up the testsuite (plus we don't really care about recovery of the schema here). -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Ryan Campbell Sent: Monday, November 28, 2005 7:29 AM To: Christian Bauer Cc: Hibernate development Subject: RE: [Hibernate] Timeout for tests There were at least two which were taking 200 seconds. I have lost the results I used to give you this total. The mysql and oracle runs are taking about 20 minutes each (total). timesten is taking about an hour. SQL server (jtds) and Sybase (jconnect) are both timing out completely because they fail to complete in under 3 hours. This could be a config problem, but the consistent problems I am having with long running tests make me wonder if it is some new test introducing some contention? -Original Message- From: Christian Bauer [mailto:[EMAIL PROTECTED] Sent: Monday, November 28, 2005 7:15 AM To: Ryan Campbell Cc: Hibernate development Subject: Re: [Hibernate] Timeout for tests Ryan Campbell wrote: Can there be a timeout for the tests? I'm seeing tests hang against different databases. If there was a timeout for the junit tests, these hanging tests would be reported as failures. I ran the tests on MySQL, and the longest one was 255 seconds, so perhaps 500 seconds is long enough? Is that only one test, if yes, which one? I remember one of them running between 20-30 seconds but 4 minutes seems to be a real exception. --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_idv37alloc_id865op=ick ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_idv37alloc_id865op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] query statistics
So some things to consider then: A. You will only really, truly be able to get the SQL(s) after all parameters values are known (accounting for parameter-lists) B. Parameter-lists will again cause you problems here. This is because the original parameter name is no longer known by the time the query gets to the translator, thus it is not in the parameter-metadata handed to the QueryImpl. The parameter metadata contains the expanded list of names (i.e., originalName0_, originalName1_,...). From: Max Andersen Sent: Thursday, November 24, 2005 6:05 AM To: Steve Ebersole; Gavin King; Hibernate devel Subject: RES: [Hibernate] query statistics just a quick response.  the priorities for the tools is:  A. get the underlying sql(s) B. get the guessed types of the parameters C. get the locations of the parameters in HQL and SQL  A and B is most important (and should be gettable without actually executing the query), C is not important since I can, at least for HQL, aproximate this.  So dont let C hold a better solution back if that is the case.  ;max De: [EMAIL PROTECTED] em nome de Steve Ebersole Enviada: qui 24-11-2005 03:53 Para: Gavin King; Hibernate devel Assunto: RE: [Hibernate] query statistics Well more I was thinking of delaying the param-list expansion until execution-time and handling it behind either the query-plan or the translators. There is an issue with the tools (or clients of Query in general) getting access to the actual sql to be performed. Essentially, it would not be available until after all parameter lists have been set. But afaict, this is the case regardless of which approach we choose here. So the other option would be to keep param list expansion in AbstractQueryImpl, but then pass both the source query and the expanded query to locate the query plan; the source query really only being used for statistics. Another issue here (though afaict this only affects tools) is proper resolution of named parameter locations corresponding to parameter-lists. This is due to the fact that, in the current setup, the translator only ever knows about the expanded query. -Original Message- From: Gavin King Sent: Monday, November 21, 2005 8:55 AM To: Steve Ebersole; 'Hibernate devel' Subject: RE: [Hibernate] query statistics Right. The only downside would be increased mem usage, I suppose. -Original Message- From: Steve Ebersole Sent: Monday, November 21, 2005 6:54 AM To: Gavin King; 'Hibernate devel' Subject: RE: [Hibernate] query statistics I guess we could make it so. This issue is that currently it does not know the non-expanded query. -Original Message- From: Gavin King Sent: Monday, November 21, 2005 8:51 AM To: Steve Ebersole; Hibernate devel Subject: RE: [Hibernate] query statistics Could the query plan cache both expanded and non-expanded SQL? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Monday, November 21, 2005 6:49 AM To: Hibernate devel Subject: [Hibernate] query statistics In relation to http://opensource2.atlassian.com/projects/hibernate/browse/HHH-73 (Statistics for HQL queries use pre-processed query string): The original issue behind this case is now easy to fix because of the introduction of query plans. The query plans know about the query strings before any processing has occurred. So simply moving the stats API calls into the query plans will get around the mentioned issue. However, I brought up another point there regarding parameter-list expansion. Currently, this is done within the QueryImpls, such that the expansion has occurred before the query string even gets to query plans/translators. This leads to scenarios where the HQL: from Animal where description in (:descriptionList) Results in different statistics being tracked based on the number of parameters actually contained in the bound descriptionList. To me, for the same arguments as the original issue, it is non-intuitive to issue from Animal where description in (:descriptionList) as an HQL query, but to see things like from Animal where description in (:descriptionList0_, :descriptionList1_) in the statistics. The flip side of this is that correcting this behavior means delaying generation of the actual SQL until the QueryParameters are actually known. AFAICT, this really only effects the tools since the tools want to display the translated SQL within the console; however, the SQL may not be fully resolvable at that point in time if we start delaying the resolution of the SQL till execution. So I wanted to open this up for discussion. What makes the most sense here? --- This SF.Net email is sponsored by the JBoss Inc. Get Certified Today Register for a JBoss Training Course. Free Certification Exam for All Training Attendees Through End of 2005. For more
RE: [Hibernate] query statistics
Well more I was thinking of delaying the param-list expansion until execution-time and handling it behind either the query-plan or the translators. There is an issue with the tools (or clients of Query in general) getting access to the actual sql to be performed. Essentially, it would not be available until after all parameter lists have been set. But afaict, this is the case regardless of which approach we choose here. So the other option would be to keep param list expansion in AbstractQueryImpl, but then pass both the source query and the expanded query to locate the query plan; the source query really only being used for statistics. Another issue here (though afaict this only affects tools) is proper resolution of named parameter locations corresponding to parameter-lists. This is due to the fact that, in the current setup, the translator only ever knows about the expanded query. -Original Message- From: Gavin King Sent: Monday, November 21, 2005 8:55 AM To: Steve Ebersole; 'Hibernate devel' Subject: RE: [Hibernate] query statistics Right. The only downside would be increased mem usage, I suppose. -Original Message- From: Steve Ebersole Sent: Monday, November 21, 2005 6:54 AM To: Gavin King; 'Hibernate devel' Subject: RE: [Hibernate] query statistics I guess we could make it so. This issue is that currently it does not know the non-expanded query. -Original Message- From: Gavin King Sent: Monday, November 21, 2005 8:51 AM To: Steve Ebersole; Hibernate devel Subject: RE: [Hibernate] query statistics Could the query plan cache both expanded and non-expanded SQL? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Monday, November 21, 2005 6:49 AM To: Hibernate devel Subject: [Hibernate] query statistics In relation to http://opensource2.atlassian.com/projects/hibernate/browse/HHH-73 (Statistics for HQL queries use pre-processed query string): The original issue behind this case is now easy to fix because of the introduction of query plans. The query plans know about the query strings before any processing has occurred. So simply moving the stats API calls into the query plans will get around the mentioned issue. However, I brought up another point there regarding parameter-list expansion. Currently, this is done within the QueryImpls, such that the expansion has occurred before the query string even gets to query plans/translators. This leads to scenarios where the HQL: from Animal where description in (:descriptionList) Results in different statistics being tracked based on the number of parameters actually contained in the bound descriptionList. To me, for the same arguments as the original issue, it is non-intuitive to issue from Animal where description in (:descriptionList) as an HQL query, but to see things like from Animal where description in (:descriptionList0_, :descriptionList1_) in the statistics. The flip side of this is that correcting this behavior means delaying generation of the actual SQL until the QueryParameters are actually known. AFAICT, this really only effects the tools since the tools want to display the translated SQL within the console; however, the SQL may not be fully resolvable at that point in time if we start delaying the resolution of the SQL till execution. So I wanted to open this up for discussion. What makes the most sense here? --- This SF.Net email is sponsored by the JBoss Inc. Get Certified Today Register for a JBoss Training Course. Free Certification Exam for All Training Attendees Through End of 2005. For more info visit: http://ads.osdn.com/?ad_idv28alloc_id845op=ick ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://ads.osdn.com/?ad_idv37alloc_id865op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] query statistics
In relation to http://opensource2.atlassian.com/projects/hibernate/browse/HHH-73 (Statistics for HQL queries use pre-processed query string): The original issue behind this case is now easy to fix because of the introduction of query plans. The query plans know about the query strings before any processing has occurred. So simply moving the stats API calls into the query plans will get around the mentioned issue. However, I brought up another point there regarding parameter-list expansion. Currently, this is done within the QueryImpls, such that the expansion has occurred before the query string even gets to query plans/translators. This leads to scenarios where the HQL: from Animal where description in (:descriptionList) Results in different statistics being tracked based on the number of parameters actually contained in the bound descriptionList. To me, for the same arguments as the original issue, it is non-intuitive to issue from Animal where description in (:descriptionList) as an HQL query, but to see things like from Animal where description in (:descriptionList0_, :descriptionList1_) in the statistics. The flip side of this is that correcting this behavior means delaying generation of the actual SQL until the QueryParameters are actually known. AFAICT, this really only effects the tools since the tools want to display the translated SQL within the console; however, the SQL may not be fully resolvable at that point in time if we start delaying the resolution of the SQL till execution. So I wanted to open this up for discussion. What makes the most sense here? --- This SF.Net email is sponsored by the JBoss Inc. Get Certified Today Register for a JBoss Training Course. Free Certification Exam for All Training Attendees Through End of 2005. For more info visit: http://ads.osdn.com/?ad_idv28alloc_id845op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] query statistics
I guess we could make it so. This issue is that currently it does not know the non-expanded query. -Original Message- From: Gavin King Sent: Monday, November 21, 2005 8:51 AM To: Steve Ebersole; Hibernate devel Subject: RE: [Hibernate] query statistics Could the query plan cache both expanded and non-expanded SQL? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Monday, November 21, 2005 6:49 AM To: Hibernate devel Subject: [Hibernate] query statistics In relation to http://opensource2.atlassian.com/projects/hibernate/browse/HHH-73 (Statistics for HQL queries use pre-processed query string): The original issue behind this case is now easy to fix because of the introduction of query plans. The query plans know about the query strings before any processing has occurred. So simply moving the stats API calls into the query plans will get around the mentioned issue. However, I brought up another point there regarding parameter-list expansion. Currently, this is done within the QueryImpls, such that the expansion has occurred before the query string even gets to query plans/translators. This leads to scenarios where the HQL: from Animal where description in (:descriptionList) Results in different statistics being tracked based on the number of parameters actually contained in the bound descriptionList. To me, for the same arguments as the original issue, it is non-intuitive to issue from Animal where description in (:descriptionList) as an HQL query, but to see things like from Animal where description in (:descriptionList0_, :descriptionList1_) in the statistics. The flip side of this is that correcting this behavior means delaying generation of the actual SQL until the QueryParameters are actually known. AFAICT, this really only effects the tools since the tools want to display the translated SQL within the console; however, the SQL may not be fully resolvable at that point in time if we start delaying the resolution of the SQL till execution. So I wanted to open this up for discussion. What makes the most sense here? --- This SF.Net email is sponsored by the JBoss Inc. Get Certified Today Register for a JBoss Training Course. Free Certification Exam for All Training Attendees Through End of 2005. For more info visit: http://ads.osdn.com/?ad_idv28alloc_id845op=ick ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.Net email is sponsored by the JBoss Inc. Get Certified Today Register for a JBoss Training Course. Free Certification Exam for All Training Attendees Through End of 2005. For more info visit: http://ads.osdn.com/?ad_idv28alloc_id845op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Please help keep JIRA clean! (comment for issue HHH-1005)
Yes, futile silly inane discussions such as this one kill my enthusiasm and interest a little bit every day... Tell you what: you run your project the way you want, I'll not interfere; ergo -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Leonardo Quijano Vincenzi Sent: Friday, November 18, 2005 4:50 PM To: Hibernate development Cc: Gavin King Subject: Re: [Hibernate] Please help keep JIRA clean! (comment for issue HHH-1005) Leonardo Quijano Vincenzi wrote: Gavin King wrote: Yes, but neglecting developer input is the other major reason of open source projects failure. I remember reading an essay about that, but right now I don't have much time to discuss it. (ohh I remember... it was the Cathedral and the Bazaar): Anyway, in a world of cheap PCs and fast Internet links, we find pretty consistently that the only really limiting resource is skilled attention. Open-source projects, when they founder, essentially never do so for want of machines or links or office space; they die only when the developers themselves lose interest. just to make a better point ;). -- Ing. Leonardo Quijano Vincenzi Director Técnico DTQ Software --- This SF.Net email is sponsored by the JBoss Inc. Get Certified Today Register for a JBoss Training Course. Free Certification Exam for All Training Attendees Through End of 2005. For more info visit: http://ads.osdn.com/?ad_id=7628alloc_id=16845op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.Net email is sponsored by the JBoss Inc. Get Certified Today Register for a JBoss Training Course. Free Certification Exam for All Training Attendees Through End of 2005. For more info visit: http://ads.osdn.com/?ad_idv28alloc_id845op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Fwd: Re: [Hibernate] Provision of source-only downloads for releases]
I tag CVS first, and then use that to do the build. So no problem there... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Barry Hawkins Sent: Friday, November 18, 2005 6:48 PM To: Hibernate devel Subject: [Fwd: Re: [Hibernate] Provision of source-only downloads for releases] -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 John Franey wrote: Barry, Hibernate provides a source only distribution, accessible via CVS (not FTP or HTTP). See: http://www.hibernate.org/6.html John [...] John, Yes, thanks. That is what I am using currently instead of manually stripping the current download. I first mentioned it several months back[0], and at that time Christian had confirmed that the tags in the repo could be used to generate a source tarball. As long as that will reliably reflect the content of a given release download, we can continue to do that. Sometimes tagging may happen slightly after the generation of a release build, and if commits occur in between it might produce unreliable results, hence the proposition. [0] - http://sourceforge.net/mailarchive/forum.php?thread_id=6923875forum_id= 7517 Regards, - -- Barry Hawkins All Things Computed site: www.alltc.com weblog: www.yepthatsme.com Registered Linux User #368650 -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.2 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFDfnZLHuKcDICy0QoRAvcUAKCvRJjV8AF/v62yEMBm/3G+k4+A1QCfVtox 8UzmL1ra/3O5DX8h0+4eICA= =H5tO -END PGP SIGNATURE- --- This SF.Net email is sponsored by the JBoss Inc. Get Certified Today Register for a JBoss Training Course. Free Certification Exam for All Training Attendees Through End of 2005. For more info visit: http://ads.osdn.com/?ad_id=7628alloc_id=16845op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.Net email is sponsored by the JBoss Inc. Get Certified Today Register for a JBoss Training Course. Free Certification Exam for All Training Attendees Through End of 2005. For more info visit: http://ads.osdn.com/?ad_idv28alloc_id845op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] Hibernate 3.1rc3 released
Hibernate 3.1rc3 has just been released. This release contains various bugfixes, as well as improvements and enhancements regarding caching of HQL and native SQL queries. Please see the release notes and changelog for more details: http://sourceforge.net/project/shownotes.php?release_id=371697group_id= 40712 The release can be downloaded at: http://sourceforge.net/project/showfiles.php?group_id=40712package_id=1 27784release_id=371697 This is expected to be the final release candidate for 3.1. Consult the roadmap for more information: http://opensource2.atlassian.com/projects/hibernate/browse/HHH?report=co m.atlassian.jira.plugin.system.project:roadmap-panel --- This SF.Net email is sponsored by the JBoss Inc. Get Certified Today Register for a JBoss Training Course. Free Certification Exam for All Training Attendees Through End of 2005. For more info visit: http://ads.osdn.com/?ad_idv28alloc_id845op=click ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] you just gotta love sf.net....
Geez... SF dev CVS is *still* down; highly annoying! -Original Message- From: Steve Ebersole Sent: Friday, November 11, 2005 10:26 AM To: Scott M Stark; Max Andersen Cc: Hibernate development Subject: RE: [Hibernate] you just gotta love sf.net I plan to have a look at that in the near future. Although I am more thinking of the subversion repo. Even as we speak, I am trying to get rc3 ready to go and am not able to commit some changes. Arggh! What timing ;) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Scott M Stark Sent: Friday, November 11, 2005 10:20 AM To: Max Andersen Cc: Hibernate development Subject: Re: [Hibernate] you just gotta love sf.net We should move the cvs repo to the jboss hosted one. Max Rydahl Andersen wrote: ...when you do an update and their sucky cvs server is suddenly in lock-mode and I lose 5 files and can't compile my hibernate3 anymore FYI http://sourceforge.net/tracker/?group_id=1atid=21 has about the first 40-50 cases about read-only cvs at the moment but noone with an answer. yippie! I'll just go look at the foggy view instead... Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] query plans
SQL query caching is in there... -Original Message- From: Max Andersen Sent: Sunday, November 06, 2005 11:53 AM To: Steve Ebersole; Hibernate development Subject: Re: [Hibernate] query plans Nice stuff - give a ping when sql query caching is in there somewhere ;) btw. if you know by heart what you replace sessionFactoryImpl.getQuery(query, false, Collections.EMPTY_MAP); then let me know ;) (or do i need a session now to create a query and get the generated sql etc. ?) /max As an fyi... I just checked in a bunch of changes related to how queries translations are cached. I added a new concept of query plans and a QueryPlanCache to encapsulate the role that used to be filled by the building and caching of the QueryTranslator arrays within SessionFactory. This has a number of significant ramifications: 1) HQL queries and collection-filters are now translated as soon as they are encountered (i.e. as soon as createQuery()/createFilter() are called). Two important things to note here: first, grammar problems will now show up immediately as opposed to delayed until first execution. Second, this allows much better parameter type guessing within the Query impls when one of the untyped forms of setParameter() is called. Minorly, (although not yet exposed) this also allows the Query impls to no the source query location of all parameters (important for the tools). 2) Native-SQL query translations are now cached. This caching, however, happens only after first execution since not all pertinent information is known at the time createSQLQuery() is called. Currently, named native-SQL queries are not cached at SF startup, but I'll add that support next week. The SQLQueryImpl also knows its parameter metadata just like HQL/collection-filters, but there is not enough information to properly do the expected type stuff done in HQL and collection-filters. 3) Allowed me to remove the evil initParameterBookkeeping stuff that used to be done on AbstractQueryImpl which should result in some minor performance increases (this stuff used to parse the query string each and every time a Query impl was obtained). 4) Especially for those of you interested in tools development, I created a new class that is responsible for reconginizing parameters within query strings in a unified manner. This class, for example, is now used exclusively within the query plans to determine the proper parameter locations. Essentially, it is a very simple parser with a small pre-defined number of recognized tokens. Have a look at org.hibernate.engine.query.ParameterParser and especially the different impls of org.hibernate.engine.query.ParameterParser$Recognizer. Anyway, all this is still not completely done to my satisfaction, but it's a good start. Because these are some very broad changes, I will plan to go with a 3.1rc3 including this stuff (maybe late next week). The current plan is that 3.1 final will then be the release after that. P.S. part of these changes required a modification to the constructor for AbstractQueryImpl to add a new parameter. There were two constructors on SQLQueryImpl for which I could not find any usages within the Hibernate core code-base. If these effect someone (tools?, annotations?, ejb3?) let me know. Otherwise I actually plan to go back and remove those constructors. --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] query plans
Yes, try reading what you quoted from me again ;) -Original Message- From: Max Andersen Sent: Sunday, November 06, 2005 3:24 PM To: Steve Ebersole; Hibernate development Subject: Re: [Hibernate] query plans SQL query caching is in there... ok - where ? Can't find it. And from your mail it sounded like you would not have this before next week. Currently, named native-SQL queries are not cached at SF startup, but I'll add that support next week. /max -Original Message- From: Max Andersen Sent: Sunday, November 06, 2005 11:53 AM To: Steve Ebersole; Hibernate development Subject: Re: [Hibernate] query plans Nice stuff - give a ping when sql query caching is in there somewhere ;) btw. if you know by heart what you replace sessionFactoryImpl.getQuery(query, false, Collections.EMPTY_MAP); then let me know ;) (or do i need a session now to create a query and get the generated sql etc. ?) /max As an fyi... I just checked in a bunch of changes related to how queries translations are cached. I added a new concept of query plans and a QueryPlanCache to encapsulate the role that used to be filled by the building and caching of the QueryTranslator arrays within SessionFactory. This has a number of significant ramifications: 1) HQL queries and collection-filters are now translated as soon as they are encountered (i.e. as soon as createQuery()/createFilter() are called). Two important things to note here: first, grammar problems will now show up immediately as opposed to delayed until first execution. Second, this allows much better parameter type guessing within the Query impls when one of the untyped forms of setParameter() is called. Minorly, (although not yet exposed) this also allows the Query impls to no the source query location of all parameters (important for the tools). 2) Native-SQL query translations are now cached. This caching, however, happens only after first execution since not all pertinent information is known at the time createSQLQuery() is called. Currently, named native-SQL queries are not cached at SF startup, but I'll add that support next week. The SQLQueryImpl also knows its parameter metadata just like HQL/collection-filters, but there is not enough information to properly do the expected type stuff done in HQL and collection-filters. 3) Allowed me to remove the evil initParameterBookkeeping stuff that used to be done on AbstractQueryImpl which should result in some minor performance increases (this stuff used to parse the query string each and every time a Query impl was obtained). 4) Especially for those of you interested in tools development, I created a new class that is responsible for reconginizing parameters within query strings in a unified manner. This class, for example, is now used exclusively within the query plans to determine the proper parameter locations. Essentially, it is a very simple parser with a small pre-defined number of recognized tokens. Have a look at org.hibernate.engine.query.ParameterParser and especially the different impls of org.hibernate.engine.query.ParameterParser$Recognizer. Anyway, all this is still not completely done to my satisfaction, but it's a good start. Because these are some very broad changes, I will plan to go with a 3.1rc3 including this stuff (maybe late next week). The current plan is that 3.1 final will then be the release after that. P.S. part of these changes required a modification to the constructor for AbstractQueryImpl to add a new parameter. There were two constructors on SQLQueryImpl for which I could not find any usages within the Hibernate core code-base. If these effect someone (tools?, annotations?, ejb3?) let me know. Otherwise I actually plan to go back and remove those constructors. --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] query plans
As an fyi... I just checked in a bunch of changes related to how queries translations are cached. I added a new concept of query plans and a QueryPlanCache to encapsulate the role that used to be filled by the building and caching of the QueryTranslator arrays within SessionFactory. This has a number of significant ramifications: 1) HQL queries and collection-filters are now translated as soon as they are encountered (i.e. as soon as createQuery()/createFilter() are called). Two important things to note here: first, grammar problems will now show up immediately as opposed to delayed until first execution. Second, this allows much better parameter type guessing within the Query impls when one of the untyped forms of setParameter() is called. Minorly, (although not yet exposed) this also allows the Query impls to no the source query location of all parameters (important for the tools). 2) Native-SQL query translations are now cached. This caching, however, happens only after first execution since not all pertinent information is known at the time createSQLQuery() is called. Currently, named native-SQL queries are not cached at SF startup, but I'll add that support next week. The SQLQueryImpl also knows its parameter metadata just like HQL/collection-filters, but there is not enough information to properly do the expected type stuff done in HQL and collection-filters. 3) Allowed me to remove the evil initParameterBookkeeping stuff that used to be done on AbstractQueryImpl which should result in some minor performance increases (this stuff used to parse the query string each and every time a Query impl was obtained). 4) Especially for those of you interested in tools development, I created a new class that is responsible for reconginizing parameters within query strings in a unified manner. This class, for example, is now used exclusively within the query plans to determine the proper parameter locations. Essentially, it is a very simple parser with a small pre-defined number of recognized tokens. Have a look at org.hibernate.engine.query.ParameterParser and especially the different impls of org.hibernate.engine.query.ParameterParser$Recognizer. Anyway, all this is still not completely done to my satisfaction, but it's a good start. Because these are some very broad changes, I will plan to go with a 3.1rc3 including this stuff (maybe late next week). The current plan is that 3.1 final will then be the release after that. P.S. part of these changes required a modification to the constructor for AbstractQueryImpl to add a new parameter. There were two constructors on SQLQueryImpl for which I could not find any usages within the Hibernate core code-base. If these effect someone (tools?, annotations?, ejb3?) let me know. Otherwise I actually plan to go back and remove those constructors. --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] Hibernate 3.1 rc2 released
Hibernate 3.1 rc2 has just been released. It contains some minor bug fixes and changes to handling of connection release mode. Please see the Change Log and Release Notes for more details: http://sourceforge.net/project/shownotes.php?release_id=364170 The release can be downloaded at: http://sourceforge.net/project/showfiles.php?group_id=40712package_id=1 27784release_id=364170 Things are moving quickly towards a 3.1 final release. Be sure to check out the roadmap for details regarding progression towards the final: http://opensource2.atlassian.com/projects/hibernate/browse/HHH?report=co m.atlassian.jira.plugin.system.project:roadmap-panel --- This SF.Net email is sponsored by: Power Architecture Resource Center: Free content, downloads, discussions, and more. http://solutions.newsforge.com/ibmarch.tmpl ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] 3.1 rc2
#1 - cool, just let me know when you are done. #2 - is not bubbled up to Query yet. I need to finish some other refactoring regarding how queries are parsed/cached first. Just follow HHH-844 and its related cases for the status. Yes, there are type-less setParameter() methods on Query. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Saturday, October 15, 2005 4:56 AM To: Hibernate development Subject: Re: [Hibernate] 3.1 rc2 1. I want to add a new operation persistOnFlush Remember why we did introduce the PERSIST_ON_FLUSH cascading action? For EJB3 flush efficiency In the current impl, it is only used for the first level of flushing in EJB3 (ie action inherited from FlushEventListener.getCascadingAction() To workaround that, I've introduced a persistOnFlush operation (not public to the session), but visible through the event listener system (create-onflush tag) I still need to test, but I'll be able to commit by the end of the week-end 2. How does the type discovery work? Did you add a typeless setParameter() to the Query? Steve Ebersole wrote: So as far as I am concerned, I am ready to push out 3.1rc2. Anything anyone else wanted to get into this before I cut it? I hope to get time to do it this weekend. If not, it'll be early next week. Here is the change-log so far: ** Bug * [HHH-1045] - Example contains inner classes that aren't serializable ** Improvement * [HHH-1038] - make 'auto' the default for hibernate.connection.release_mode * [HHH-1042] - determine expected type of parameter during HQL parsing It is really for HHH-1038 that I want to get this out there. --- This SF.Net email is sponsored by: Power Architecture Resource Center: Free content, downloads, discussions, and more. http://solutions.newsforge.com/ibmarch.tmpl ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.Net email is sponsored by: Power Architecture Resource Center: Free content, downloads, discussions, and more. http://solutions.newsforge.com/ibmarch.tmpl ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.Net email is sponsored by: Power Architecture Resource Center: Free content, downloads, discussions, and more. http://solutions.newsforge.com/ibmarch.tmpl ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Re: [JBoss-dev] switch to derby in JB5?
There maybe some setting we are just missing for test purposes. For example, I don't know about you, but on my Oracle setup I disable recovery logging on the datafiles backing my test schema. Without disabling this option, it is painfully slow to run the testsuite against Oracle; and obviously I don't care about recovery of my test data ;). Wasn't one of the Derby guys interested in helping us with any issues we encountered in Derby usage/adoption? -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Saturday, October 15, 2005 5:18 AM To: Emmanuel Bernard Cc: jboss-development@lists.sourceforge.net; Hibernate development Subject: Re: [Hibernate] Re: [JBoss-dev] switch to derby in JB5? Hi, yes - there is alot more weird limitations, but Derby is not alone in that aspect (db2 comes to mind ;) But the turnaorund performance is disappointing. /max AFAIR, the DDL generation fails on my test suite for this DB. They are too strict in some are. So unless they've relaxed some restriction, it's a nope for me. Max Rydahl Andersen wrote: Hi, A small FYI crosspost here since both communities has talked about it. Tonight I tried out Derby and followed the advise about running Derby with the JVM wide system property derby.system.durability to the value test. It certainly has an effect, but Derby is still sluggish with this setting compared to all other dbs on my box (mysql, oracle and hsql) - maybe the dialect can be tuned more; but as a development db HSQL still has a *much* better turnaround time. /max Sacha Labourey wrote: I think that Alexey had evaluated it (right?) and mentionned it was nowhere close from the original closed source product. Maybe I am mistaken... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: mardi, 20. septembre 2005 19:31 To: jboss-development@lists.sourceforge.net Subject: Re: [JBoss-dev] switch to derby in JB5? Its been very slow compared to using hsqldb with hibernate test suite - at least the two times i tried to use it. It seems like it is not very well optimized for DDL and queries when running in embedded mode. That might have changed, but it should at least be tested/considered before changing away from the test/developer friendly hsqld. When Derby were named Cloudscape it actually had more sql features and were faster...but apparently they did their best to make it DB2 compliant ;) /max Its been asked in the past. Someone needs to validate that it works as the default db and update the service to start it. Alexey has a prototype in varia: org.jboss.jdbc.DerbyDatabase -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Bill Burke Sent: Tuesday, September 20, 2005 9:29 AM To: jboss-development@lists.sourceforge.net Subject: [JBoss-dev] switch to derby in JB5? Should we switch to derby for JB5? Seems it is a fully featured DB unlike Hypersonic which supports XA and everything. -- Bill Burke Chief Architect JBoss Inc. --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ JBoss-Development mailing list JBoss-Development@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-development --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ JBoss-Development mailing list JBoss-Development@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-development -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] http://www.jboss.com/events/jbossworld JBoss World Barcelona 10-12 October --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ JBoss-Development mailing list JBoss-Development@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jboss-development --- SF.Net email
[Hibernate] 3.1 rc2
So as far as I am concerned, I am ready to push out 3.1rc2. Anything anyone else wanted to get into this before I cut it? I hope to get time to do it this weekend. If not, it'll be early next week. Here is the change-log so far: ** Bug * [HHH-1045] - Example contains inner classes that aren't serializable ** Improvement * [HHH-1038] - make 'auto' the default for hibernate.connection.release_mode * [HHH-1042] - determine expected type of parameter during HQL parsing It is really for HHH-1038 that I want to get this out there. --- This SF.Net email is sponsored by: Power Architecture Resource Center: Free content, downloads, discussions, and more. http://solutions.newsforge.com/ibmarch.tmpl ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] Session.getTransaction()
FYI, I made the JDBCContext.hibernateTransaction field transient. This worked around this issue of serializing a session with an associated transaction, which also allowed me to expose more of the methods of Session/SessionImplementor on the proxy generated from ThreadLocalSessionContext. --- This SF.Net email is sponsored by: Power Architecture Resource Center: Free content, downloads, discussions, and more. http://solutions.newsforge.com/ibmarch.tmpl ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] ThreadLocalSessionContext javadoc inconsistency
Here's another concern with the current impl for ThreadLocalSessionContext: the static accessors. Basically the way this is setup right now, users will nt be able to use this simultaneously for multiple session-factories... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Saturday, October 01, 2005 10:32 AM To: Hibernate development Subject: [Hibernate] ThreadLocalSessionContext javadoc inconsistency hi, javadoc for ThreadLocalSessionContext state: it unsafe for this impl to actually generate Session instances; thus it does not but at currentSession it does the following: if (current == null) { log.debug(Current thread doesn't have a session, opening new); bind(factory.openSession( null, Which one should it be ? btw. any reason why we can't return Session instead of classical.Session ? -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] http://www.jboss.com/events/jbossworld JBoss World Barcelona 10-12 October --- This SF.Net email is sponsored by: Power Architecture Resource Center: Free content, downloads, discussions, and more. http://solutions.newsforge.com/ibmarch.tmpl ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.Net email is sponsored by: Power Architecture Resource Center: Free content, downloads, discussions, and more. http://solutions.newsforge.com/ibmarch.tmpl ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] ThreadLocalSessionContext javadoc inconsistency
Ah yes! Forgot that it already knows about the SF to which it is bound via its constructor. So really the only changes needed here is to the static portion of ThreadLocalSessionContext. Well, it's a trivial implementation. We should either include it or at the very least post it to the Wiki. If we add it to the distro, then at least I'd have more then 3 things in that new package :) I could even refactor the Synchronization into a top-level class; then I'd have 5 things in that package :)) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Christian Bauer Sent: Monday, October 03, 2005 9:25 AM To: Hibernate development Subject: Re: [Hibernate] ThreadLocalSessionContext javadoc inconsistency Steve Ebersole wrote: Here's another concern with the current impl for ThreadLocalSessionContext: the static accessors. Basically the way this is setup right now, users will nt be able to use this simultaneously for multiple session-factories... Well, I'd say that this is one of the implement your own SessionContext cases. It would be the same but with a Map of ThreadLocals and SF name on all methods, right? --- This SF.Net email is sponsored by: Power Architecture Resource Center: Free content, downloads, discussions, and more. http://solutions.newsforge.com/ibmarch.tmpl ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- This SF.Net email is sponsored by: Power Architecture Resource Center: Free content, downloads, discussions, and more. http://solutions.newsforge.com/ibmarch.tmpl ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] ThreadLocalSessionContext javadoc inconsistency
Well, it might be doable by slightly changing the CurrentSessionContext intf slightly. Instead of currentSession(), have currentSession(SessionFactoryImplementor) Additionally for ThreadLocalSessionContext, change the bind() and unbind() methods appropriately. Its internal ThreadLocal could then keep a map of SessionFactory - Session. -Original Message- From: Max Andersen Sent: Monday, October 03, 2005 9:21 AM To: Steve Ebersole; Hibernate development Subject: Re: [Hibernate] ThreadLocalSessionContext javadoc inconsistency On Mon, 03 Oct 2005 16:15:01 +0200, Steve Ebersole [EMAIL PROTECTED] wrote: Here's another concern with the current impl for ThreadLocalSessionContext: the static accessors. Basically the way this is setup right now, users will nt be able to use this simultaneously for multiple session-factories... oh - thats not nice. This becomes a global thing...would it make sense to have getCurrentSession(string name); ...hmm i guess not...it is equally hard to keep track of the current name as well as the current sessionfactory. bummer...i had hoped to use this in the eclipse plugin, but cant because I actually here by its nature can/will have multiple session-factories with different strategies. oh well - its still a good thing for 98% of the worlds applications ;) /max -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Saturday, October 01, 2005 10:32 AM To: Hibernate development Subject: [Hibernate] ThreadLocalSessionContext javadoc inconsistency hi, javadoc for ThreadLocalSessionContext state: it unsafe for this impl to actually generate Session instances; thus it does not but at currentSession it does the following: if (current == null) { log.debug(Current thread doesn't have a session, opening new); bind(factory.openSession( null, Which one should it be ? btw. any reason why we can't return Session instead of classical.Session ? -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] http://www.jboss.com/events/jbossworld JBoss World Barcelona 10-12 October --- This SF.Net email is sponsored by: Power Architecture Resource Center: Free content, downloads, discussions, and more. http://solutions.newsforge.com/ibmarch.tmpl ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] sessionfactoryimpl.close()
Why? You can call clear() on collections marked as final. Obviously you could not null them out... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Tuesday, September 27, 2005 8:44 AM To: Gavin King; Emmanuel Bernard Cc: Hibernate development Subject: Re: [Hibernate] sessionfactoryimpl.close() Hi, We tried to do this but it requires us to un-final stuff and that is not worth it. Instead I added a comment to sf.close() about the importance of actually not keeping a reference to the sf when it is not wanted anymore. /max I think it would be perfectly reasonable to clear the internal collections. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Max Rydahl Andersen Sent: Monday, 26 September 2005 3:20 PM To: Emmanuel Bernard Cc: Hibernate development Subject: Re: [Hibernate] sessionfactoryimpl.close() OTOH, this will consume some extra CPU time for nothing since the GC will do that job anyway. is sf.close() cpu critical ? Even with a clean up it shouldn't be bad, or ? /max Max Rydahl Andersen wrote: Hi guys, Any reason why we don't empty all the collections we are holding onto in the sessionfactory ? Are we just letting that be up to the garbage collector to handle or how ? :) It is not a memory leak as the garbage collector will get them when the user actually lets go of the sessionfactory (sf = null), but it could probably save us some forum argumenting since a profiler will list the sessionfactory as a leach even after sf.close() has been called. -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] http://www.jboss.com/events/jbossworld JBoss World Barcelona 10-12 October --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel -- -- Max Rydahl Andersen callto://max.rydahl.andersen Hibernate [EMAIL PROTECTED] http://hibernate.org JBoss Inc [EMAIL PROTECTED] http://www.jboss.com/events/jbossworld JBoss World Barcelona 10-12 October --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- SF.Net email is sponsored by: Tame your development challenges with Apache's Geronimo App Server. Download it for free - -and be entered to win a 42 plasma tv or your very own Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] QuerySyntaxException not always serializable
A simpler solution would be to just add a writeObject() impl to HibernateException which culls the cause if it is not serializable (either to null or some marker). This would be all encompassing. Plus it would still allow the cause to be known (so long as no attempt is made to serialize it). -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Emmanuel Bernard Sent: Thursday, September 08, 2005 9:05 AM To: Hibernate development Subject: [Hibernate] QuerySyntaxException not always serializable To be more specific, RecognitionException the cause exception may be not Serializable (eg antlr.NoViableAltException (AST and Token are not serializable) Thus JBoss or any remote capable system clashes on remote calls. Is it OK if we do not propagate the cause exception? ie public QuerySyntaxException(RecognitionException e) { super( e.getMessage() + ( ( e.getLine() 0 e.getColumn() 0 ) ? ( near line + e.getLine() + , column + e.getColumn() ) : ), *null* ); //instead of e } Or do we consider Hibernate exceptions as not Serializable? --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] Is this dependency realistic?
If you mean will we have 3.1 final out by the end of this week; no. We are approximately 2 weeks away from 3.1rc1. There is one change I am aware of that would cause problems with the JBoss-Hibernate integration code regarding a change made to how event-listeners are registered. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Scott M Stark Sent: Monday, September 05, 2005 11:45 AM To: Hibernate devel Subject: [Hibernate] Is this dependency realistic? Bill created a dependency on a hibernate 3.1 final release for the jboss-4.0.3 release: http://jira.jboss.com/jira/browse/JBAS-1951 I would guess this also affects the har deployer. We want to get jboss-4.0.3 out end of this week, no latter than end of next week. Is this dependency realistic? --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
[Hibernate] RE: Insert...select... And version numbers
Are you serious! arrggh! :) Yes it is certainly doable for version numbers. It is actually probably doable for vm-based timestamps also. We could either use jdbc escape syntax (because I know how much you love this) to convert the string to a timestamp or, provided we knew the expected date string format, just embed the date string. UserVersionTypes might possibly even be doable. I'd have to think it through a bit. _ From: Gavin King Sent: Saturday, August 13, 2005 5:39 PM To: Steve Ebersole Cc: hibernate-devel@lists.sourceforge.net Subject: Insert...select... And version numbers I discovered that DB2 does not support parameters in the select clause of SQL insert select queries. This is a bit of a problem for the auto-version seeding stuff. Currently we generate SQL like this: insert (id, version, ...) values (seq.nextval, ?, ... ) I do have a temporary workaround for DB2, but I'm wondering how much work it would be to generate the following SQL instead: For integral version types: insert (id, version, ...) values (seq.nextval, 0, ... ) For timestamp source=db/ insert (id, version, ... ) values (seq.nextval, sysdate, ) We are still going to need parameters for UserVersionTypes and timestamp source=jvm/. Steve, what do you think? --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] RE: testing question
And the reason I did definition as a separate nested element was so that I could enforce this as a mutually-exclusive choice in the DTD. In DTD I can say this nested element OR those other two nested elements. Plus, you realize that there is no trimming involved at all in your first example compared to my first example, right? I simply chose CDATA tags to enclose my text, where you did not... -Original Message- From: Max Andersen Sent: Tuesday, August 09, 2005 5:58 AM To: Steve Ebersole; Hibernate devel Subject: Re: [Hibernate] RE: testing question i don't like database-object, but I don't have a better suggestion, so...(maybe just ddl ?) I do though have some trimming suggestions: database-object name=blahBlah createCREATE INDEX .../create drop.../drop scope dialect=org.hibernate.dialect.Oracle9Dialect/ /database-object and database-object name=blaBlah class=MyPLSQLTrigger/ (don't see much need for a separate definition tag for the class) btw. the reason for my wish for multiple create/drop's were simply to allow grouping of these construct to ensure proper ordering. Can we guarantee that with single drop/create's ? /max So I have this implemented locally. It actually uses the org.hibernate.mapping.RelationModel interface. It allows definition through the mapping file or programmatically via the Configuration. There are two basic usages: #1: database-object create ![CDATA[CREATE OR REPLACE TRIGGER t_iu_gen_prop BEFORE INSERT OR UPDATE ON gen_prop FOR EACH ROW BEGIN IF INSERTING THEN :new.lastModified := HEXTORAW( '1' ); ELSE :new.lastModified := HEXTORAW( TO_NUMBER( RAWTOHEX( :old.lastModified ) ) + 1 ); END IF; END;]] /create drop ![CDATA[DROP TRIGGER t_iu_gen_prop]] /drop !-- again, completely optional -- dialect-scope name=org.hibernate.dialect.Oracle9Dialect/ dialect-scope name=org.hibernate.dialect.OracleDialect/ /database-object #2: database-object definition class=MyPLSQLTrigger/ !-- again, completely optional -- dialect-scope name=org.hibernate.dialect.Oracle9Dialect/ dialect-scope name=org.hibernate.dialect.OracleDialect/ /database-object If anyone wants different name(s), speak now or forever hold your peace... Steve -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Monday, August 08, 2005 8:01 AM To: Hibernate devel Subject: RE: [Hibernate] RE: testing question Actually, probably even better: public interface DatabaseObject { public String sqlCreateString(); public String sqlDropString(); } ;) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Monday, August 08, 2005 7:54 AM To: Hibernate devel Subject: RE: [Hibernate] RE: testing question Yes, but I was more thinking: public interface DatabaseObject { public String getCreateCommand(); public String getDropCommand(); } because the CREATE/DROP SQL commands explicit operate on a single database object... -Original Message- From: Max Andersen Sent: Monday, August 08, 2005 7:49 AM To: Steve Ebersole; Hibernate devel Subject: Re: [Hibernate] RE: testing question And here MyTransactSQLTrigger would be a userprovided class that has String[] createSQL/dropSQL methods ? Sounds good. I was more thinking like: database-object name=WhateverMostlyForLogging create-ddl CREATE ... /create-ddl create-ddl CREATE ... /create-ddl drop-ddl DROP .. /drop-ddl /database-object but I guess both are usable. /max If we just let them register something like the DatabaseObject mentioned (keyed by dialect) I guess I'm fine with that. Maybe something like: database-object class=MyTransactSQLTrigger !-- optional dialect scoping -- dialect class=o.h.d.SybaseDialect/ dialect class=o.h.d.SQLServerDialect/ /database-object database-object class=MyPLSQLTrigger !-- optional dialect scoping -- dialect class=o.h.d.OracleDialect/ dialect class=o.h.d.Oracle9Dialect/ /database-object Due to export feature, I guess DatabaseObject would really instead need to expose the create/drop strings. -Original Message- From: Max Andersen Sent: Monday, August 08, 2005 6:36 AM To: Steve Ebersole; [EMAIL PROTECTED]; Hibernate devel Subject: Re: testing question This is the same reason why I always get failures on the tests relating to stored procedure support. These tests creates the SP's before testing - thus if you get errors while running junit test then that is something that should be failing. How about simply
RE: [Hibernate] RE: testing question
Also, I guess a note about the ordering of the statements is in order. So the Configuration maintains a list of the database-objects/ bound. For the create script it appends them unto the end of the current processing. For the drop script it adds them to the beginning. So I assume you are referring to the ordering amongst the different database-object/s, which is my previous answer... Overall, for large mapping sets, I basically envisioned this as being done in a separate mapping file just like we suggest for things like cache strategies, etc anyway. The only fool-proof way to achieve this is to introduce a notion of dependencies, which I don't think we want to get into. That's my $.02 at any rate. P.S. I choose database-object/ because in my setup, that's what you are defining: one database object. -Original Message- From: Max Andersen Sent: Tuesday, August 09, 2005 5:58 AM To: Steve Ebersole; Hibernate devel Subject: Re: [Hibernate] RE: testing question i don't like database-object, but I don't have a better suggestion, so...(maybe just ddl ?) I do though have some trimming suggestions: database-object name=blahBlah createCREATE INDEX .../create drop.../drop scope dialect=org.hibernate.dialect.Oracle9Dialect/ /database-object and database-object name=blaBlah class=MyPLSQLTrigger/ (don't see much need for a separate definition tag for the class) btw. the reason for my wish for multiple create/drop's were simply to allow grouping of these construct to ensure proper ordering. Can we guarantee that with single drop/create's ? /max So I have this implemented locally. It actually uses the org.hibernate.mapping.RelationModel interface. It allows definition through the mapping file or programmatically via the Configuration. There are two basic usages: #1: database-object create ![CDATA[CREATE OR REPLACE TRIGGER t_iu_gen_prop BEFORE INSERT OR UPDATE ON gen_prop FOR EACH ROW BEGIN IF INSERTING THEN :new.lastModified := HEXTORAW( '1' ); ELSE :new.lastModified := HEXTORAW( TO_NUMBER( RAWTOHEX( :old.lastModified ) ) + 1 ); END IF; END;]] /create drop ![CDATA[DROP TRIGGER t_iu_gen_prop]] /drop !-- again, completely optional -- dialect-scope name=org.hibernate.dialect.Oracle9Dialect/ dialect-scope name=org.hibernate.dialect.OracleDialect/ /database-object #2: database-object definition class=MyPLSQLTrigger/ !-- again, completely optional -- dialect-scope name=org.hibernate.dialect.Oracle9Dialect/ dialect-scope name=org.hibernate.dialect.OracleDialect/ /database-object If anyone wants different name(s), speak now or forever hold your peace... Steve -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Monday, August 08, 2005 8:01 AM To: Hibernate devel Subject: RE: [Hibernate] RE: testing question Actually, probably even better: public interface DatabaseObject { public String sqlCreateString(); public String sqlDropString(); } ;) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Monday, August 08, 2005 7:54 AM To: Hibernate devel Subject: RE: [Hibernate] RE: testing question Yes, but I was more thinking: public interface DatabaseObject { public String getCreateCommand(); public String getDropCommand(); } because the CREATE/DROP SQL commands explicit operate on a single database object... -Original Message- From: Max Andersen Sent: Monday, August 08, 2005 7:49 AM To: Steve Ebersole; Hibernate devel Subject: Re: [Hibernate] RE: testing question And here MyTransactSQLTrigger would be a userprovided class that has String[] createSQL/dropSQL methods ? Sounds good. I was more thinking like: database-object name=WhateverMostlyForLogging create-ddl CREATE ... /create-ddl create-ddl CREATE ... /create-ddl drop-ddl DROP .. /drop-ddl /database-object but I guess both are usable. /max If we just let them register something like the DatabaseObject mentioned (keyed by dialect) I guess I'm fine with that. Maybe something like: database-object class=MyTransactSQLTrigger !-- optional dialect scoping -- dialect class=o.h.d.SybaseDialect/ dialect class=o.h.d.SQLServerDialect/ /database-object database-object class=MyPLSQLTrigger !-- optional dialect scoping -- dialect class=o.h.d.OracleDialect/ dialect class=o.h.d.Oracle9Dialect/ /database-object Due to export feature, I guess DatabaseObject would really instead need to expose the create/drop strings. -Original Message- From
RE: [Hibernate] RE: testing question
Why a name, though? I was not planning on allowing lookup of these things as I don't see a benefit of allowing it. Do you see a benefit to it? Hard to explain a configuration necessity that has no purpose... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Christian Bauer Sent: Monday, August 08, 2005 1:55 PM To: Hibernate devel Subject: Re: [Hibernate] RE: testing question On Aug 8, 2005, at 8:48 PM, Steve Ebersole wrote: If anyone wants different name(s), speak now or forever hold your peace... I think it should have a name= attribute so we keep a consistent catalog in the Configuration. --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] RE: testing question
Let's move this discussion over to: http://opensource.atlassian.com/projects/hibernate/browse/HHH-840 -Original Message- From: Max Andersen Sent: Tuesday, August 09, 2005 5:58 AM To: Steve Ebersole; Hibernate devel Subject: Re: [Hibernate] RE: testing question i don't like database-object, but I don't have a better suggestion, so...(maybe just ddl ?) I do though have some trimming suggestions: database-object name=blahBlah createCREATE INDEX .../create drop.../drop scope dialect=org.hibernate.dialect.Oracle9Dialect/ /database-object and database-object name=blaBlah class=MyPLSQLTrigger/ (don't see much need for a separate definition tag for the class) btw. the reason for my wish for multiple create/drop's were simply to allow grouping of these construct to ensure proper ordering. Can we guarantee that with single drop/create's ? /max So I have this implemented locally. It actually uses the org.hibernate.mapping.RelationModel interface. It allows definition through the mapping file or programmatically via the Configuration. There are two basic usages: #1: database-object create ![CDATA[CREATE OR REPLACE TRIGGER t_iu_gen_prop BEFORE INSERT OR UPDATE ON gen_prop FOR EACH ROW BEGIN IF INSERTING THEN :new.lastModified := HEXTORAW( '1' ); ELSE :new.lastModified := HEXTORAW( TO_NUMBER( RAWTOHEX( :old.lastModified ) ) + 1 ); END IF; END;]] /create drop ![CDATA[DROP TRIGGER t_iu_gen_prop]] /drop !-- again, completely optional -- dialect-scope name=org.hibernate.dialect.Oracle9Dialect/ dialect-scope name=org.hibernate.dialect.OracleDialect/ /database-object #2: database-object definition class=MyPLSQLTrigger/ !-- again, completely optional -- dialect-scope name=org.hibernate.dialect.Oracle9Dialect/ dialect-scope name=org.hibernate.dialect.OracleDialect/ /database-object If anyone wants different name(s), speak now or forever hold your peace... Steve -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Monday, August 08, 2005 8:01 AM To: Hibernate devel Subject: RE: [Hibernate] RE: testing question Actually, probably even better: public interface DatabaseObject { public String sqlCreateString(); public String sqlDropString(); } ;) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Monday, August 08, 2005 7:54 AM To: Hibernate devel Subject: RE: [Hibernate] RE: testing question Yes, but I was more thinking: public interface DatabaseObject { public String getCreateCommand(); public String getDropCommand(); } because the CREATE/DROP SQL commands explicit operate on a single database object... -Original Message- From: Max Andersen Sent: Monday, August 08, 2005 7:49 AM To: Steve Ebersole; Hibernate devel Subject: Re: [Hibernate] RE: testing question And here MyTransactSQLTrigger would be a userprovided class that has String[] createSQL/dropSQL methods ? Sounds good. I was more thinking like: database-object name=WhateverMostlyForLogging create-ddl CREATE ... /create-ddl create-ddl CREATE ... /create-ddl drop-ddl DROP .. /drop-ddl /database-object but I guess both are usable. /max If we just let them register something like the DatabaseObject mentioned (keyed by dialect) I guess I'm fine with that. Maybe something like: database-object class=MyTransactSQLTrigger !-- optional dialect scoping -- dialect class=o.h.d.SybaseDialect/ dialect class=o.h.d.SQLServerDialect/ /database-object database-object class=MyPLSQLTrigger !-- optional dialect scoping -- dialect class=o.h.d.OracleDialect/ dialect class=o.h.d.Oracle9Dialect/ /database-object Due to export feature, I guess DatabaseObject would really instead need to expose the create/drop strings. -Original Message- From: Max Andersen Sent: Monday, August 08, 2005 6:36 AM To: Steve Ebersole; [EMAIL PROTECTED]; Hibernate devel Subject: Re: testing question This is the same reason why I always get failures on the tests relating to stored procedure support. These tests creates the SP's before testing - thus if you get errors while running junit test then that is something that should be failing. How about simply extending hibernate with the possibility for user provided additional DDL's ? (been suggested before by users, but not had any compelling usecase for it...maybe our own testing is ?) /max I think we should come up with a unified way to approach this. So I'll throw out my proposal
RE: [Hibernate] RE: testing question
The binder code simply iterates the Elements, presumably in the order they appear (I think that's how Dom4J works here). But at any rate it's the same question with multiple create/drop nested elements. If Dom4J does not for some reason return the Element iterator in the expected order, it'll be the same issue... -Original Message- From: Max Andersen Sent: Tuesday, August 09, 2005 5:58 AM To: Steve Ebersole; Hibernate devel Subject: Re: [Hibernate] RE: testing question i don't like database-object, but I don't have a better suggestion, so...(maybe just ddl ?) I do though have some trimming suggestions: database-object name=blahBlah createCREATE INDEX .../create drop.../drop scope dialect=org.hibernate.dialect.Oracle9Dialect/ /database-object and database-object name=blaBlah class=MyPLSQLTrigger/ (don't see much need for a separate definition tag for the class) btw. the reason for my wish for multiple create/drop's were simply to allow grouping of these construct to ensure proper ordering. Can we guarantee that with single drop/create's ? /max So I have this implemented locally. It actually uses the org.hibernate.mapping.RelationModel interface. It allows definition through the mapping file or programmatically via the Configuration. There are two basic usages: #1: database-object create ![CDATA[CREATE OR REPLACE TRIGGER t_iu_gen_prop BEFORE INSERT OR UPDATE ON gen_prop FOR EACH ROW BEGIN IF INSERTING THEN :new.lastModified := HEXTORAW( '1' ); ELSE :new.lastModified := HEXTORAW( TO_NUMBER( RAWTOHEX( :old.lastModified ) ) + 1 ); END IF; END;]] /create drop ![CDATA[DROP TRIGGER t_iu_gen_prop]] /drop !-- again, completely optional -- dialect-scope name=org.hibernate.dialect.Oracle9Dialect/ dialect-scope name=org.hibernate.dialect.OracleDialect/ /database-object #2: database-object definition class=MyPLSQLTrigger/ !-- again, completely optional -- dialect-scope name=org.hibernate.dialect.Oracle9Dialect/ dialect-scope name=org.hibernate.dialect.OracleDialect/ /database-object If anyone wants different name(s), speak now or forever hold your peace... Steve -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Monday, August 08, 2005 8:01 AM To: Hibernate devel Subject: RE: [Hibernate] RE: testing question Actually, probably even better: public interface DatabaseObject { public String sqlCreateString(); public String sqlDropString(); } ;) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Monday, August 08, 2005 7:54 AM To: Hibernate devel Subject: RE: [Hibernate] RE: testing question Yes, but I was more thinking: public interface DatabaseObject { public String getCreateCommand(); public String getDropCommand(); } because the CREATE/DROP SQL commands explicit operate on a single database object... -Original Message- From: Max Andersen Sent: Monday, August 08, 2005 7:49 AM To: Steve Ebersole; Hibernate devel Subject: Re: [Hibernate] RE: testing question And here MyTransactSQLTrigger would be a userprovided class that has String[] createSQL/dropSQL methods ? Sounds good. I was more thinking like: database-object name=WhateverMostlyForLogging create-ddl CREATE ... /create-ddl create-ddl CREATE ... /create-ddl drop-ddl DROP .. /drop-ddl /database-object but I guess both are usable. /max If we just let them register something like the DatabaseObject mentioned (keyed by dialect) I guess I'm fine with that. Maybe something like: database-object class=MyTransactSQLTrigger !-- optional dialect scoping -- dialect class=o.h.d.SybaseDialect/ dialect class=o.h.d.SQLServerDialect/ /database-object database-object class=MyPLSQLTrigger !-- optional dialect scoping -- dialect class=o.h.d.OracleDialect/ dialect class=o.h.d.Oracle9Dialect/ /database-object Due to export feature, I guess DatabaseObject would really instead need to expose the create/drop strings. -Original Message- From: Max Andersen Sent: Monday, August 08, 2005 6:36 AM To: Steve Ebersole; [EMAIL PROTECTED]; Hibernate devel Subject: Re: testing question This is the same reason why I always get failures on the tests relating to stored procedure support. These tests creates the SP's before testing - thus if you get errors while running junit test then that is something that should be failing. How about simply extending hibernate with the possibility for user provided additional DDL's ? (been
RE: [Hibernate] RE: testing question
What is the point of this for tooling if you cannot get the name of these things, and even if you could you could not do anything to them by name? So maybe there is some requirement you need from this in terms of tooling that you are not mentioning. But as it stands I still see no need for this. -Original Message- From: Max Andersen Sent: Tuesday, August 09, 2005 2:32 PM To: Steve Ebersole; Hibernate devel Subject: Re: [Hibernate] RE: testing question mainly for tooling. /max Why a name, though? I was not planning on allowing lookup of these things as I don't see a benefit of allowing it. Do you see a benefit to it? Hard to explain a configuration necessity that has no purpose... -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Christian Bauer Sent: Monday, August 08, 2005 1:55 PM To: Hibernate devel Subject: Re: [Hibernate] RE: testing question On Aug 8, 2005, at 8:48 PM, Steve Ebersole wrote: If anyone wants different name(s), speak now or forever hold your peace... I think it should have a name= attribute so we keep a consistent catalog in the Configuration. --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel
RE: [Hibernate] RE: testing question
huh? we have no table/ element... I'll check it in like this. If you feel that strongly about it, feel free to change it. -Original Message- From: Max Andersen Sent: Tuesday, August 09, 2005 2:20 PM To: Steve Ebersole; Hibernate devel Subject: Re: [Hibernate] RE: testing question the trimming were not about the CDATA, but about the definition. Did not think about the mutally-exclusive choice thing - but we don't do that normally, e.g. table and table. /max And the reason I did definition as a separate nested element was so that I could enforce this as a mutually-exclusive choice in the DTD. In DTD I can say this nested element OR those other two nested elements. Plus, you realize that there is no trimming involved at all in your first example compared to my first example, right? I simply chose CDATA tags to enclose my text, where you did not... -Original Message- From: Max Andersen Sent: Tuesday, August 09, 2005 5:58 AM To: Steve Ebersole; Hibernate devel Subject: Re: [Hibernate] RE: testing question i don't like database-object, but I don't have a better suggestion, so...(maybe just ddl ?) I do though have some trimming suggestions: database-object name=blahBlah createCREATE INDEX .../create drop.../drop scope dialect=org.hibernate.dialect.Oracle9Dialect/ /database-object and database-object name=blaBlah class=MyPLSQLTrigger/ (don't see much need for a separate definition tag for the class) btw. the reason for my wish for multiple create/drop's were simply to allow grouping of these construct to ensure proper ordering. Can we guarantee that with single drop/create's ? /max So I have this implemented locally. It actually uses the org.hibernate.mapping.RelationModel interface. It allows definition through the mapping file or programmatically via the Configuration. There are two basic usages: #1: database-object create ![CDATA[CREATE OR REPLACE TRIGGER t_iu_gen_prop BEFORE INSERT OR UPDATE ON gen_prop FOR EACH ROW BEGIN IF INSERTING THEN :new.lastModified := HEXTORAW( '1' ); ELSE :new.lastModified := HEXTORAW( TO_NUMBER( RAWTOHEX( :old.lastModified ) ) + 1 ); END IF; END;]] /create drop ![CDATA[DROP TRIGGER t_iu_gen_prop]] /drop !-- again, completely optional -- dialect-scope name=org.hibernate.dialect.Oracle9Dialect/ dialect-scope name=org.hibernate.dialect.OracleDialect/ /database-object #2: database-object definition class=MyPLSQLTrigger/ !-- again, completely optional -- dialect-scope name=org.hibernate.dialect.Oracle9Dialect/ dialect-scope name=org.hibernate.dialect.OracleDialect/ /database-object If anyone wants different name(s), speak now or forever hold your peace... Steve -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Monday, August 08, 2005 8:01 AM To: Hibernate devel Subject: RE: [Hibernate] RE: testing question Actually, probably even better: public interface DatabaseObject { public String sqlCreateString(); public String sqlDropString(); } ;) -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Steve Ebersole Sent: Monday, August 08, 2005 7:54 AM To: Hibernate devel Subject: RE: [Hibernate] RE: testing question Yes, but I was more thinking: public interface DatabaseObject { public String getCreateCommand(); public String getDropCommand(); } because the CREATE/DROP SQL commands explicit operate on a single database object... -Original Message- From: Max Andersen Sent: Monday, August 08, 2005 7:49 AM To: Steve Ebersole; Hibernate devel Subject: Re: [Hibernate] RE: testing question And here MyTransactSQLTrigger would be a userprovided class that has String[] createSQL/dropSQL methods ? Sounds good. I was more thinking like: database-object name=WhateverMostlyForLogging create-ddl CREATE ... /create-ddl create-ddl CREATE ... /create-ddl drop-ddl DROP .. /drop-ddl /database-object but I guess both are usable. /max If we just let them register something like the DatabaseObject mentioned (keyed by dialect) I guess I'm fine with that. Maybe something like: database-object class=MyTransactSQLTrigger !-- optional dialect scoping -- dialect class=o.h.d.SybaseDialect/ dialect class=o.h.d.SQLServerDialect/ /database-object database-object class=MyPLSQLTrigger !-- optional dialect scoping -- dialect class=o.h.d.OracleDialect/ dialect class=o.h.d.Oracle9Dialect/ /database-object Due to export feature, I guess DatabaseObject would really
[Hibernate] testing question
In working on this functionality to test the support for database generated values, I ran across an interesting issue with unit testing this functionality. Basically, the only real way to test this in a consistent fashion across all databases is to apply triggers to the database in use for testing (after schema generation). This is the same reason why I always get failures on the tests relating to stored procedure support. I think we should come up with a unified way to approach this. So I'll throw out my proposal as a starting point and see if anyone has better solutions. The basic idea is to have the individual tests in this category register additional db objects with the base test case class; these would be used during setUp() and tearDown() processing. DatabaseObject might look like: interface DatabaseObject { void doCreate(Connection conn); void doDrop(Connection conn); } I am thinking of a new test base class that tests relying on non-table db-object creation could extend; or even add this functionality to the existing TestCase. It would add a single new method DatabaseObject[] getAdditionalDatabaseObjects(Dialect dialect) which it would call during setUp() processing. The reason for this instead of just overriding setUp()/tearDown() would be to only execute this stuff when we actually rebuild the session fatory. The simple option would be to have each test class do this work themselves in setUp() and tearDown() for each test execution even though we are not necessarily creating/dropping the schema at that frequency. Anyway, thoughts? Steve --- SF.Net email is Sponsored by the Better Software Conference EXPO September 19-22, 2005 * San Francisco, CA * Development Lifecycle Practices Agile Plan-Driven Development * Managing Projects Teams * Testing QA Security * Process Improvement Measurement * http://www.sqe.com/bsce5sf ___ hibernate-devel mailing list hibernate-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/hibernate-devel