Skip to Main Content

Java APIs

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to Install JXTA properly?

843790Mar 30 2010 — edited Mar 31 2010
I am trying to build a DrawingPad like P2P application. I've read a lot over the internet and came to a conclusion that I can use JXTA for this purpose. The next step is to install JXTA on my computer.

I went here -> http://download.java.net/jxta/

and downloaded the libraries. I copied them into my C->program files->java->jdk1.6.0_18->bin->lib

But there is absolutely no place I could find which tells me how ensure the installation. I am really confused and don't want to mess with my Java installation.

There are a million places where I could fine THIS link for installing. But It appears to be broken.

I would appreciate if anyone can guide me about how to install JXTA so that I can go ahead with my p2p application.


I tried to execute the following code:
import net.jxta.platform.NetworkManager;
import java.text.MessageFormat;

public class HelloWorld {

public static void main(String args[]) {
NetworkManager manager = null;
try {
manager = new NetworkManager(NetworkManager.ConfigMode.EDGE,
"HelloWorld");
System.out.println("Starting JXTA");
manager.startNetwork();
System.out.println("JXTA Started");
} catch (Exception e) {
e.printStackTrace();
System.exit(-1);
}
System.out.println("Waiting for a rendezvous connection");
boolean connected = manager.waitForRendezvousConnection(12000);
System.out.println(MessageFormat.format("Connected :{0}", connected));
System.out.println("Stopping JXTA");
manager.stopNetwork();
}
}
But it gives me an error. Please help.

Thanks.
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Apr 28 2010
Added on Mar 30 2010
7 comments
465 views