Archived

This forum has been archived. Please start a new discussion on GitHub.

IceStorm problem

Hi,

I've got a problem getting a simple IceStorm example to run - btw, I'm a newbie in connection with Ice. My Slice definition looks like as follows:

#ifndef NOTIFICATION_ICE
#define NOTIFICATION_ICE
module Notification {
interface Monitor {
void test();
};
};
#endif NOTIFICATION_ICE

I implemented a publisher and a subscriber as shown in the specification (Ice-2.1.0.). Subscribing to a specific topic works fine, but when I would like to publish a message, nothing happens. I had a look to the trace, but wasn't able to figure out what the problem really is.

subscribing works fine as the following trace snippet shows
...
[ icebox-IceStorm: Protocol: received request
message type = 0 (request)
compression status = 0 (not compressed; do not compress response, if any)
message size = 93
request id = 3
identity = Monitoring
facet =
operation = subscribe
mode = 0 (normal)
context = ]
[ icebox-IceStorm: Topic: Subscribe: 06804d68-4649-4cce-9214-bb63408c6b27 QoS:
]
[ icebox-IceStorm: Protocol: sending reply
message type = 2 (reply)
compression status = 0 (not compressed; do not compress response, if any)
message size = 25
request id = 3
reply status = 0 (ok) ]
...

publishing doesn't work
...
[ icebox-IceStorm: Protocol: sending validate connection
message type = 3 (validate connection)
compression status = 0 (not compressed; do not compress response, if any)
message size = 14 ]
[ icebox-IceStorm: Protocol: received request
message type = 0 (request)
compression status = 0 (not compressed; do not compress response, if any)
message size = 51
request id = 0 (oneway)
identity = Monitoring/publish
facet =
operation = test
mode = 0 (normal)
context = ]
[ icebox-IceStorm: Subscriber: 06804d68-4649-4cce-9214-bb63408c6b27: publish fai
led: .\Reference.cpp:1103: Ice::NoEndpointException:
no suitable endpoint available for proxy `06804d68-4649-4cce-9214-bb63408c6b27
-o' ]
[ icebox-IceStorm: Protocol: received close connection
message type = 4 (close connection)
compression status = 1 (not compressed; compress response, if any)
message size = 14 ]
...

ok, I see that a NoEndpointException occurs, but what does it really mean? I checked my config files to see if I set everything right - and it seems to be. Any suggestions where I can start for finding my fault? Would be great! Thanks ...

--sepp

Comments

  • mes
    mes California
    Welcome to the forum!

    The exception indicates that your subscriber's object adapter has not defined any endpoints. If you used the createObjectAdapter("MyAdapter") operation, then you must define a configuration property that supplies the endpoints, such as the following:

    MyAdapter.Endpoints=tcp -h thehost -p 9999

    Alternatively, you can use createObjectAdapterWithEndpoints and then specify the endpoints explicitly in your code.

    You can verify that your subscriber's object adapter endpoints are being set properly by running the subscriber with --Ice.Trace.Network=1. Upon startup, you should see trace information describing the initialization of each endpoint.

    Let us know if you're still having trouble.

    Take care,
    - Mark
  • Well, indeed, that was my fault - everything works fine now; I forgot to specify the ports. Thanks a lot!

    --sepp