Hi there.
I have a problem when using the dynamic classloading feature of RMI for a non RMI-Class.
Note:
- The "WebService" which provides the class is up and running on the port 8083.
- I use jboss-4.2.2
The first problem:
When the class X to be loaded dynamically is sent as instance to the client, the codebase
is not set correctly to the WebServer running on port 8083. Instead the codebase comprises
loads of "file:/...."-URLs. Therefore when the class X has to be loaded the
client does not try to dynamically load the class from the server running on port 8083.
I patched the class MarshalInputStream so that the codebase is set correctly on the client
side. After having applied the patch the client now tries to load the class from the
server...
now the second problem:
I sniffed the port 8083. The following HTTP get call is performed:
GET /org/foo/bar/X.class HTTP/1.1
User-Agent: Java/1.6.0_05
Host: delgado:8083
Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2
Connection: keep-alive
Which is answered by the server with:
HTTP/1.0 404 Not Found
Content-Type: text/html
I debugged the WebServer code and found out that classloader returned by the call
"Thread.currentThread().getContextClassLoader();" is not able to load my class
X.
Any hints to my problem are appreciated.
cheers,
marco
View the original post :
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4161898#...
Reply to the post :
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&a...