[jboss-user] [EJB 3.0 Users] - Session EJB 3.1 packaged in war file not recognized in JBoss

2009-12-07 Thread icordoba
Hello, I am trying to repackage a small EJB3 application moving the EJB jar file to .war's /WEB-INF/lib and deploying only that war, as docs say can be done with EJB3.1 specs. The Entity EJBs in that jar are recognized OK as hibernate logs show, but JBoss seems to ignore the Stateless Session

[jboss-user] [JNDI and Naming] - EJB 3.1 Global JNDI names

2009-12-07 Thread icordoba
Hello, I am testing on JBoss 6 some of the new EJB3.1 features. On JNDIView in JMX Console I see that I am getting the same JNDI naming as with JBoss 5.1 Do I have to make any changes in JBoss or in any xml deployment description to make a ear or war file be recognized as EJB 3.1 and so get then

[jboss-user] [JNDI and Naming] - Default JNDI name changed after recompiling

2009-11-10 Thread icordoba
Hi there, I have just migrated an application from JBoss 4 and Java 5 to JBoss 5.1 and Java 6. It worked OK... my Stateless Session Beans had a remote JNDi name like: UserManager/remote (as all docs state is the default remote name). For some reason I had implemented @Remote both in the

[jboss-user] [Installation, Configuration Deployment] - Re: Multiple JBoss instances vs. one

2009-10-28 Thread icordoba
Hello, thanks for the links. I had of course read them before posting but, sorry, I can't find definite information there about having to activate CallByValue. I'm sure I'm missing something. In my scenario I have to deploy two .ears and two .wars. I use classloading configuration for 2

[jboss-user] [Persistence] - Isolated ears with same name persistence unit

2009-10-28 Thread icordoba
Hello, I am deploying two different apps in two ears in JBoss 5.1. They deployed OK in JBoss 4. As I reuse compiled JEE5 classes and I use annotations, the persistence unit used in both application has the same name: mainPersistenceUnit (it has to be hardcoded). this was not a problem with

[jboss-user] [Installation, Configuration Deployment] - Multiple JBoss instances vs. one big JBoss with different

2009-10-27 Thread icordoba
hello, I start this thread to get opinions on which is the best approach when needing to deploy multiple different applications in the same server. I've been using JBoss for years starting with version 3. During this time I've used a couple of JBoss instances with scope class loading, even

[jboss-user] [Installation, Configuration Deployment] - Forcing a .war to load after a .ear

2009-10-25 Thread icordoba
Hello, I had several applications installed in JBoss 4 and had no problems with them. I had modified deployment sorter to make war file deploy after the corresponding ear file. For come reasons I need to have the war file outside the ear file, which only contains .jar files with EJBs. This was

[jboss-user] [EJB 3.0 Users] - Re: Migrating .ear to JBoss 5 with several EJB3 Jars inside

2009-10-25 Thread icordoba
Well, they are EJB3 entities. I guest they have most in common with HJPA/Hibernate entities but I try not to code anything outside EJB3 specifications, so I never deal with Hibernate in my code, even though I know it is there taking care of EJB3 persistence. May I ask if dealing with Hibernate

[jboss-user] [EJB 3.0 Users] - Migrating .ear to JBoss 5 with several EJB3 Jars inside

2009-10-09 Thread icordoba
Hello, I am migrating to JBoss 5 from Jboss 4.0.3 My application is packed in an .ear file with multiple .jar files inside. All share a common persistence unit and have relations between them. This works OK in JBoss 4.0.3 (To make it work I had to include all EJBs in the orm.xml file in the

[jboss-user] [EJB 3.0 Users] - Re: Migrating .ear to JBoss 5 with several EJB3 Jars inside

2009-10-09 Thread icordoba
Sorry, I mean, Do I have to repack my EJBs all in one jar inside the ear? Thanks :-) View the original post : http://www.jboss.org/index.html?module=bbop=viewtopicp=4259588#4259588 Reply to the post : http://www.jboss.org/index.html?module=bbop=postingmode=replyp=4259588

[jboss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Having EntityManagers in different SLSB be in sync inside

2008-12-16 Thread icordoba
Hi there, I am having a problem when working with entity managers in different stateless session beans in a same application. I include them via injection: @PersistenceContext(name=myPersistenceContext, unitName=mainPersistenceUnit) | private EntityManager entityManager; |

[jboss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Cascade.REMOVE not working between EJBs in different jars

2008-12-10 Thread icordoba
Hi there, I am having a problem with Hibernate which I don't know if it is a problem or the regular behaviour. Cascade.REMOVE is working fine for me but only between EJBs in the same .JAR (several jars, each for a differente module are packed in an .ear for my application) I deploy a .ear

[jboss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Help on join query

2008-11-06 Thread icordoba
In my system I have the following classes: File Category User Role Permission Files belong to one or more categories Users can have one or more roles A permission can refer to a file or a category of files (never both) A permission can refer to a user or role (and so affecting all users in that

[jboss-user] [Management, JMX/JBoss] - Re: How to remove a timer from JMX Console

2008-04-10 Thread icordoba
Thanks for the reply Dimitri, I'am already removing timers from the persistencePlicy MBean, but I then need to stop start Jboss. Is it possible to just stop or kill a running timer from a running JBoss without having to restart it? Thanks for your help, Ignacio View the original post :

[jboss-user] [Persistence, JBoss/CMP, Hibernate, Database] - Multiple datasources for same persistence unit

2007-12-05 Thread icordoba
Hi there, I have an application packaged in an .ear file. It has 3 jars. I've included a persistence.xml file in each jar, because all EJBs point to the same persistence unit name (they are already compiled this way). I cannot specify a different datasource for that same persistence unit name. Is

[jboss-user] [JBossCache] - Re: How to install JBoss cache from

2007-11-30 Thread icordoba
Thanks a lot for your very helpful message. I have tons of logs and screen captures, but before re-posting them, again, I decided to make that simple question. Just wanted to make sure I was copying the right files from all to default instance to use JBoss Cache. Nothing more in this thread.

[jboss-user] [JBossCache] - How to install JBoss cache from all to default server

2007-11-29 Thread icordoba
Hi there, I want to use default jboss instance with JBoss Tree Cache (JBoss version 4.2.2) I've copied jgroups.jar and jboss-cache-jdk50.jar in default/lib and ejb3-entity-cache-service.xml en default/deploy It seems to work but I am having redeploy/undeploy problems of the ears I run with

[jboss-user] [JBossCache] - Exception when redeploying .ear that uses JBoss Cache

2007-11-29 Thread icordoba
Hi there, I have no problems redeploying ears which don't use JBoss Cache. If I try to redeploy an ear using the Cache I have to stop and start JBoss because I get the following exception. Thanks for any help. 2007-11-29 12:39:43,395 WARN [org.hibernate.cache.TransactionalCache] could not

[jboss-user] [JBossCache] - Re: Exception when redeploying .ear that uses JBoss Cache

2007-11-29 Thread icordoba
Thanks a lot for your reply. It has the default value of 15000 (15 seconds?) Should I reduce it? In my code I always do a UserTransaction.commit() and a UserTransaction.setRollBackOnly in case of an exception inside the transaction. Do I have to take any other actions to be sure that

[jboss-user] [JBossCache] - Re: Exception when redeploying .ear that uses JBoss Cache

2007-11-29 Thread icordoba
Oh, sorry. Yes, that's the IP of the server in which I want to redeploy the app. I've realized that touching the ejb3-entity-cache-service.xml cache configuration file makes it easier to redeploy ears using it. (prevents previous indicated exception) I'll so set 3 for LockAcquisitionTimeout

[jboss-user] [JBossCache] - Re: Exception when redeploying .ear that uses JBoss Cache

2007-11-29 Thread icordoba
Hi again, i use Struts actions as clients, but they don't access the cache anyway. They get EJBs from a DAO SSB. I only use the Cache specifying it in the persistence.xml file for every .jar file in the ear file (that is the only way I guess I am capable of using it. Of course I don't do any

[jboss-user] [JBossCache] - Re: Exception when redeploying .ear that uses JBoss Cache

2007-11-29 Thread icordoba
Thanks a lot for your replies. I've managed to redeploy .ear's using JBoss Cache, which was my original goal in this thread. Thanks again, Ignacio View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4108994#4108994 Reply to the post :

[jboss-user] [EJB 3.0] - Re: BatchUpdateException when removing a entity with a ManyT

2007-11-07 Thread icordoba
In my case some of the entities have 2 o 3 ManyToMany each so it is tedious not to have a direct way to solve this. Thanks a lot for your reply. Ignacio View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4102459#4102459 Reply to the post :

[jboss-user] [EJB 3.0] - BatchUpdateException when removing a entity with a ManyToMan

2007-11-06 Thread icordoba
Hi there, I am getting BatchUpdateException when removing entities related to others by a ManyToMany association. Hibernate creates the link table with foreign keys and they make that BatchUpdateException to be thrown (I like tables to have foreign keys, of course). I've tried to add a REMOVE

[jboss-user] [EJB 3.0] - How to get the size of a Lazy load relation

2007-09-17 Thread icordoba
Hi there, I need to pre-load the size of a Lazy load relation. I need to do it because I need to access the Entity in a JSP and I get No session or session closed if getting the size directly from the relation (I don't want to put a Transaciton using a scriptlet in the JSP page) I can neither

[jboss-user] [EJB 3.0] - Re: How to get the size of a Lazy load relation

2007-09-17 Thread icordoba
Thanks a lot for your reply. I am trying this both as a NamedQuery or as a direct query and I am getting the following exception: 2007-09-17 17:12:05,036 DEBUG [org.hibernate.SQL] select count(.) as col_0_0_ from Role role0_, User_Role users1_, User user2_ where role0_.pkey=users1_.roles_pkey

[jboss-user] [EJB 3.0] - Re: How to get the size of a Lazy load relation

2007-09-17 Thread icordoba
I am using anonymous wrote : I am using caches in persistence.xml, I'll deactivate them just to test... :-( Thanks, Ignacio View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4085206#4085206 Reply to the post :

[jboss-user] [EJB 3.0] - Re: How to get the size of a Lazy load relation

2007-09-17 Thread icordoba
Quote tag doesnt show the tag... anyway: View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4085208#4085208 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4085208 ___ jboss-user

[jboss-user] [EJB 3.0] - Re: @PostLoad invoked before eagerly loaded property finishe

2007-08-23 Thread icordoba
Hi; I am having the same problem in a Entity postLoad method which access a eagerly loaded Set. Wierd as it doesn't happen on every Load of the entity... :-/ Did you find any sollution on this? thanks, Ignacio View the original post :

[jboss-user] [EJB 3.0] - Re: Complex query generated by 4 non-lazy relations

2007-08-22 Thread icordoba
Hi again, I don't know how to check execution plan. Which debug must I activate? thanks, Ignacio View the original post : http://www.jboss.com/index.html?module=bbop=viewtopicp=4076946#4076946 Reply to the post : http://www.jboss.com/index.html?module=bbop=postingmode=replyp=4076946

[jboss-user] [EJB 3.0] - Re: Complex query generated by 4 non-lazy relations

2007-08-21 Thread icordoba
Thanks for your reply. I don't use native queries as my components are supposed to work, for example, both with SQLServer and MySQL. I change the mappings in persistence.xml and forget about which data base I am using. One of the reasons to work with all EJB overload is to be able to forget

[jboss-user] [EJB 3.0] - Complex query generated by 4 non-lazy relations

2007-08-20 Thread icordoba
Hi there, i have a typical Portal-user-role-component structure, with obvious relations. I have to configure these relations as eager because I need to use entities in the client side (JSP page). My problem is that a very complex and slow query is generated with thousand combinations of

[jboss-user] [EJB 3.0] - Re: Working example por OneToMany cascade remove?

2007-08-10 Thread icordoba
Hi there, thanks a lot for your reply... this is the Portal side: @OneToMany(mappedBy=portal,fetch=FetchType.LAZY, cascade={CascadeType.ALL}) | public void setUsers(SetUser users) | { | this.users = users; | } | |

[jboss-user] [EJB 3.0] - Re: Working example por OneToMany cascade remove?

2007-08-10 Thread icordoba
OK.. thanks for the reply. This way, Users will the orphan and I need the special Hibernate annotation for orphans to be removed, right? Is there a way of making JBoss really remove User entities itself without that Hibernate-specific annotation? I can't understand what is then the pourpose of

[jboss-user] [EJB 3.0] - Working example por OneToMany cascade remove?

2007-08-10 Thread icordoba
Hi there, I've spent days reading threads and googling about the behaviour of the remove cascade in EJB3 but haven't been able to make Cascade.REMOVE to work in a OneToMany relation. Could anybody post a working example? I have, for example, Portals and Users. I just need that when I do a

[jboss-user] [EJB 3.0] - Re: Entity relationship and remove operations

2007-08-07 Thread icordoba
Hi there, I haven't been able to solve this same problem (deleted entity passed to persist exception when deleting a OneToMany with cascade all relation(). You say you just have to refresh the parent, but you were saying that you delete the parent and you expect the children to be deleted. If

[jboss-user] [EJB 3.0] - Reciprocal dependency injection with @EJB

2007-07-27 Thread icordoba
Hi there, how can I get a dependency injection using @EJB in two Stateless Session beans which each one needs a reference to the other one? I get a NOTYETINSTALLED status when just injecting in eachone the reference to the otherone: In UserManager: @EJB PortalManagerLocal portalmanager; in

[jboss-user] [EJB 3.0] - BUG: is id a reserved field id in EJB3 entities?

2007-07-25 Thread icordoba
Hi there, I am migrating EJB2.1 Entity Beans to EJB3 and some of them have a field named id which is not primary key. When trying to add a Query JBoss/Hibernate seems to interchange the id field with the primary key field. This seems to be a Bug as naming id with, for example userid makes

[jboss-user] [EJB 3.0] - Re: detached entity passed to persist

2007-06-24 Thread icordoba
I see this is an old thread but just in case someone nees a solution... try to enclose everyting in a UserTransaction. If you take an EJB3 entity outside the transaction, you cannot re-persist it or iterate over CMRs, etc. You need then a UserTransaction in the client side. View the original

[jboss-user] [EJB 3.0] - LazyInitializationException in PostLoad method

2007-06-16 Thread icordoba
Hi, I am getting the following exception when trying to get the size of a one to many relation in a PostLoad method. Of course, this code runs inside a SLSB DAO and should so be inside a transaction: org.hibernate.LazyInitializationException: failed to lazily initialize a collection, no session

[jboss-user] [EJB 3.0] - Which approach to fully access EJB3 Entities from within JSP

2007-06-15 Thread icordoba
Hi there, after reading lots of posts trying to find a solution to access EJB3 Entity beans from JSTL I haven't been able to get a valid approach. I can't use Lazy loading as that would make my JSP need a scriptlet to make a UserTransaction surround all data access. When using Eager loading, I

[jboss-user] [EJB 3.0] - Re: Which approach to fully access EJB3 Entities from within

2007-06-15 Thread icordoba
Just one comment. The only solution I've found is adding @transient properties to the EJBs with the following structure: @Transient | public ListCMTextblock getTextblocksList() | { | ArrayListCMTextblock list = new ArrayListCMTextblock(); |

[jboss-user] [Tomcat, HTTPD, Servlets JSP] - NoClassDefFoundError in a expanded war from its own /lib/ ja

2007-05-29 Thread icordoba
Hi there, i am trying tu configure class loading in JBoss 4.0.5 I have an .ear file with loader-repository-config and java2ParentDelegation=true I need to access classes in this .ear from my war application, deployed in a war dir (I need to work on it, can't package it in the .ear file) I've

[jboss-user] [Tomcat, HTTPD, Servlets JSP] - How to make a .ear use an expanded war classloader

2007-05-29 Thread icordoba
Hi there, I have the following scenario in my webapps: - .ear file with EJBs (2.1 3) - expanded war file with the web interface. I don't include the war in the ear file because in development moment I change many thin in JSPs / struts XMLs /... JBoss configuration What is the ClassLoading

[jboss-user] [EJB 3.0] - Re: Without rhyme or reason? a ClassCastException occured!

2007-05-28 Thread icordoba
Hi there, I am having this same problem. Did you find the solution? thanks for any info. (If i use remote interface it works OK, but when changing to local lookups of the Stateless sessiion bean, it throws the class cast exception just when invoking the method) Thanks, Ignacio View the

[jboss-user] [EJB 3.0] - Setting jndi-name in jboss.xml without ejb-jar.xml

2007-05-09 Thread icordoba
Hi there, as promised for EJB3 I am trying to get rid of ejb-jar.xml. I have a problem when trying to set jndi-name of my EJBs in jboss.xml I deploy the same EJBs in different apps and I used to set different jndi names in 2.1 EJBs in jboss.xml. Doing so I am getting the following error:

[jboss-user] [Management, JMX/JBoss] - How to remove a timer from JMX Console

2007-02-05 Thread icordoba
Hi there, I have a big problem in a very important JBoss App. It creates several instances of the same timer. Until I fix it I need to remove the duplicated instances without shutting down JBoss. I see in JMX Console, listing Timers: [target=jboss.j2ee:jndiName=tuportal/MailRelay,service=EJB]

[jboss-user] [Management, JMX/JBoss] - How to remove a Timer using JMX Console

2006-09-20 Thread icordoba
Hi there, I have repeated timers for the same service due to a error in an application which code cannot be modified now. How can I remove duplicated timers from JMX Console? I don't know which parameters I must introduce in the removeTimerService() MBean Operation I can list them invoking