multiple services in one vm?

Rikard Elofsson <[email protected]>
Newsgroups gmane.comp.java.sun.jini
Message-ID <[email protected]>
Hello

I'm in a bit deep water but I thought i understood that mnultiple JINI
services can be run in the same VM. Said and done i gave it a try.

--------------------------------------------------------------

I first start reggie in a thread of its own via ServiceStarter:

String[] args = { "config/reggie/start-transient-reggie.config" };
ServiceStarter.main(args);

---------------------------------------------------------------

Then I start my server service and export (via JERI) and register it and
use a JoinManager to see that it actually registers. This all works fine
and i get a nice log:

INFO: started Reggie: 85706c25-4a28-43a7-b533-224f4900f3a6, [],
ConstrainableLookupLocator[[jini://192.168.0.12/], [null]]
RemoteLogServer discovered by
net.jini.discovery.LookupDiscoveryManager@15c97e4


------------------------------------------------------------------

Then I try to find my service:

LookupDiscoveryManager mgr = new
LookupDiscoveryManager(LookupDiscovery.ALL_GROUPS, null, null);

When I run this all hell breaks loose in the log. Copying it below (much
longer on my screen) What is my problem?


---------------------------------------------------------------------



2007-jan-17 16:25:05 com.sun.jini.discovery.DiscoveryV2 getInstance
FINAST: returning DiscoveryV2[[], [], [], [], [], []]
2007-jan-17 16:25:05 net.jini.config.AbstractConfiguration getEntryInternal
FIN: net.jini.config.EmptyConfiguration@ba6c13, component
net.jini.discovery.LookupDiscovery, name registrarPreparer: returns
default BasicProxyPreparer[]
2007-jan-17 16:25:05 net.jini.config.AbstractConfiguration getEntryInternal
FIN: net.jini.config.EmptyConfiguration@ba6c13, component
net.jini.discovery.LookupDiscovery, name discoveryConstraints: returns
default null
2007-jan-17 16:25:05 net.jini.config.AbstractConfiguration getEntryInternal
FAILED: net.jini.config.EmptyConfiguration@ba6c13, component
net.jini.discovery.LookupDiscovery, name taskManager: entry not found
2007-jan-17 16:25:05 net.jini.config.AbstractConfiguration getEntryInternal
FIN: net.jini.config.EmptyConfiguration@ba6c13, component
net.jini.discovery.LookupDiscovery, name multicastRequestMax: returns
default 7
2007-jan-17 16:25:05 net.jini.config.AbstractConfiguration getEntryInternal
FIN: net.jini.config.EmptyConfiguration@ba6c13, component
net.jini.discovery.LookupDiscovery, name multicastRequestInterval:
returns default 5 000
2007-jan-17 16:25:05 net.jini.config.AbstractConfiguration getEntryInternal
FIN: net.jini.config.EmptyConfiguration@ba6c13, component
net.jini.discovery.LookupDiscovery, name finalMulticastRequestInterval:
returns default 120 000
2007-jan-17 16:25:05 net.jini.config.AbstractConfiguration getEntryInternal
FAILED: net.jini.config.EmptyConfiguration@ba6c13, component
net.jini.discovery.LookupDiscovery, name multicastRequestHost: entry not
found
2007-jan-17 16:25:05 net.jini.config.AbstractConfiguration getEntryInternal
FAILED: net.jini.config.EmptyConfiguration@ba6c13, component
net.jini.discovery.LookupDiscovery, name multicastInterfaces: entry not
found
2007-jan-17 16:25:05 net.jini.discovery.LookupDiscovery init
KONFIG: LookupDiscovery - multicast network interface(s): [name:lo (MS
TCP Loopback interface) index: 1 addresses:
/127.0.0.1;
, name:eth0 (Broadcom 440x 10/100 Integrated Controller - Miniport för
paketschemaläggning) index: 2 addresses:
/192.168.0.12;
, name:eth1 (Bluetooth-enhet (Personal Area Network) #2) index: 65540
addresses:
]
2007-jan-17 16:25:05 net.jini.config.AbstractConfiguration getEntryInternal
FIN: net.jini.config.EmptyConfiguration@ba6c13, component
net.jini.discovery.LookupDiscovery, name
multicastInterfaceRetryInterval: returns default 300 000
2007-jan-17 16:25:05 net.jini.config.AbstractConfiguration getEntryInternal
FIN: net.jini.config.EmptyConfiguration@ba6c13, component
net.jini.discovery.LookupDiscovery, name multicastAnnouncementInterval:
returns default 120 000
2007-jan-17 16:25:05 net.jini.config.AbstractConfiguration getEntryInternal
FIN: net.jini.config.EmptyConfiguration@ba6c13, component
net.jini.discovery.LookupDiscovery, name unicastDelayRange: returns
default 0
2007-jan-17 16:25:05 net.jini.config.AbstractConfiguration getEntryInternal
FIN: net.jini.config.EmptyConfiguration@ba6c13, component
net.jini.discovery.LookupDiscovery, name
initialMulticastRequestDelayRange: returns default 0
2007-jan-17 16:25:05
net.jini.discovery.LookupDiscovery$AnnouncementListener <init>
HANDLED: network interface is bad or not configured for multicast:
name:eth1 (Bluetooth-enhet (Personal Area Network) #2) index: 65540
addresses:

java.net.SocketException: bad argument for IP_MULTICAST_IF2: No IP
addresses bound to interface
        at java.net.PlainDatagramSocketImpl.socketSetOption(Native Method)
        at
java.net.PlainDatagramSocketImpl.setOption(PlainDatagramSocketImpl.java:299)
        at java.net.MulticastSocket.setNetworkInterface(MulticastSocket.java:502)
        at
net.jini.discovery.LookupDiscovery$AnnouncementListener.<init>(LookupDiscovery.java:1033)
        at net.jini.discovery.LookupDiscovery$10.run(LookupDiscovery.java:3073)
        at java.security.AccessController.doPrivileged(Native Method)
        at net.jini.security.Security$5.run(Security.java:543)
        at java.security.AccessController.doPrivileged(Native Method)
        at net.jini.security.Security.doPrivileged(Security.java:540)
        at
net.jini.discovery.LookupDiscovery.beginDiscovery(LookupDiscovery.java:3071)
        at net.jini.discovery.LookupDiscovery.<init>(LookupDiscovery.java:1928)
        at
net.jini.discovery.LookupDiscoveryManager.beginDiscovery(LookupDiscoveryManager.java:1493)
        at
net.jini.discovery.LookupDiscoveryManager.<init>(LookupDiscoveryManager.java:872)
        at
com.ssb.skillgames.log.RemoteLogHandler.findService(RemoteLogHandler.java:24)
        at com.ssb.skillgames.log.RemoteLogHandler.<init>(RemoteLogHandler.java:18)
        at com.ssb.skillgames.log.Logs2.init(Logs2.java:21)
        at com.ssb.skillgames.Startup.<init>(Startup.java:37)
        at com.ssb.skillgames.Startup.main(Startup.java:67)

--------------------------------------------------------------------------
Getting Started:     http://www.jini.org/wiki/Category:Getting_Started
Community Web Site:  http://jini.org
jini-users Archive:  http://archives.java.sun.com/archives/jini-users.html
Unsubscribing:       email "signoff JINI-USERS"  to [email protected]
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.