gaurav singh has posted comments on this change. ( http://gerrit.cloudera.org:8080/22527 )
Change subject: WIP: add ipv6 support for webui/hs2/hs2-http/beeswax ...................................................................... Patch Set 14: (6 comments) http://gerrit.cloudera.org:8080/#/c/22527/14/be/src/util/network-util.cc File be/src/util/network-util.cc: http://gerrit.cloudera.org:8080/#/c/22527/14/be/src/util/network-util.cc@246 PS14, Line 246: ss << "[" << address.hostname << "]:" << dec << address.port; Maybe also check if the hostname already has "[" and "]" ? http://gerrit.cloudera.org:8080/#/c/22527/14/be/src/util/webserver.cc File be/src/util/webserver.cc: http://gerrit.cloudera.org:8080/#/c/22527/14/be/src/util/webserver.cc@415 PS14, Line 415: listening_spec_v6 << "[" << ip << "]:" << http_address_.port; Maybe also check if the hostname already has "[" and "]" ? http://gerrit.cloudera.org:8080/#/c/22527/14/shell/impala_client.py File shell/impala_client.py: http://gerrit.cloudera.org:8080/#/c/22527/14/shell/impala_client.py@562 PS14, Line 562: host = "[%s]" % self.impalad_host if ":" in self.impalad_host else self.impalad_host Check if host is already this format "[::1]" http://gerrit.cloudera.org:8080/#/c/22527/14/shell/impala_shell.py File shell/impala_shell.py: http://gerrit.cloudera.org:8080/#/c/22527/14/shell/impala_shell.py@977 PS14, Line 977: def __parse_host_port(addr): : split_by_colon = addr.split(':') : ipv6addr = len(split_by_colon) > 2 : host_port = None : if ipv6addr: : if addr[0] == "[": : parts = addr.split("]") : host_port = [parts[0][1:]] : has_port = parts[1] != "" : if has_port: : if parts[1][0] != ":": return None : host_port.append(parts[1][1:]) : else: : host_port = [addr] : else: : host_port = [val for val in split_by_colon if val.strip()] : # validate the connection string. : if ':' in addr and len(host_port) != 2: return None : return host_port Add one line description (with example) for the function, what its trying to do. http://gerrit.cloudera.org:8080/#/c/22527/14/tests/common/impala_connection.py File tests/common/impala_connection.py: http://gerrit.cloudera.org:8080/#/c/22527/14/tests/common/impala_connection.py@600 PS14, Line 600: host, port = split_host_port(self.__host_port) what happens if the input is invalid format and returns None ? http://gerrit.cloudera.org:8080/#/c/22527/14/tests/common/network.py File tests/common/network.py: http://gerrit.cloudera.org:8080/#/c/22527/14/tests/common/network.py@37 PS14, Line 37: def split_host_port(host_port): Add function description. This seems to be similar to the function __parse_host_port() in impala_shell.py -- To view, visit http://gerrit.cloudera.org:8080/22527 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I51ac66c568cc9bb06f4a3915db07a53c100109b6 Gerrit-Change-Number: 22527 Gerrit-PatchSet: 14 Gerrit-Owner: Csaba Ringhofer <csringho...@cloudera.com> Gerrit-Reviewer: Abhishek Rawat <ara...@cloudera.com> Gerrit-Reviewer: Impala Public Jenkins <impala-public-jenk...@cloudera.com> Gerrit-Reviewer: Kurt Deschler <kdesc...@cloudera.com> Gerrit-Reviewer: Michael Smith <michael.sm...@cloudera.com> Gerrit-Reviewer: gaurav singh <gsi...@cloudera.com> Gerrit-Comment-Date: Thu, 13 Mar 2025 17:17:04 +0000 Gerrit-HasComments: Yes