hihi Nikola,

where are you placing your JAR files?  are any in TC/commons/lib or
TC/shared/lib?

try placing everything together, just as a test.  put *all* your
classes and JAR files under TC/commons for example and give it a try...
they should be able to see each other if they are at the same
classloading hierarchy level... this is what i suspect your problem is

http://struts.apache.org/userGuide/configuration.html#config_add

hth,
woodchuck


--- Nikola Milutinovic <[EMAIL PROTECTED]> wrote:

> Hi all.
> 
> Me and the team have given up on RMI and went to RPC, but I thought
> I'd 
> make one last educational attempt.
> 
> Is anyone using RMI in TC where TC is acting as a RMI client to a
> remote 
> RMI, general-purpose, server?
> 
> I have seen tons of (rather old) examples of Applet being a RMI
> client 
> and they do not help me one bit.
> 
> To remind the group of my problems, I'll recap. I have a working RMI 
> client and server packages, plus command line test client application
> 
> which uses RMI client lib successfully against the server. When the
> same 
> lib is used in Tomcat from a servlet, it throws ClassCastException.
> 
> Further investigation has shown that the class that Servlet gets from
> 
> RMI subsystem implements the desired interface, to which it is being 
> cast. It also showed that the classloader of the class was RMI 
> ClassLoader, while other classes in the servlet, including servlet 
> itself werefrom TC's ClassLoader. It lead me to believe that *that*
> is 
> the source of the problem. It has occured to me that, since TC web 
> application has several classloaders, bound into a hierarchy, maybe
> RMI 
> classloader should be somehow introduced into it.
> 
> QUESTIONS
> 
> Am I on the right track?
> If yes, how do I bind in RMI ClassLoader into TC's ClassLoader
> hierarchy?
> And, lastly, who should do it - Servlet or RMI client?
> 
> The last question is more a design question, but it could also be a 
> feasibility question, too. Can RMI client detect a classloader it
> should 
> bind into? It could be dome from the Servlet, but I would like to
> have a 
> general purpose Servlet that would be oblivious of underlying 
> implementation.
> 
> I thought that at least JBoss developers would have something to say
> on 
> this question, since, as I recall, JBoss uses or has been using a lot
> of 
> RMI. There was one article or was it JBoss docs, which explained some
> 
> problems of classloading, which were very similar to mine. I don't 
> recall those docs saying anything to solve the problem in TC.
> 
> Nix.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 
> 



                
__________________________________ 
Discover Yahoo! 
Stay in touch with email, IM, photo sharing and more. Check it out! 
http://discover.yahoo.com/stayintouch.html

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to