Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Build Java RMI applications with Eclipse (How to do rmic)

Tags:

java

eclipse

rmi

I'm trying to develop a Java RMI application and found out that it's not straight forward to tell eclipse to compile it using rmic.

Are there any available addons (if so which one do you recommend)?

or

what are the ways to accomplish this?

Thanks.

like image 789
Shamal Karunarathne Avatar asked Nov 24 '10 11:11

Shamal Karunarathne


People also ask

How do I run an RMI program in eclipse?

To do this, go to Run → External Tools → External Tools Configurations... from the menu. Create a new Program configuration, which will look like the figure below. Browse File System... to locate your rmiregistry , which is usually in the bin directory of the Java distribution. Save and run this external tool.

What is RMIC in Java?

The rmic compiler generates stub and skeleton class files (JRMP protocol) and stub and tie class files (IIOP protocol) for remote objects. These classes files are generated from compiled Java programming language classes that are remote object implementation classes.

What is the work of RMIC command?

Overrides the location of bootstrap class files. Specifies the path the rmic command uses to look up classes. This option overrides the default or the CLASSPATH environment variable when it is set. Directories are separated by colons or semicolons, depending on your operating system.


2 Answers

As of Java 5 there is no need to use the rmic tool since stubs are now dynamically generated. I'd suggest following an updated tutorial which is more geared towards RMI implementations for Java 5 or greater. Following the RMI Guide for Java 5 should give you a decent start.

like image 200
Sanjay T. Sharma Avatar answered Sep 29 '22 23:09

Sanjay T. Sharma


You have plugins for eclipse for RMI applications like this one: http://www.genady.net/rmi/index.html

Edit: Also, some free plugins like this: http://sourceforge.net/projects/rmi-eclipse/

like image 41
bdhar Avatar answered Sep 30 '22 00:09

bdhar