Re: WSDiscoveryClient multicast network interface selection

2018-08-06 Thread Jonas
Your patch is working for me. Here is how I tested it:

Bus bus = BusFactory.getThreadDefaultBus();
bus.setProperty(UDPConduit.NETWORK_INTERFACE,
NetworkInterface.getByInetAddress(InetAddress.getByName("192.168.23.42")));

WSDiscoveryClient client = new WSDiscoveryClient(bus);
client.setVersion10();
List references = client.probe(new
QName("http://www.onvif.org/ver10/network/wsdl;, "NetworkVideoTransmitter",
"net"));
client.close();

I verified this with different network interfaces. Thanks a lot.

Jonas



--
Sent from: http://cxf.547215.n5.nabble.com/cxf-user-f547216.html


WSDiscoveryClient multicast network interface selection

2018-07-17 Thread Jonas
Hi,

I'm trying to discover ONVIF video devices with the WSDiscoveryClient. I can
see the probe message in Wireshark. However, the message is sent on the
wrong network interface and I didn't find a way to explicitly set an
interface in the client. I found the "NETWORK_INTERFACE" property key in the
UDPDestination class, but I don't know how to use it.
Is it possible to explicitly select the network interface for WS-Discovery
messages? If so, how?

Here is a short snippet of the code:



Best regards,
Jonas



--
Sent from: http://cxf.547215.n5.nabble.com/cxf-user-f547216.html


Re: WSDiscoveryClient multicast network interface selection

2018-07-17 Thread Jonas
Looks like the list didn't like the raw-tag for the code. Here is the
snippet:

WSDiscoveryClient client = new WSDiscoveryClient();
client.setVersion10();
List references = client.probe(new
QName("http://www.onvif.org/ver10/network/wsdl;,
"NetworkVideoTransmitter"));
client.close();

However, the code doesn't really show the problem. The problem is what's not
there. So UDPConduit is responsible in my case. Since I can't see any call
to "setNetworkInterface" in that class, can I assume that it's not possible
to select the interface for WSDiscoveryClient?

Jonas



--
Sent from: http://cxf.547215.n5.nabble.com/cxf-user-f547216.html


Re: WSDiscoveryClient multicast network interface selection

2018-07-18 Thread Jonas
Thanks. I guess I'm looking for an alternative for now. I guess I could
somehow convince my OS (or Java) to use the correct interface, but in the
end it still fails if I want to discover devices on multiple interfaces.

Jonas



--
Sent from: http://cxf.547215.n5.nabble.com/cxf-user-f547216.html