[JBoss-user] [EJB 3.0] - Re: Catching exceptions in Session Bean

2006-06-07 Thread gommo
Well I worked this out. It seemed jboss throws an EntityExistsException and the inner exception is ConstraintViolationException. Was this changed in 4.0.4.GA todo this?? Thanks View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=3949594#3949594 Reply to the post

[JBoss-user] [EJB 3.0] - Catching exceptions in Session Bean

2006-06-05 Thread gommo
Hello, Has something changed with the way you catch exceptions from session beans in 4.0.4.GA?? I was successfully catching ConstraintViolationExceptions by the methods already discussed on this forum. Namely 1. flushing the entity manager 2. catching ConstraintViolationException 3. throwing

[JBoss-user] [EJB 3.0] - Unit Testing EJB3 Strategies

2006-06-05 Thread gommo
Hello, I'm looking for some feedback/pointers to start unit testing my application which makes use of EJB3 and using PostgreSQL I'm going to use the TestNG framework and I have that all setup and running and am now starting to setup the EJB3 standalone container. Is it usual to create say a

[JBoss-user] [EJB 3.0] - Re: MIgrating to 4.0.4RC1 from 4.0.3SP1 and no Entity Beans

2006-03-30 Thread gommo
Thanks, I worked out I needed hibernate .hbm2ddl.auto = update So my Database tables are created if they arent there (or missing FK s etc..) but arent removed. I thought this would have been the default. What type of circumstances would you use create-drop. Doesnt that defeat the purpose of

[JBoss-user] [EJB 3.0] - MIgrating to 4.0.4RC1 from 4.0.3SP1 and no Entity Beans are

2006-03-29 Thread gommo
Hi, I've been pulling my hair out for hours now migrating from 4.0.3SP1 to 4.0.4RC1. I'm using Postgres 8.1 as by database. My one remaining issue seems to be that my entity beans are either not being deployed or are using hibernate instead. No exceptions seem to be thrown at startup, JBoss is

[JBoss-user] [EJB 3.0] - Re: MIgrating to 4.0.4RC1 from 4.0.3SP1 and no Entity Beans

2006-03-29 Thread gommo
Interestingly, I removed the database from postgres and I get an exception on deployment that org.jboss.resource.JBossResourceException: Could not create connection; - nested throwable: (org.postgresql.util.PSQLException: FATAL: database posejb3 does not exist) So I know the persistence is

[JBoss-user] [Persistence,JBoss/CMP, Hibernate, Database] - Disappearing Foreign Key Constraints

2006-03-23 Thread gommo
Hi, I'm using Postgres 8.1 Jboss 4.0.3SP1. I've just noticed that when I shut down JBoss, my foreign key constraints are gone, and then when I start it back up they are created again. Is this normal behavious? Thanks View the original post :

[JBoss-user] [EJB/JBoss] - Use Primitives or Not to use Primitives

2006-02-26 Thread gommo
(EJB3) Is it bad design to use primitives such as int, long, boolean etc.. in Entity beans? The reason I ask is that I created an entity on the client but didnt set the primary key (which was a long). I forgot to put code in to set the primary key before calling persist. As a result it was

[JBoss-user] [Messaging, JMS JBossMQ] - Stack trace on createTopicConnection

2005-06-25 Thread gommo
I am starting up a subscriber connection to a topic. As soon as I call createTopicConnection I get a fairly large bunch of messages printed to the console as well as a stack trace but it almost appears as if this is just debug output. Is this normal? And if so can I shut it off? Or is it an