Re: [JBoss-user] RMI/IIOP warning
No! EJBException extends RuntimeException extends Exception extends Throwable implements java.io.Serializable. So? Burkhard - Original Message - From: Toby Allsopp [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, July 03, 2001 12:18 AM Subject: Re: [JBoss-user] RMI/IIOP warning On Sun, Jul 01, 2001 at 09:07:57PM -0400, asdfa asdfdfd wrote: public void setHostIP(String hostName) throws java.rmi.RemoteException, javax.ejb.EJBException; javax.ejb.EJBException is not a valid exception for RMI/IIOP because it is a subclass of RuntimeException. Remove this from your throws clause. Toby. ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] RMI/IIOP warning
Still it's an invalid exception of RMI/IIOP because ... it extends RuntimeException (regardless of what the superclass of RuntimeException is). --hermann PS : cf previous post of Toby ... ;-) - Original Message - From: Burkhard Vogel [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, July 04, 2001 2:36 PM Subject: Re: [JBoss-user] RMI/IIOP warning No! EJBException extends RuntimeException extends Exception extends Throwable implements java.io.Serializable. So? Burkhard - Original Message - From: Toby Allsopp [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, July 03, 2001 12:18 AM Subject: Re: [JBoss-user] RMI/IIOP warning On Sun, Jul 01, 2001 at 09:07:57PM -0400, asdfa asdfdfd wrote: public void setHostIP(String hostName) throws java.rmi.RemoteException, javax.ejb.EJBException; javax.ejb.EJBException is not a valid exception for RMI/IIOP because it is a subclass of RuntimeException. Remove this from your throws clause. Toby. ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] RMI/IIOP warning
Anyway, I have still this error message without EJBException François - Original Message - From: Hermann RANGAMANA [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, July 04, 2001 3:23 PM Subject: Re: [JBoss-user] RMI/IIOP warning Still it's an invalid exception of RMI/IIOP because ... it extends RuntimeException (regardless of what the superclass of RuntimeException is). --hermann PS : cf previous post of Toby ... ;-) - Original Message - From: Burkhard Vogel [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, July 04, 2001 2:36 PM Subject: Re: [JBoss-user] RMI/IIOP warning No! EJBException extends RuntimeException extends Exception extends Throwable implements java.io.Serializable. So? Burkhard - Original Message - From: Toby Allsopp [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, July 03, 2001 12:18 AM Subject: Re: [JBoss-user] RMI/IIOP warning On Sun, Jul 01, 2001 at 09:07:57PM -0400, asdfa asdfdfd wrote: public void setHostIP(String hostName) throws java.rmi.RemoteException, javax.ejb.EJBException; javax.ejb.EJBException is not a valid exception for RMI/IIOP because it is a subclass of RuntimeException. Remove this from your throws clause. Toby. ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] RMI/IIOP warning
ohh yes, i should realy check back with the spec before posting?!?! Burkhard - Original Message - From: Hermann RANGAMANA [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, July 04, 2001 3:23 PM Subject: Re: [JBoss-user] RMI/IIOP warning Still it's an invalid exception of RMI/IIOP because ... it extends RuntimeException (regardless of what the superclass of RuntimeException is). --hermann PS : cf previous post of Toby ... ;-) - Original Message - From: Burkhard Vogel [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, July 04, 2001 2:36 PM Subject: Re: [JBoss-user] RMI/IIOP warning No! EJBException extends RuntimeException extends Exception extends Throwable implements java.io.Serializable. So? Burkhard - Original Message - From: Toby Allsopp [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, July 03, 2001 12:18 AM Subject: Re: [JBoss-user] RMI/IIOP warning On Sun, Jul 01, 2001 at 09:07:57PM -0400, asdfa asdfdfd wrote: public void setHostIP(String hostName) throws java.rmi.RemoteException, javax.ejb.EJBException; javax.ejb.EJBException is not a valid exception for RMI/IIOP because it is a subclass of RuntimeException. Remove this from your throws clause. Toby. ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
RE: [JBoss-user] RMI/IIOP warning
I guess that your methods in the bean-class throws RemoteException. The methods in the home, and remote interface must throw RemoteException, however the method in the bean-class are no longer allowed to do that (see EJB2.0 PFD section 18, Exception handling, for more information). However I can't see why EJBException should not be a valid RMI/IIOP type??? /Per -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of François Charoy Sent: den 4 juli 2001 15:37 To: [EMAIL PROTECTED] Subject: Re: [JBoss-user] RMI/IIOP warning Anyway, I have still this error message without EJBException François - Original Message - From: Hermann RANGAMANA [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, July 04, 2001 3:23 PM Subject: Re: [JBoss-user] RMI/IIOP warning Still it's an invalid exception of RMI/IIOP because ... it extends RuntimeException (regardless of what the superclass of RuntimeException is). --hermann PS : cf previous post of Toby ... ;-) - Original Message - From: Burkhard Vogel [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, July 04, 2001 2:36 PM Subject: Re: [JBoss-user] RMI/IIOP warning No! EJBException extends RuntimeException extends Exception extends Throwable implements java.io.Serializable. So? Burkhard - Original Message - From: Toby Allsopp [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, July 03, 2001 12:18 AM Subject: Re: [JBoss-user] RMI/IIOP warning On Sun, Jul 01, 2001 at 09:07:57PM -0400, asdfa asdfdfd wrote: public void setHostIP(String hostName) throws java.rmi.RemoteException, javax.ejb.EJBException; javax.ejb.EJBException is not a valid exception for RMI/IIOP because it is a subclass of RuntimeException. Remove this from your throws clause. Toby. ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] RMI/IIOP warning
Still not. I removed all the RemoteExceptions from my bean and there is still the same message :( François - Original Message - From: Per Böckman [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, July 04, 2001 4:11 PM Subject: RE: [JBoss-user] RMI/IIOP warning I guess that your methods in the bean-class throws RemoteException. The methods in the home, and remote interface must throw RemoteException, however the method in the bean-class are no longer allowed to do that (see EJB2.0 PFD section 18, Exception handling, for more information). However I can't see why EJBException should not be a valid RMI/IIOP type??? /Per -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of François Charoy Sent: den 4 juli 2001 15:37 To: [EMAIL PROTECTED] Subject: Re: [JBoss-user] RMI/IIOP warning Anyway, I have still this error message without EJBException François - Original Message - From: Hermann RANGAMANA [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, July 04, 2001 3:23 PM Subject: Re: [JBoss-user] RMI/IIOP warning Still it's an invalid exception of RMI/IIOP because ... it extends RuntimeException (regardless of what the superclass of RuntimeException is). --hermann PS : cf previous post of Toby ... ;-) - Original Message - From: Burkhard Vogel [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Wednesday, July 04, 2001 2:36 PM Subject: Re: [JBoss-user] RMI/IIOP warning No! EJBException extends RuntimeException extends Exception extends Throwable implements java.io.Serializable. So? Burkhard - Original Message - From: Toby Allsopp [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, July 03, 2001 12:18 AM Subject: Re: [JBoss-user] RMI/IIOP warning On Sun, Jul 01, 2001 at 09:07:57PM -0400, asdfa asdfdfd wrote: public void setHostIP(String hostName) throws java.rmi.RemoteException, javax.ejb.EJBException; javax.ejb.EJBException is not a valid exception for RMI/IIOP because it is a subclass of RuntimeException. Remove this from your throws clause. Toby. ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] RMI/IIOP warning
If think it is not sufficient. These two home methods produce the same result [Verifier] Bean : Project Method : public abstract Project create(String, String) throws RemoteException, CreateException Section: 9.2.8 Warning: The method return values in the home interface must be of valid types for RMI/IIOP. [Verifier] Bean : Project Method : public abstract Project findByPrimaryKey(String) throws FinderException, RemoteException Section: 9.2.8 Warning: The method return values in the home interface must be of valid types for RMI/IIOP. What is most surprising is that the result of the verifier is not the same each time... I can't find a repeatable pattern to generate these errors and now they all occur on Home interfaces François and here is the Home file. This is surprising; package hero.project; import java.util.Collection; import java.rmi.RemoteException; import javax.ejb.*; /** * Implements Home Interface */ public interface ProjectHome extends EJBHome { /** * Create Entity Bean */ public Project create(java.lang.String name, java.lang.String creator) throws RemoteException, CreateException; /** * Finder Method by Primary Key password */ public Project findByPrimaryKey(String name) throws FinderException, RemoteException; /** * Finder Method that obtain all user projects */ public Collection findByUser(String user) throws FinderException, RemoteException; } - Original Message - From: Toby Allsopp [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Tuesday, July 03, 2001 12:18 AM Subject: Re: [JBoss-user] RMI/IIOP warning On Sun, Jul 01, 2001 at 09:07:57PM -0400, asdfa asdfdfd wrote: public void setHostIP(String hostName) throws java.rmi.RemoteException, javax.ejb.EJBException; javax.ejb.EJBException is not a valid exception for RMI/IIOP because it is a subclass of RuntimeException. Remove this from your throws clause. Toby. ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] RMI/IIOP warning
I have exactly the same kind of problem and arrived at the same conclusion. I can't see what can be wrong with these definitions. I seems to be important as I have found somewhere in the list archive that it may produce some thread leak and this is exactly what I have. When I run a set of tests, the number of thread (w2k) goes from 300 to 900 and goes down to something like 600 and stay there This happens each time I restart the tests until if breaks with an out of memory error. (conf = jboss2.2.2 + tomcat + junit + w2000 + cygwin) François - Original Message - From: asdfa asdfdfd [EMAIL PROTECTED] To: [EMAIL PROTECTED] Sent: Monday, July 02, 2001 3:07 AM Subject: [JBoss-user] RMI/IIOP warning I was wondering if anyone could help me out with this issue. I have seen a couple of posts on the list, but the responses were not helpful. I get the following warning for SOME of my beans (session or entity, it doesn't seem to matter), but not all of them: [Verifier] Bean : Service Method : public abstract Service create(String) throws CreateException, RemoteException Section: 9.2.8 Warning: The method return values in the home interface must be of valid types for RMI/IIOP. Here is the home interface for that particular class: public interface ServiceHome extends javax.ejb.EJBHome { public Service create(String serviceName) throws javax.ejb.CreateException, java.rmi.RemoteException; public Service findByPrimaryKey(ServicePK kpk) throws javax.ejb.FinderException, java.rmi.RemoteException; public java.util.Collection findAll() throws javax.ejb.FinderException, java.rmi.RemoteException; } I think this warning is bogus because I have other beans (which use almost exactly the same code, only the names are changed) which deploy with no problems. And lest someone tell me that simply making the remote interface Serializabe will solve this problem, let me ask why that is necessary at all. The remote and home interfaces will be shipped in a client jar, so the classes themselves should NOT have to be Serializable. And besides, it should be up to the container to make sure that it sends client Serializable objects that also implement my remote or home interfaces. A bean which deploys with no problem is the following: public interface FolderHome extends javax.ejb.EJBHome { public Folder create(String folderName) throws javax.ejb.CreateException, java.rmi.RemoteException; public Folder findByPrimaryKey(FolderPK fpk) throws javax.ejb.FinderException, java.rmi.RemoteException; public java.util.Collection findByFolderName(String folderName) throws javax.ejb.FinderException, java.rmi.RemoteException; } The definitions of Folder and Service are nearly identical: public interface Service extends javax.ejb.EJBObject { public long getServiceID() throws java.rmi.RemoteException; public java.lang.String getServiceName() throws java.rmi.RemoteException; public void setServiceName(String newName) throws java.rmi.RemoteException; public String getHostIP() throws java.rmi.RemoteException; public void setHostIP(String hostName) throws java.rmi.RemoteException, javax.ejb.EJBException; } public interface Folder extends javax.ejb.EJBObject { public long getFolderID() throws java.rmi.RemoteException; public java.lang.String getFolderName() throws java.rmi.RemoteException; public void setFolderName(String newName) throws java.rmi.RemoteException; public long getServiceID() throws java.rmi.RemoteException; public void setServiceID(int serviceID) throws java.rmi.RemoteException; } Except for the different method names and the different implementations in the bean itself, they are functionally identical, at least they should be to the deployer. Yet it complains about Service, but not Folder. My question is: why does this happen for some beans, but not others? I saw a previous response to another user's similar requst, that suggested I could only return Java primitives or their Serializable counterparts (java.lang.Long, java.lang.Integer, etc.). The user also suggested that you could return a Collection, but Collection doesn't implement Serializable, so why should it function differently? These seem unreasonable restrictions and I can't believe that they are the case. Does anyone have any experience with this problem? Thanks in advance for your help. Matt Dubord Get 250 color business cards for FREE! http://businesscards.lycos.com/vp/fastpath/ ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
Re: [JBoss-user] RMI/IIOP warning
On Sun, Jul 01, 2001 at 09:07:57PM -0400, asdfa asdfdfd wrote: public void setHostIP(String hostName) throws java.rmi.RemoteException, javax.ejb.EJBException; javax.ejb.EJBException is not a valid exception for RMI/IIOP because it is a subclass of RuntimeException. Remove this from your throws clause. Toby. ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user
[JBoss-user] RMI/IIOP warning
I was wondering if anyone could help me out with this issue. I have seen a couple of posts on the list, but the responses were not helpful. I get the following warning for SOME of my beans (session or entity, it doesn't seem to matter), but not all of them: [Verifier] Bean : Service Method : public abstract Service create(String) throws CreateException, RemoteException Section: 9.2.8 Warning: The method return values in the home interface must be of valid types for RMI/IIOP. Here is the home interface for that particular class: public interface ServiceHome extends javax.ejb.EJBHome { public Service create(String serviceName) throwsjavax.ejb.CreateException, java.rmi.RemoteException; public Service findByPrimaryKey(ServicePK kpk) throws javax.ejb.FinderException, java.rmi.RemoteException; public java.util.Collection findAll() throws javax.ejb.FinderException, java.rmi.RemoteException; } I think this warning is bogus because I have other beans (which use almost exactly the same code, only the names are changed) which deploy with no problems. And lest someone tell me that simply making the remote interface Serializabe will solve this problem, let me ask why that is necessary at all. The remote and home interfaces will be shipped in a client jar, so the classes themselves should NOT have to be Serializable. And besides, it should be up to the container to make sure that it sends client Serializable objects that also implement my remote or home interfaces. A bean which deploys with no problem is the following: public interface FolderHome extends javax.ejb.EJBHome { public Folder create(String folderName) throws javax.ejb.CreateException, java.rmi.RemoteException; public Folder findByPrimaryKey(FolderPK fpk) throws javax.ejb.FinderException, java.rmi.RemoteException; public java.util.Collection findByFolderName(String folderName) throws javax.ejb.FinderException, java.rmi.RemoteException; } The definitions of Folder and Service are nearly identical: public interface Service extends javax.ejb.EJBObject { public long getServiceID() throws java.rmi.RemoteException; public java.lang.String getServiceName() throws java.rmi.RemoteException; public void setServiceName(String newName) throws java.rmi.RemoteException; public String getHostIP() throws java.rmi.RemoteException; public void setHostIP(String hostName) throws java.rmi.RemoteException, javax.ejb.EJBException; } public interface Folder extends javax.ejb.EJBObject { public long getFolderID() throws java.rmi.RemoteException; public java.lang.String getFolderName() throws java.rmi.RemoteException; public void setFolderName(String newName) throws java.rmi.RemoteException; public long getServiceID() throws java.rmi.RemoteException; public void setServiceID(int serviceID) throws java.rmi.RemoteException; } Except for the different method names and the different implementations in the bean itself, they are functionally identical, at least they should be to the deployer. Yet it complains about Service, but not Folder. My question is: why does this happen for some beans, but not others? I saw a previous response to another user's similar requst, that suggested I could only return Java primitives or their Serializable counterparts (java.lang.Long, java.lang.Integer, etc.). The user also suggested that you could return a Collection, but Collection doesn't implement Serializable, so why should it function differently? These seem unreasonable restrictions and I can't believe that they are the case. Does anyone have any experience with this problem? Thanks in advance for your help. Matt Dubord Get 250 color business cards for FREE! http://businesscards.lycos.com/vp/fastpath/ ___ JBoss-user mailing list [EMAIL PROTECTED] http://lists.sourceforge.net/lists/listinfo/jboss-user