Skip to main content

[JXSE 2.7 RC1] Failed to make PSE Membership credential 'ready for join'

7 replies [Last post]
hades82
Offline
Joined: 2008-11-20
Points: 0

Well,
I'm desperated, please, could someone tell me what I doing wrong?
As I say in the subject, my problem is that error. The app I try to execute is quite simple:
nmg = new NetworkManager(NetworkManager.ConfigMode.EDGE, "man1");
ncfg = nmg.getConfigurator();
ncfg.setHttp2Enabled(false);
nmg.startNetwork();
Thread.sleep(7000);
nmg.stopNetwork();
with its try/catch blocks and so on. I compile it and 0 errors, but when executing:
Clearing SRDI for null
16-feb-2011 15:55:04 net.jxta.impl.cm.InMemorySrdi clearSrdi
INFO: Clearing SRDIs for urn:jxta:jxta-WorldGroup[0,4660784] / [32124414]
16-feb-2011 15:55:04 net.jxta.logging.Logging logCheckedInfo
INFO: Line 679 net.jxta.impl.peergroup.GenericPeerGroup.loadModule()
Loaded privileged module : PSE Membership Service (net.jxta.impl.membership.pse.PSEMembershipService)
16-feb-2011 15:55:04 net.jxta.logging.Logging logCheckedInfo
INFO: Line 331 net.jxta.impl.membership.pse.PSEMembershipService.startApp()
PSE Membmership Service started.
16-feb-2011 15:55:04 net.jxta.impl.peergroup.StdPeerGroup initFirst
GRAVE: Failed to make PSE membership credential 'ready for join'
16-feb-2011 15:55:04 net.jxta.peergroup.WorldPeerGroupFactory newWorldPeerGroup
GRAVE: World Peer Group could not be instantiated.

net.jxta.exception.PeerGroupException: Failed to login to this group: null. Error=0
at net.jxta.impl.peergroup.StdPeerGroup.initFirst(StdPeerGroup.java:704)
at net.jxta.impl.peergroup.Platform.initFirst(Platform.java:214)
at net.jxta.impl.peergroup.GenericPeerGroup.init(GenericPeerGroup.java:907)
at net.jxta.peergroup.WorldPeerGroupFactory.newWorldPeerGroup(WorldPeerGroupFactory.java:312)
at net.jxta.peergroup.WorldPeerGroupFactory.<init>(WorldPeerGroupFactory.java:182)
at net.jxta.peergroup.NetPeerGroupFactory.<init>(NetPeerGroupFactory.java:203)
at net.jxta.platform.NetworkManager.startNetwork(NetworkManager.java:408)
at time.Time.main(Time.java:18)
net.jxta.exception.PeerGroupException: World Peer Group could not be instantiated.
at net.jxta.peergroup.WorldPeerGroupFactory.newWorldPeerGroup(WorldPeerGroupFactory.java:337)
at net.jxta.peergroup.WorldPeerGroupFactory.<init>(WorldPeerGroupFactory.java:182)
at net.jxta.peergroup.NetPeerGroupFactory.<init>(NetPeerGroupFactory.java:203)
at net.jxta.platform.NetworkManager.startNetwork(NetworkManager.java:408)
at time.Time.main(Time.java:18)
Caused by: net.jxta.exception.PeerGroupException: Failed to login to this group: null. Error=0
at net.jxta.impl.peergroup.StdPeerGroup.initFirst(StdPeerGroup.java:704)
at net.jxta.impl.peergroup.Platform.initFirst(Platform.java:214)
at net.jxta.impl.peergroup.GenericPeerGroup.init(GenericPeerGroup.java:907)
at net.jxta.peergroup.WorldPeerGroupFactory.newWorldPeerGroup(WorldPeerGroupFactory.java:312)
... 4 more

The code can't be easier, so I don't know where is the error. Help me please
Thank you very much. Best regards.

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
hades82
Offline
Joined: 2008-11-20
Points: 0

I keep on trying...
If I put jxta.jar (from JXSE 2.5 release) instead jxse-2.7-RC1.jar, it works fine too.
Any idea??

hades82
Offline
Joined: 2008-11-20
Points: 0

Ok, forget all I said before.
The problem has nothing to do with that. First of all, the code I was executing was different, and I've found the exact line that isn't working.
The code (the true code) is:
nc.setName(name);
nc.setPassword(password);
nc.save();
nmg.startNetwork();
If I comment the nc.save() line it works fine. Do you know if is there any problem with that method in JXSE 2.7RC1? or what's the way to avoid this problem?
Thank you very much!!

hades82
Offline
Joined: 2008-11-20
Points: 0

for more information, the classpath I use includes the following jar files:
bouncycastle/bcprov-jdk15-145.jar
h2/h2-1.1.127.jar
jetty/javax.servlet.jar
jetty/org.mortbay.jetty.jar
netty/netty-3.1.5.GA.jar
derby/derby-10.5.1.1.jar
felix/felix.jar
junit/junit-4.4.jar
jmock-2.5.1/*.jar
jxse-2.7-RC1
Must I include another one, or remove any?
Thanks again.

hades82
Offline
Joined: 2008-11-20
Points: 0

edited

altmann
Offline
Joined: 2011-02-16
Points: 0

I have the same problem. I'm using JXTA-RC2.7 from http://jxse.kenai.com/Downloads/Downloads.html.
It kicks me everytime I try to use NetworkManager.startNetwork();
My code can be downloaded here: http://maltmann.wi-kassel.de/tmp/JXTA-RC27Prob.zip

It seem's that the World Peer Group and NetPeer Group isn't correctly set. How can I deliver NetPeerGroup to the Network Manager. I thought this would be done by:
NetworkManager nw_mgr = new NetworkManager(NetworkManager.ConfigMode.RENDEZVOUS_RELAY, NetPeerGroupName, new File(jxtaHome).toURI());
In JXTA 2.5 I got the NetPeerGroup with:
NetPeerGroupFactory factory;
try {
factory = new NetPeerGroupFactory(
(ConfigParams)configurator.getPlatformConfig(),
new File(jxtaHome).toURI(),
IDFactory.fromURI(new URI(NetPeerGroupID)),
NetPeerGroupName,
(XMLElement) StructuredDocumentFactory.newStructuredDocument(MimeMediaType.XMLUTF8,
"desc", NetPeerGroupName)
);
}
catch(URISyntaxException e) {
throw new Exception(e.getMessage());
}

netPeerGroup = factory.getInterface();

In 2.7 I would do:

NetPeerGroupFactory factory;
try {
factory = new NetPeerGroupFactory(
(ConfigParams)configurator.getPlatformConfig(),
new File(jxtaHome).toURI());
}
catch(URISyntaxException e) {
throw new Exception(e.getMessage());
}

netPeerGroup = factory.getNetPeerGroup();
But then, how does the Manager work?

hades82
Offline
Joined: 2008-11-20
Points: 0

I think there's something wrong with this release. I will try to avoid those methods that make exceptions appears. It will be harder but there's nothing we can do.
Thank you for your answer (I thought I was the only man with this problem). If you find something interesting please reply, I'll do the same.
bye!!

deco.af
Offline
Joined: 2011-05-05
Points: 0

I've just got the same error when trying to create a custom group and cleaning the jxtacache has solved my problem.