[JBoss JIRA] Updated: (JBAS-3265) Problem with empty classname in classloader
by Dimitris Andreadis (JIRA)
[ http://jira.jboss.com/jira/browse/JBAS-3265?page=all ]
Dimitris Andreadis updated JBAS-3265:
-------------------------------------
Fix Version/s: JBossAS-4.0.6.CR1
(was: JBossAS-4.0.5.CR1)
> Problem with empty classname in classloader
> -------------------------------------------
>
> Key: JBAS-3265
> URL: http://jira.jboss.com/jira/browse/JBAS-3265
> Project: JBoss Application Server
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: JMX
> Affects Versions: JBossAS-4.0.4.GA
> Reporter: Adrian Brock
> Assigned To: Scott M Stark
> Fix For: JBossAS-4.0.6.CR1
>
>
> The RepositoryClassLoader doesn't handle empty classnames correctly.
> It eventually breaks when it tries to do the array name handling here:
> // If this is an array class, use Class.forName to resolve it
> if( name.charAt(0) == '[' )
> {
> result = Class.forName(name, true, this);
> removeFromClassBlackList(name);
> return result;
> }
> 17:04:42,858 ERROR [STDERR] java.lang.StringIndexOutOfBoundsException: String index out of range: 0
> 17:04:42,860 ERROR [STDERR] at java.lang.String.charAt(String.java:444)
> 17:04:42,861 ERROR [STDERR] at org.jboss.mx.loading.RepositoryClassLoader.loadClassLocally(RepositoryClassLoader.java:169)
> 17:04:42,862 ERROR [STDERR] at org.jboss.mx.loading.UnifiedLoaderRepository3.loadClassFromClassLoader(UnifiedLoaderRepository3.java:263)
> 17:04:42,862 ERROR [STDERR] at org.jboss.mx.loading.LoadMgr3.beginLoadTask(LoadMgr3.java:270)
> 17:04:42,864 ERROR [STDERR] at org.jboss.mx.loading.RepositoryClassLoader.loadClassImpl(RepositoryClassLoader.java:475)
> 17:04:42,865 ERROR [STDERR] at org.jboss.mx.loading.RepositoryClassLoader.loadClass(RepositoryClassLoader.java:377)
> 17:04:42,865 ERROR [STDERR] at java.lang.ClassLoader.loadClass(ClassLoader.java:235)
> The classloader should just reject a null or empty ("") classname in loadClass()
> with a meaningful error message.
> I suspect the null is handled by the cache since the cache is a Concurrent HashMap
> which won't accept null as a key.
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
19 years, 10 months
[JBoss JIRA] Updated: (JBAS-3261) Serialization of EJB handles
by Dimitris Andreadis (JIRA)
[ http://jira.jboss.com/jira/browse/JBAS-3261?page=all ]
Dimitris Andreadis updated JBAS-3261:
-------------------------------------
Fix Version/s: JBossAS-4.0.6.CR1
(was: JBossAS-4.0.5.CR1)
> Serialization of EJB handles
> ----------------------------
>
> Key: JBAS-3261
> URL: http://jira.jboss.com/jira/browse/JBAS-3261
> Project: JBoss Application Server
> Issue Type: Bug
> Security Level: Public(Everyone can see)
> Components: EJB2
> Affects Versions: JBossAS-3.2.8.SP1, JBossAS-4.0.4.GA
> Reporter: Lars Kral
> Assigned To: Scott M Stark
> Fix For: JBossAS-4.0.6.CR1
>
> Attachments: test-ejb.jar
>
>
> According to [JBAS-1620], we have to use org.jboss.naming.NamingContextFactory to allow the handle to remember the JNDI environment that was in effect when it was created. But what about handles constructed inside the JBoss server JVM and later serialized into the client JVM? Each JVM may use different properties to access the JNDI - e.g. the "java.naming.provider.url" property, which is not available in the JBoss JVM but is required in a client JVM. Sure, I can add the "java.naming.provider.url" property to the $JBOSS_SERVER_HOME/conf/jndi.properties file, but as far as I know this forces in-VM calls to use RMI.
> Please have a look at the attached testcase (sources are included). The code works in our production environment (v3.2.7) but fails with the latest JBoss releases (4.0.4.GA and 3.2.8.SP1).
> Regards,
> lkral
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira
19 years, 10 months