You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by dk...@apache.org on 2018/07/17 15:24:06 UTC
[cxf] branch 3.2.x-fixes updated (011ca19 -> 4c4d930)
This is an automated email from the ASF dual-hosted git repository.
dkulp pushed a change to branch 3.2.x-fixes
in repository https://gitbox.apache.org/repos/asf/cxf.git.
from 011ca19 Re-enabling fixed test
new 881c469 use latest releases of build-utils and xjc-utils, currently there is no need to have snapshot version
new 91724bb [CXF-7796] Add ability to set the network interface for UDPConduit
new 4c4d930 Recording .gitmergeinfo Changes
The 3 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails. The revisions
listed as "add" were already present in the repository and have only
been added to this reference.
Summary of changes:
.gitmergeinfo | 2 ++
pom.xml | 4 ++--
.../org/apache/cxf/transport/udp/UDPConduit.java | 25 ++++++++++++++++++----
3 files changed, 25 insertions(+), 6 deletions(-)
[cxf] 02/03: [CXF-7796] Add ability to set the network interface
for UDPConduit
Posted by dk...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
dkulp pushed a commit to branch 3.2.x-fixes
in repository https://gitbox.apache.org/repos/asf/cxf.git
commit 91724bb4067ff5b2b9ba9f666777d401c0330c8a
Author: Daniel Kulp <dk...@apache.org>
AuthorDate: Tue Jul 17 11:12:32 2018 -0400
[CXF-7796] Add ability to set the network interface for UDPConduit
(cherry picked from commit 11c74955265a058f1f81920915b393cd97572c74)
---
.../org/apache/cxf/transport/udp/UDPConduit.java | 25 ++++++++++++++++++----
1 file changed, 21 insertions(+), 4 deletions(-)
diff --git a/rt/transports/udp/src/main/java/org/apache/cxf/transport/udp/UDPConduit.java b/rt/transports/udp/src/main/java/org/apache/cxf/transport/udp/UDPConduit.java
index 866276c..8a2edc4 100644
--- a/rt/transports/udp/src/main/java/org/apache/cxf/transport/udp/UDPConduit.java
+++ b/rt/transports/udp/src/main/java/org/apache/cxf/transport/udp/UDPConduit.java
@@ -32,8 +32,9 @@ import java.net.NetworkInterface;
import java.net.URI;
import java.util.ArrayList;
import java.util.Collection;
-import java.util.Enumeration;
+import java.util.Collections;
import java.util.HashMap;
+import java.util.List;
import java.util.Map;
import java.util.Queue;
import java.util.concurrent.ArrayBlockingQueue;
@@ -61,6 +62,12 @@ import org.apache.mina.transport.socket.nio.NioDatagramConnector;
*
*/
public class UDPConduit extends AbstractConduit {
+ /**
+ * For broadcast/multicast, the specific network interface to use. This can either be
+ * a specific java.net.NetworkInterface or a string for NetworkInterface.getByName(String name)
+ */
+ public static final String NETWORK_INTERFACE = UDPConduit.class.getName() + ".NETWORK_INTERFACE";
+
private static final String CXF_MESSAGE_ATTR = "CXFMessage";
private static final String MULTI_RESPONSE_TIMEOUT = "udp.multi.response.timeout";
private static final String HOST_PORT = UDPConduit.class + ".host:port";
@@ -244,14 +251,24 @@ public class UDPConduit extends AbstractConduit {
socket.setReceiveBufferSize(64 * 1024);
socket.setBroadcast(true);
socket.setReuseAddress(true);
+ Object netIntFromMsg = message.getContextualProperty(NETWORK_INTERFACE);
+ NetworkInterface netInf = null;
+ if (netIntFromMsg instanceof String) {
+ netInf = NetworkInterface.getByName((String)netIntFromMsg);
+ } else if (netIntFromMsg instanceof NetworkInterface) {
+ netInf = (NetworkInterface)netIntFromMsg;
+ }
if (multicast != null) {
((MulticastSocket)socket).setLoopbackMode(false);
+ if (netInf != null) {
+ ((MulticastSocket)socket).setNetworkInterface(netInf);
+ }
}
if (multicast == null) {
- Enumeration<NetworkInterface> interfaces = NetworkInterface.getNetworkInterfaces();
- while (interfaces.hasMoreElements()) {
- NetworkInterface networkInterface = interfaces.nextElement();
+ List<NetworkInterface> interfaces = netInf == null
+ ? Collections.list(NetworkInterface.getNetworkInterfaces()) : Collections.singletonList(netInf);
+ for (NetworkInterface networkInterface : interfaces) {
if (!networkInterface.isUp() || networkInterface.isLoopback()) {
continue;
}
[cxf] 03/03: Recording .gitmergeinfo Changes
Posted by dk...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
dkulp pushed a commit to branch 3.2.x-fixes
in repository https://gitbox.apache.org/repos/asf/cxf.git
commit 4c4d9306ded488e769437e201bce6c6607c7eebf
Author: Daniel Kulp <dk...@apache.org>
AuthorDate: Tue Jul 17 11:24:02 2018 -0400
Recording .gitmergeinfo Changes
---
.gitmergeinfo | 2 ++
1 file changed, 2 insertions(+)
diff --git a/.gitmergeinfo b/.gitmergeinfo
index a69bf4c..78639d0 100644
--- a/.gitmergeinfo
+++ b/.gitmergeinfo
@@ -1,4 +1,6 @@
origin/master
B bb098089d18825ddc850fa82f4acee45e2b6ee7a
B da5b01b32a59867b48e2b35a9281b3625f58d514
+B e9261069513b1947e16bf485182c328c07160e1c
+B fc656dc1311963f5fc833856984b36b7ccd26042
M 0b920d7275800e651b2c48c982b1977249516ddf
[cxf] 01/03: use latest releases of build-utils and xjc-utils,
currently there is no need to have snapshot version
Posted by dk...@apache.org.
This is an automated email from the ASF dual-hosted git repository.
dkulp pushed a commit to branch 3.2.x-fixes
in repository https://gitbox.apache.org/repos/asf/cxf.git
commit 881c469e973814bea96d32a6cc94aea7975681d7
Author: Dennis Kieselhorst <ma...@dekies.de>
AuthorDate: Wed Jul 11 09:39:47 2018 +0200
use latest releases of build-utils and xjc-utils, currently there is no need to have snapshot version
(cherry picked from commit 55b054d7582a9448fdba7c01393ff20c31fb0564)
---
pom.xml | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/pom.xml b/pom.xml
index 02c0e93..01d97d5 100644
--- a/pom.xml
+++ b/pom.xml
@@ -40,8 +40,8 @@
</issueManagement>
<properties>
<cxf.compiler.fork>false</cxf.compiler.fork>
- <cxf.build-utils.version>3.4.2-SNAPSHOT</cxf.build-utils.version>
- <cxf.xjc-utils.version>3.2.3-SNAPSHOT</cxf.xjc-utils.version>
+ <cxf.build-utils.version>3.4.1</cxf.build-utils.version>
+ <cxf.xjc-utils.version>3.2.2</cxf.xjc-utils.version>
<cxf.jdk.version>1.8</cxf.jdk.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<site.deploy.url>scp://people.apache.org/www/cxf.apache.org/maven-site</site.deploy.url>