You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@phoenix.apache.org by st...@apache.org on 2023/09/22 09:04:00 UTC

[phoenix-omid] branch master updated (7d3cf3e8 -> b78e9a95)

This is an automated email from the ASF dual-hosted git repository.

stoty pushed a change to branch master
in repository https://gitbox.apache.org/repos/asf/phoenix-omid.git


    from 7d3cf3e8 OMID-247 Change TSO default port to be outside the ephemeral range
     new 3c78aaea OMID-237 TestHBaseTransactionClient.testReadCommitTimestampFromCommitTable fails
     new b78e9a95 OMID-248 Transactional Phoenix tests fail on Java 17 in getDefaultNetworkInterface

The 2 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:
 common/src/main/java/org/apache/omid/NetworkUtils.java         | 10 ++++++++--
 .../apache/omid/transaction/TestHBaseTransactionClient.java    |  2 +-
 2 files changed, 9 insertions(+), 3 deletions(-)


[phoenix-omid] 02/02: OMID-248 Transactional Phoenix tests fail on Java 17 in getDefaultNetworkInterface

Posted by st...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

stoty pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/phoenix-omid.git

commit b78e9a95f80188ddf57172f39caa57411ddc0a38
Author: Istvan Toth <st...@apache.org>
AuthorDate: Thu Sep 21 07:30:01 2023 +0200

    OMID-248 Transactional Phoenix tests fail on Java 17 in getDefaultNetworkInterface
---
 common/src/main/java/org/apache/omid/NetworkUtils.java | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/common/src/main/java/org/apache/omid/NetworkUtils.java b/common/src/main/java/org/apache/omid/NetworkUtils.java
index c78f7ea6..e29fdb03 100644
--- a/common/src/main/java/org/apache/omid/NetworkUtils.java
+++ b/common/src/main/java/org/apache/omid/NetworkUtils.java
@@ -29,13 +29,19 @@ public class NetworkUtils {
 
     private static final Logger LOG = LoggerFactory.getLogger(NetworkUtils.class);
 
+    //FIXME Popular distros haven't called their network interfaces ethX for a long time
     private static final String LINUX_TSO_NET_IFACE_PREFIX = "eth";
+    //Modern Linux typically uses an en prefix
     private static final String MAC_TSO_NET_IFACE_PREFIX = "en";
 
+    // FIXME This seems to be only used for determining the host and port when registering TSO
+    // to ZK for HA.
+    // We should get the TSO IP from the ZK TCP connection on demand, and not worry about the
+    // default network interface at all
     public static String getDefaultNetworkInterface() {
 
         try (DatagramSocket s=new DatagramSocket()) {
-            s.connect(InetAddress.getByAddress(new byte[]{1,1,1,1}), 0);
+            s.connect(InetAddress.getByAddress(new byte[]{1,1,1,1}), 53);
             return NetworkInterface.getByInetAddress(s.getLocalAddress()).getName();
         } catch (Exception e) {
             //fall through
@@ -49,7 +55,7 @@ public class NetworkUtils {
                 NetworkInterface nextElement = networkInterfaces.nextElement();
                 String name = nextElement.getDisplayName();
                 LOG.info("Iterating over network interfaces, found '{}'", name);
-                boolean hasInet = Collections.list(nextElement.getInetAddresses()).size() > 1; // Checking that inet exists, to avoid taking iBridge
+                boolean hasInet = Collections.list(nextElement.getInetAddresses()).size() > 0; // Checking that inet exists, to avoid taking iBridge
                 if (hasInet && fallBackName == null) {
                     fallBackName = name;
                 }


[phoenix-omid] 01/02: OMID-237 TestHBaseTransactionClient.testReadCommitTimestampFromCommitTable fails

Posted by st...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

stoty pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/phoenix-omid.git

commit 3c78aaea0e1d1f1099c0f0e2707138c034ffec06
Author: Istvan Toth <st...@apache.org>
AuthorDate: Wed Sep 20 16:42:19 2023 +0200

    OMID-237 TestHBaseTransactionClient.testReadCommitTimestampFromCommitTable fails
---
 .../java/org/apache/omid/transaction/TestHBaseTransactionClient.java    | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hbase-client/src/test/java/org/apache/omid/transaction/TestHBaseTransactionClient.java b/hbase-client/src/test/java/org/apache/omid/transaction/TestHBaseTransactionClient.java
index 7430a1f3..ef5a24d8 100644
--- a/hbase-client/src/test/java/org/apache/omid/transaction/TestHBaseTransactionClient.java
+++ b/hbase-client/src/test/java/org/apache/omid/transaction/TestHBaseTransactionClient.java
@@ -131,7 +131,7 @@ public class TestHBaseTransactionClient extends OmidTestBase {
     public void testReadCommitTimestampFromCommitTable(ITestContext context) throws Exception {
 
         //connection = ConnectionFactory.createConnection(hbaseConf);
-        final long NON_EXISTING_CELL_TS = 1000L;
+        final long NON_EXISTING_CELL_TS = 1000000L;
 
         PostCommitActions syncPostCommitter =
                 spy(new HBaseSyncPostCommitter(new NullMetricsProvider(), getCommitTable(context).getClient(), connection));