[
https://issues.apache.org/jira/browse/IMPALA-13729?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17930772#comment-17930772
]
ASF subversion and git services commented on IMPALA-13729:
----------------------------------------------------------
Commit 242095ac8a2f8493d72bb47693ee1e0728b035c8 in impala's branch
refs/heads/master from Xuebin Su
[ https://gitbox.apache.org/repos/asf?p=impala.git;h=242095ac8 ]
IMPALA-13729: Accept error messages not starting with prompt
Previously, error_msg_expected() only accepted error messages starting
with the following error prompt:
```
Query <query_id> failed:\n
```
However, for some tests using the Beeswax protocol, the error prompt may
appear in the middle of the error message instead of at its beginning.
Therefore, this patch adapts error_msg_expected() to accept error
messages not starting with the error prompt.
The error_msg_expected() function is renamed to error_msg_startswith()
to better describe its behavior.
Change-Id: Iac3e68bcc36776f7fd6cc9c838dd8da9c3ecf58b
Reviewed-on: http://gerrit.cloudera.org:8080/22468
Reviewed-by: Daniel Becker <[email protected]>
Tested-by: Impala Public Jenkins <[email protected]>
Reviewed-by: Riza Suminto <[email protected]>
> TestKillQuery.test_same_coordinator fails in error_msg_expected
> ---------------------------------------------------------------
>
> Key: IMPALA-13729
> URL: https://issues.apache.org/jira/browse/IMPALA-13729
> Project: IMPALA
> Issue Type: Bug
> Reporter: Quanlong Huang
> Assignee: Xuebin Su
> Priority: Critical
>
> Saw this failed in a downstream build.
> Stacktrace
> {noformat}
> query_test/test_kill_query.py:38: in test_same_coordinator
> assert_kill_ok(client, query_id_to_kill)
> util/cancel_util.py:65: in __exit__
> self.client.get_query_id(self.handle),
> E assert (error_msg_expected('TException - service has thrown:
> BeeswaxException(message=Query 9941dc9c3c2257bb:0e610b3900000000
> failed:\nInvalid or...1dc9c3c2257bb:0e610b3900000000.\n\n, log_context=,
> handle=QueryHandle(id=, log_context=), errorCode=0, SQLState=HY000)',
> 'Invalid or unknown query handle', '9941dc9c3c2257bb:0e610b3900000000') or
> error_msg_expected('TException - service has thrown:
> BeeswaxException(message=Query 9941dc9c3c2257bb:0e610b3900000000
> failed:\nInvalid or...1dc9c3c2257bb:0e610b3900000000.\n\n, log_context=,
> handle=QueryHandle(id=, log_context=), errorCode=0, SQLState=HY000)',
> 'Cancelled', '9941dc9c3c2257bb:0e610b3900000000'))
> E + where 'TException - service has thrown:
> BeeswaxException(message=Query 9941dc9c3c2257bb:0e610b3900000000
> failed:\nInvalid or...1dc9c3c2257bb:0e610b3900000000.\n\n, log_context=,
> handle=QueryHandle(id=, log_context=), errorCode=0, SQLState=HY000)' =
> str(ImpalaBeeswaxException())
> E + where ImpalaBeeswaxException() = ImpalaBeeswaxException()
> E + where ImpalaBeeswaxException() =
> <tests.util.cancel_util.QueryToKill instance at 0x7ff088362560>.exc
> E + and '9941dc9c3c2257bb:0e610b3900000000' = <bound method
> BeeswaxConnection.get_query_id of
> <tests.common.impala_connection.BeeswaxConnection object at
> 0x7ff087f4fb10>>(<tests.common.impala_connection.OperationHandle object at
> 0x7ff087f4f050>)
> E + where <bound method BeeswaxConnection.get_query_id of
> <tests.common.impala_connection.BeeswaxConnection object at 0x7ff087f4fb10>>
> = <tests.common.impala_connection.BeeswaxConnection object at
> 0x7ff087f4fb10>.get_query_id
> E + where <tests.common.impala_connection.BeeswaxConnection object at
> 0x7ff087f4fb10> = <tests.common.impala_connection.BeeswaxConnection object at
> 0x7ff087f4fb10>
> E + where <tests.common.impala_connection.BeeswaxConnection object
> at 0x7ff087f4fb10> = <tests.util.cancel_util.QueryToKill instance at
> 0x7ff088362560>.client
> E + and <tests.common.impala_connection.OperationHandle object at
> 0x7ff087f4f050> = <tests.common.impala_connection.OperationHandle object at
> 0x7ff087f4f050>
> E + where <tests.common.impala_connection.OperationHandle object at
> 0x7ff087f4f050> = <tests.util.cancel_util.QueryToKill instance at
> 0x7ff088362560>.handle
> E + and 'TException - service has thrown:
> BeeswaxException(message=Query 9941dc9c3c2257bb:0e610b3900000000
> failed:\nInvalid or...1dc9c3c2257bb:0e610b3900000000.\n\n, log_context=,
> handle=QueryHandle(id=, log_context=), errorCode=0, SQLState=HY000)' =
> str(ImpalaBeeswaxException())
> E + where ImpalaBeeswaxException() = ImpalaBeeswaxException()
> E + where ImpalaBeeswaxException() =
> <tests.util.cancel_util.QueryToKill instance at 0x7ff088362560>.exc
> E + and '9941dc9c3c2257bb:0e610b3900000000' = <bound method
> BeeswaxConnection.get_query_id of
> <tests.common.impala_connection.BeeswaxConnection object at
> 0x7ff087f4fb10>>(<tests.common.impala_connection.OperationHandle object at
> 0x7ff087f4f050>)
> E + where <bound method BeeswaxConnection.get_query_id of
> <tests.common.impala_connection.BeeswaxConnection object at 0x7ff087f4fb10>>
> = <tests.common.impala_connection.BeeswaxConnection object at
> 0x7ff087f4fb10>.get_query_id
> E + where <tests.common.impala_connection.BeeswaxConnection object at
> 0x7ff087f4fb10> = <tests.common.impala_connection.BeeswaxConnection object at
> 0x7ff087f4fb10>
> E + where <tests.common.impala_connection.BeeswaxConnection object
> at 0x7ff087f4fb10> = <tests.util.cancel_util.QueryToKill instance at
> 0x7ff088362560>.client
> E + and <tests.common.impala_connection.OperationHandle object at
> 0x7ff087f4f050> = <tests.common.impala_connection.OperationHandle object at
> 0x7ff087f4f050>
> E + where <tests.common.impala_connection.OperationHandle object at
> 0x7ff087f4f050> = <tests.util.cancel_util.QueryToKill instance at
> 0x7ff088362560>.handle{noformat}
> Standard Error
> {noformat}
> SET
> client_identifier=query_test/test_kill_query.py::TestKillQuery::()::test_same_coordinator[protocol:beeswax];
> -- connecting to: localhost:21000
> -- 2025-02-01 22:56:47,787 INFO MainThread: Could not connect to ('::1',
> 21000, 0, 0)
> Traceback (most recent call last):
> File
> "/data/jenkins/workspace/impala-cdw-master-core-ozone/repos/Impala/infra/python/env-gcc10.4.0/lib/python2.7/site-packages/thrift/transport/TSocket.py",
> line 137, in open
> handle.connect(sockaddr)
> File
> "/data/jenkins/workspace/impala-cdw-master-core-ozone/Impala-Toolchain/toolchain-packages-gcc10.4.0/python-2.7.16/lib/python2.7/socket.py",
> line 228, in meth
> return getattr(self._sock,name)(*args)
> error: [Errno 111] Connection refused
> -- connecting to localhost:21050 with impyla
> -- 2025-02-01 22:56:47,788 INFO MainThread: Could not connect to ('::1',
> 21050, 0, 0)
> Traceback (most recent call last):
> File
> "/data/jenkins/workspace/impala-cdw-master-core-ozone/repos/Impala/infra/python/env-gcc10.4.0/lib/python2.7/site-packages/thrift/transport/TSocket.py",
> line 137, in open
> handle.connect(sockaddr)
> File
> "/data/jenkins/workspace/impala-cdw-master-core-ozone/Impala-Toolchain/toolchain-packages-gcc10.4.0/python-2.7.16/lib/python2.7/socket.py",
> line 228, in meth
> return getattr(self._sock,name)(*args)
> error: [Errno 111] Connection refused
> -- 2025-02-01 22:56:47,807 INFO MainThread: Closing active operation
> -- connecting to localhost:28000 with impyla
> -- 2025-02-01 22:56:47,835 INFO MainThread: Closing active operation
> -- connecting to localhost:11050 with impyla
> -- 2025-02-01 22:56:47,837 INFO MainThread: Could not connect to ('::1',
> 11050, 0, 0)
> Traceback (most recent call last):
> File
> "/data/jenkins/workspace/impala-cdw-master-core-ozone/repos/Impala/infra/python/env-gcc10.4.0/lib/python2.7/site-packages/thrift/transport/TSocket.py",
> line 137, in open
> handle.connect(sockaddr)
> File
> "/data/jenkins/workspace/impala-cdw-master-core-ozone/Impala-Toolchain/toolchain-packages-gcc10.4.0/python-2.7.16/lib/python2.7/socket.py",
> line 228, in meth
> return getattr(self._sock,name)(*args)
> error: [Errno 111] Connection refused
> -- 2025-02-01 22:56:47,837 INFO MainThread: Could not connect to
> ('127.0.0.1', 11050)
> Traceback (most recent call last):
> File
> "/data/jenkins/workspace/impala-cdw-master-core-ozone/repos/Impala/infra/python/env-gcc10.4.0/lib/python2.7/site-packages/thrift/transport/TSocket.py",
> line 137, in open
> handle.connect(sockaddr)
> File
> "/data/jenkins/workspace/impala-cdw-master-core-ozone/Impala-Toolchain/toolchain-packages-gcc10.4.0/python-2.7.16/lib/python2.7/socket.py",
> line 228, in meth
> return getattr(self._sock,name)(*args)
> error: [Errno 111] Connection refused
> -- 2025-02-01 22:56:47,837 ERROR MainThread: Could not connect to any of
> [('::1', 11050, 0, 0), ('127.0.0.1', 11050)]
> -- 2025-02-01 22:56:47,837 INFO MainThread: HS2 FENG connection setup
> failed, continuing...: Could not connect to any of [('::1', 11050, 0, 0),
> ('127.0.0.1', 11050)]
> SET
> client_identifier=query_test/test_kill_query.py::TestKillQuery::()::test_same_coordinator[protocol:beeswax];
> -- connecting to: localhost:21000
> -- 2025-02-01 22:56:47,839 INFO MainThread: Could not connect to ('::1',
> 21000, 0, 0)
> Traceback (most recent call last):
> File
> "/data/jenkins/workspace/impala-cdw-master-core-ozone/repos/Impala/infra/python/env-gcc10.4.0/lib/python2.7/site-packages/thrift/transport/TSocket.py",
> line 137, in open
> handle.connect(sockaddr)
> File
> "/data/jenkins/workspace/impala-cdw-master-core-ozone/Impala-Toolchain/toolchain-packages-gcc10.4.0/python-2.7.16/lib/python2.7/socket.py",
> line 228, in meth
> return getattr(self._sock,name)(*args)
> error: [Errno 111] Connection refused
> SET
> client_identifier=query_test/test_kill_query.py::TestKillQuery::()::test_same_coordinator[protocol:beeswax];
> -- connecting to: localhost:21000
> -- 2025-02-01 22:56:47,839 INFO MainThread: Could not connect to ('::1',
> 21000, 0, 0)
> Traceback (most recent call last):
> File
> "/data/jenkins/workspace/impala-cdw-master-core-ozone/repos/Impala/infra/python/env-gcc10.4.0/lib/python2.7/site-packages/thrift/transport/TSocket.py",
> line 137, in open
> handle.connect(sockaddr)
> File
> "/data/jenkins/workspace/impala-cdw-master-core-ozone/Impala-Toolchain/toolchain-packages-gcc10.4.0/python-2.7.16/lib/python2.7/socket.py",
> line 228, in meth
> return getattr(self._sock,name)(*args)
> error: [Errno 111] Connection refused
> -- executing async: localhost:21000
> SELECT sleep(1000);
> -- 2025-02-01 22:56:47,855 INFO MainThread: Started query
> 9941dc9c3c2257bb:0e610b3900000000
> -- 9941dc9c3c2257bb:0e610b3900000000: fetching all rows
> -- executing against localhost:21000
> KILL QUERY '9941dc9c3c2257bb:0e610b3900000000';
> -- 2025-02-01 22:56:47,873 INFO MainThread: Started query
> f840d9f30501a6a3:3a2ccae100000000
> -- closing connection to: localhost:21000{noformat}
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]