aspose file tools*
The moose likes Java in General and the fly likes Accessing classes in other JVM Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Java in General
Bookmark "Accessing classes in other JVM" Watch "Accessing classes in other JVM" New topic
Author

Accessing classes in other JVM

Ajju Chawla
Greenhorn

Joined: Oct 21, 2005
Posts: 21
Hi,

need some help people...
I've an application deployed in tomcat and some java services on the same m/c. Now I want that java service should be able to invoke the classes running in the application deployed in tomcat. Note they both are runnning in different JVM's.

Any suggestions...

Thanks
Ajju
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41885
    
  63
RMI would be one way of doing it. Since you have Tomcat running already, you might also look into web services.
[ October 21, 2005: Message edited by: Ulf Dittmer ]

Ping & DNS - my free Android networking tools app
Ajju Chawla
Greenhorn

Joined: Oct 21, 2005
Posts: 21
Hi Ulf,
thanx for uor reply...I was wondering can i use JNDI to access those classes in the tomcat. The idea is that classes outside tomcat will call the JNDI service of tomcat and than those tomcat classes can be invoked.

what do u think as Iam not sure that tomcat provides such a JNDI service..

Thanks
Ajju
Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 41885
    
  63
JNDI, as its name implies, is a naming and directory service, not a remote access service. You can use it in your app to look up a service that connects to a remote Tomcat, but you still need to implement that service.
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Accessing classes in other JVM