Re: [JBoss-dev] Accessing Container from an EJB?
I don't think EJB can access its container directly. However maybe you could add an interceptor in stack that does nothing but provides you information you need, because they have access to container. Then your EJB could contact interceptor (with static call for instance) Maybe is it possible via JMX also ? julien JB I am trying to write an EJBTestCase that needs access to information held in JB the Container (Container.getEjbModule().getModuleData(CATALOG)). I can do JB this if I add EjbModule as a attribute of Container but was wondering if I JB should do this or if there was another way? JB Thanks JB Jeremy JB --- JB This SF.NET email is sponsored by: JB SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! JB http://www.vasoftware.com JB ___ JB Jboss-development mailing list JB [EMAIL PROTECTED] JB https://lists.sourceforge.net/lists/listinfo/jboss-development -- Best regards, julienmailto:[EMAIL PROTECTED] ___ Do You Yahoo!? -- Une adresse @yahoo.fr gratuite et en français ! Yahoo! Mail : http://fr.mail.yahoo.com --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] Accessing Container from an EJB?
I'm pretty confused about what exactly you are trying to do, since there is already an instance variable ejbModule and and accessors get/setEjbModule in the Container class. ?? david jencks On Thursday, January 30, 2003, at 01:36 AM, Jeremy Boynes wrote: I am trying to write an EJBTestCase that needs access to information held in the Container (Container.getEjbModule().getModuleData(CATALOG)). I can do this if I add EjbModule as a attribute of Container but was wondering if I should do this or if there was another way? Thanks Jeremy --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] [ jboss-Feature Requests-677512 ] force datasource timeout
Feature Requests item #677512, was opened at 2003-01-30 15:44 You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=376688aid=677512group_id=22866 Category: JBossCX Group: None Status: Open Resolution: None Priority: 5 Submitted By: ryan sonnek (wireframe6464) Assigned to: Nobody/Anonymous (nobody) Summary: force datasource timeout Initial Comment: i frequently have oracle DB errors (Maximum number of cursors exceeded). my connection pool size is limited to 10 connections, but those 10 connections are constantly executed and are not idle long enough to disconnect. without those connecitons closing, cached prepared statements stay alive and cause this error. it'd be very useful to configure the datasource to force a connection to close after so long (as long as it's not in the middle of an executing statement). sorry if this is a duplicate, i couldn't find a similar request anywhere. -- You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=376688aid=677512group_id=22866 --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] Accessing Container from an EJB?
Yes but it is not exposed on the MBean interface, so how do you get a reference to the module unless you already have a real reference to the container? -dain On Thursday, January 30, 2003, at 06:50 AM, David Jencks wrote: I'm pretty confused about what exactly you are trying to do, since there is already an instance variable ejbModule and and accessors get/setEjbModule in the Container class. ?? david jencks On Thursday, January 30, 2003, at 01:36 AM, Jeremy Boynes wrote: I am trying to write an EJBTestCase that needs access to information held in the Container (Container.getEjbModule().getModuleData(CATALOG)). I can do this if I add EjbModule as a attribute of Container but was wondering if I should do this or if there was another way? Thanks Jeremy --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
RE: [JBoss-dev] Accessing Container from an EJB?
David Jencks wrote I'm pretty confused about what exactly you are trying to do, since there is already an instance variable ejbModule and and accessors get/setEjbModule in the Container class. I am trying to unit test changes to JDBCEJBQLCompiler by comparing the SQL generated to known values. Its constructor takes a Catalog, which is the metadata about the abstract schema in this deployment and is stored in the EjbModule moduleData. Trying to construct one from scratch is a nightmare, so my intention was to deploy the ejb-jar and get the Catalog created during deployment. The problem I had was getting access to the EjbModule from the test case EJB. I know the ObjectName of the Container but the MBeanServer isolates me from the get/setEjbModule as it is not a declared JMX attribute. I was able to solve this by adding if(EjbModule.equals(attribute)) { return getEjbModule(); } to Container.getAttribute(String attribute) to declare it but was wondering if a) there was a better way of getting the EjbModule, or b) another way of getting a direct reference to the Container so I can call getEjbModule(). And also, whether it was OK to declare this attribute. Thanks Jeremy --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] Accessing Container from an EJB?
Why not? I see no reason why a client can't look up the EJB container directly using an MBean and get some information. I can see why this would be a bad idea, but we shouldn't restrict the access. Anyway this is for some test code. -dain On Thursday, January 30, 2003, at 04:23 AM, julien viet wrote: I don't think EJB can access its container directly. However maybe you could add an interceptor in stack that does nothing but provides you information you need, because they have access to container. Then your EJB could contact interceptor (with static call for instance) Maybe is it possible via JMX also ? julien JB I am trying to write an EJBTestCase that needs access to information held in JB the Container (Container.getEjbModule().getModuleData(CATALOG)). I can do JB this if I add EjbModule as a attribute of Container but was wondering if I JB should do this or if there was another way? JB Thanks JB Jeremy JB --- JB This SF.NET email is sponsored by: JB SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! JB http://www.vasoftware.com JB ___ JB Jboss-development mailing list JB [EMAIL PROTECTED] JB https://lists.sourceforge.net/lists/listinfo/jboss-development -- Best regards, julienmailto:[EMAIL PROTECTED] ___ Do You Yahoo!? -- Une adresse @yahoo.fr gratuite et en français ! Yahoo! Mail : http://fr.mail.yahoo.com --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] [ jboss-Patches-677603 ] Shutdown broken in 3.0.6
Patches item #677603, was opened at 2003-01-30 19:40 You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=376687aid=677603group_id=22866 Category: JBossServer Group: v3.0 Rabbit Hole Status: Open Resolution: None Priority: 5 Submitted By: Ville Skyttä (scop) Assigned to: Nobody/Anonymous (nobody) Summary: Shutdown broken in 3.0.6 Initial Comment: Here's a patch that fixes Shutdown on 3.0.6. When not given a password, a NPE will be thrown in the PasswordAuthenticator. That will be happily caught and no error is signaled. The patch also makes shutdown better so that it will not mask that many unexpected exceptions. Please apply. -- You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=376687aid=677603group_id=22866 --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
RE: [JBoss-dev] Accessing Container from an EJB?
Thanks - I copied the code to get the registry into the test setup and it worked like a charm. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of David Jencks Sent: Thursday, January 30, 2003 9:13 AM To: [EMAIL PROTECTED] Subject: Re: [JBoss-dev] Accessing Container from an EJB? Well, one solution in jboss 4 that doesnt add any more code is: I figure you know the object name for the ejbModule mbean you are writing the test. I just added a jmx method in ServiceMBeanSupport to return the actual object behind an mbean. You can use this (or pre-jboss 4 similar code) to get the actual ejbModule object and call whatever method you want on it. I don't know if this will work with the Container mbean since it is dynamic. david --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] [ jboss-Feature Requests-677614 ] method to remove single Principal from authentication cache
Feature Requests item #677614, was opened at 2003-01-30 12:50 You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=376688aid=677614group_id=22866 Category: JBossSX Group: v3.0 Rabbit Hole Status: Open Resolution: None Priority: 5 Submitted By: David Ward (dward2) Assigned to: Nobody/Anonymous (nobody) Summary: method to remove single Principal from authentication cache Initial Comment: The JaasSecurityManagerService provides many methods in 3.0.6: getPrincipal() registerSecurityDomain() isValid() start() create() doesUserHaveRole() getAuthenticationCachePrincipals() stop() getUserRoles() flushAuthenticationCache() destroy() However, it is lacking in a method to remove a single user from the authentication cache. A method like this: removeAuthenticationCachePrincipal(String username) or removeAuthenticationCachePrincipal(Principal user) would be very helpful. Here is a jboss-user mailing list thread that talks about the problem that is trying to be solved: http://www.mail-archive.com/jboss-user%40lists.sourceforge.net/msg25514.html Thanks muchly, David -- You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=376688aid=677614group_id=22866 --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] Automated JBoss(Branch_3_0) Testsuite Results: 30-January-2003
JBoss daily test results SUMMARY Number of tests run: 1024 Successful tests: 1019 Errors:5 Failures: 0 [time of test: 2003-01-30.15-01 GMT] [java.version: 1.4.1_01] [java.vendor: Sun Microsystems Inc.] [java.vm.version: 1.4.1_01-b01] [java.vm.name: Java HotSpot(TM) Client VM] [java.vm.info: mixed mode] [os.name: Linux] [os.arch: i386] [os.version: 2.4.18-14] See http://users.jboss.org/~starksm/Branch_3_0/2003-01-30.15-01 for details of this test. NOTE: If there are any errors shown above - this mail is only highlighting them - it is NOT indicating that they are being looked at by anyone. It is assumed that whoever makes change(s) to jboss that break the test will be fixing the test or jboss, as appropriate! DETAILS OF ERRORS Suite: UnackedUnitTestCase Test:testUnackedTopic(org.jboss.test.jbossmq.test.UnackedUnitTestCase) Type:error Exception: java.lang.InternalError Message: Test timeout - Suite: LocalWrapperCleanupUnitTestCase Test: testAutoCommitOffInRemoteUserTx(org.jboss.test.jca.test.LocalWrapperCleanupUnitTestCase) Type:error Exception: java.rmi.ServerException Message: RemoteException occurred in server thread; nested exception is: java.rmi.ServerException: EJBException:; nested exception is: javax.ejb.EJBException: Row committed, autocommit still on! - Suite: MissingClassUnitTestCase Test: testDeployServiceWithoutClass(org.jboss.test.jmx.test.MissingClassUnitTestCase) Type:error Exception: org.jboss.deployment.DeploymentException Message: jboss.test:name=missingclasstest is not registered.; - nested throwable: (javax.management.InstanceNotFoundException: jboss.test:name=missingclasstest is not registered.) - Suite: SimpleUnitTestCase Test:testHaParitionName(org.jboss.test.naming.test.SimpleUnitTestCase) Type:error Exception: javax.naming.CommunicationException Message: Receive timed out - Suite: EJBSpecUnitTestCase Test:testMDBRunAs(org.jboss.test.security.test.EJBSpecUnitTestCase) Type:error Exception: java.lang.NullPointerException Message: - --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] [ jboss-Patches-677807 ] Shutdown broken in 3.0.6, shutdown through HTTPS is broken
Patches item #677807, was opened at 2003-01-30 17:22 You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=376687aid=677807group_id=22866 Category: JBossServer Group: v3.0 Rabbit Hole Status: Open Resolution: None Priority: 5 Submitted By: Vladyslav Kosulin (kosulin) Assigned to: Nobody/Anonymous (nobody) Summary: Shutdown broken in 3.0.6, shutdown through HTTPS is broken Initial Comment: 3 fixes: 1. In 3.0.6 org.jboss.Shutdown is broken: PasswordAuthenticator(String username, String password) throws NPE if password is not given. See also patch # 677603. The patch prevents this. 2. It is impossible to shutdown with org.jboss.Shutdown if HTTP is disabled. To fix, I propose to use additional parameter: java org.jboss.Shutdown [host [port [protocol]]] [-u username] [-p password] [-c shutdown_command] Protocol is located after port to prevent existing scripts from break. 3. Masking most exceptions makes it hard to find why the shutdown is not happening. With patch all exceptions are being printed to System.err with printStackTrace(). Vlad Kosulin -- You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=376687aid=677807group_id=22866 --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
RE: [JBoss-dev] Accessing Container from an EJB?
OK, it worked like a charm in the HEAD branch. In 3.2 I get a NoSuchMethodException when calling get(name) on the registry: Caused by: java.lang.NoSuchMethodException: Unable to locate method for: get(,javax.management.ObjectName) at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispat cher.java:288) at org.jboss.mx.interceptor.ObjectReferenceInterceptor.invoke(ObjectReferenceIn terceptor.java:64) at org.jboss.mx.interceptor.MBeanAttributeInterceptor.invoke(MBeanAttributeInte rceptor.java:50) at org.jboss.mx.interceptor.PersistenceInterceptor.invoke(PersistenceIntercepto r.java:91) at org.jboss.mx.server.MBeanInvoker.invoke(MBeanInvoker.java:79) at javax.management.modelmbean.RequiredModelMBean.invoke(RequiredModelMBean.jav a:141) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549) at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174) Any ideas? Thanks Jeremy -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Jeremy Boynes Sent: Thursday, January 30, 2003 9:43 AM To: [EMAIL PROTECTED] Subject: RE: [JBoss-dev] Accessing Container from an EJB? Thanks - I copied the code to get the registry into the test setup and it worked like a charm. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of David Jencks Sent: Thursday, January 30, 2003 9:13 AM To: [EMAIL PROTECTED] Subject: Re: [JBoss-dev] Accessing Container from an EJB? Well, one solution in jboss 4 that doesnt add any more code is: I figure you know the object name for the ejbModule mbean you are writing the test. I just added a jmx method in ServiceMBeanSupport to return the actual object behind an mbean. You can use this (or pre-jboss 4 similar code) to get the actual ejbModule object and call whatever method you want on it. I don't know if this will work with the Container mbean since it is dynamic. david --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
Re: [JBoss-dev] Accessing Container from an EJB?
Someone left the get method out of the ModelMBeanInfo for the registry. I'm checking for problems, then I'll add it to 3.2. I'm less enthusiastic about 3.0. david jencks On Thursday, January 30, 2003, at 06:27 PM, Jeremy Boynes wrote: OK, it worked like a charm in the HEAD branch. In 3.2 I get a NoSuchMethodException when calling get(name) on the registry: Caused by: java.lang.NoSuchMethodException: Unable to locate method for: get(,javax.management.ObjectName) at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanD ispat cher.java:288) at org.jboss.mx.interceptor.ObjectReferenceInterceptor.invoke(ObjectRefere nceIn terceptor.java:64) at org.jboss.mx.interceptor.MBeanAttributeInterceptor.invoke(MBeanAttribut eInte rceptor.java:50) at org.jboss.mx.interceptor.PersistenceInterceptor.invoke(PersistenceInter cepto r.java:91) at org.jboss.mx.server.MBeanInvoker.invoke(MBeanInvoker.java:79) at javax.management.modelmbean.RequiredModelMBean.invoke(RequiredModelMBea n.jav a:141) at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:549) at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174) Any ideas? Thanks Jeremy -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Jeremy Boynes Sent: Thursday, January 30, 2003 9:43 AM To: [EMAIL PROTECTED] Subject: RE: [JBoss-dev] Accessing Container from an EJB? Thanks - I copied the code to get the registry into the test setup and it worked like a charm. -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of David Jencks Sent: Thursday, January 30, 2003 9:13 AM To: [EMAIL PROTECTED] Subject: Re: [JBoss-dev] Accessing Container from an EJB? Well, one solution in jboss 4 that doesnt add any more code is: I figure you know the object name for the ejbModule mbean you are writing the test. I just added a jmx method in ServiceMBeanSupport to return the actual object behind an mbean. You can use this (or pre-jboss 4 similar code) to get the actual ejbModule object and call whatever method you want on it. I don't know if this will work with the Container mbean since it is dynamic. david --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
RE: [JBoss-dev] Accessing Container from an EJB?
OK. 3.2 is fine for me. Thanks Jeremy -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of David Jencks Sent: Thursday, January 30, 2003 4:27 PM To: [EMAIL PROTECTED] Subject: Re: [JBoss-dev] Accessing Container from an EJB? Someone left the get method out of the ModelMBeanInfo for the registry. I'm checking for problems, then I'll add it to 3.2. I'm less enthusiastic about 3.0. david jencks --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development
[JBoss-dev] [ jboss-Patches-677882 ] fixed run.sh to include jar files for JBoss/Tomcat combo
Patches item #677882, was opened at 2003-01-30 16:58 You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=376687aid=677882group_id=22866 Category: None Group: v3.0 Rabbit Hole Status: Open Resolution: None Priority: 5 Submitted By: Dominik Kacprzak (dominikos) Assigned to: Nobody/Anonymous (nobody) Summary: fixed run.sh to include jar files for JBoss/Tomcat combo Initial Comment: Apparently, the current run.sh does not include jar files required by Tomcat code. I have fixed it by adding additional classpath variable, CATALINA_CLASSPATH, which is set only if tomcat- directory exists in the distribution. The fixed script was tested on RH Linux 8.0 with jboss-3.0.4_tomcat-4.1.12.zip and jboss-3.0.6_tomcat-4.1.18.zip. - Dominik -- You can respond by visiting: https://sourceforge.net/tracker/?func=detailatid=376687aid=677882group_id=22866 --- This SF.NET email is sponsored by: SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See! http://www.vasoftware.com ___ Jboss-development mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/jboss-development