[ 
https://issues.apache.org/jira/browse/IMPALA-14686?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18110039#comment-18110039
 ] 

ASF subversion and git services commented on IMPALA-14686:
----------------------------------------------------------

Commit 1f67ffc620c8e8e4442b19c496821c8b796a0f6d in impala's branch 
refs/heads/master from Joe McDonnell
[ https://gitbox.apache.org/repos/asf?p=impala.git;h=1f67ffc62 ]

IMPALA-14686: Use long polling by default

Long polling avoids extra latency on short queries
by waiting for completion on the server side rather
than sleep on the client side. This has a very large
effect on short queries, as the client may sleep 50ms
when waiting for completion. This is more efficient
than short polling intervals.

This sets the default value of long_polling_time_ms to 250ms.
This allows for relatively quick cancellation for interactive
clients like impala-shell, but it waits enough time to avoid
excessive wait for small queries.

There were a few tests that needed adjustments to work
with long polling:
 - TestAsyncDDLTiming.test_alter_table_recover is checking
   that a certain query waits a specific amount of time.
   The start timestamp was taken after a call that would
   use long polling, so this was throwing off the time.
   This moved the start timestamp to before the long polling.
 - test_admission_control.py's test_kill_statestore_with_queries_running
   and test_kill_coord_with_queries_running were using queries
   that reached the FINISHED state very quickly. With long polling,
   the client never saw them in RUNNING state. This changes the
   query so that it stays in the RUNNING state longer and avoids
   the issue.
 - TestEventSyncFailures's test_hms_event_sync_with_event_processing_disabled
   sees a timing window where the get_log() does not include the
   INJECT_ERROR_LOG. This is a race condition between the transition to
   FINISHED and ClientRequestState setting the coordinator (which includes
   the error log). This changes the test to add a fetch call, which
   avoids the timing window.

Testing:
 - Passed an exhaustive release job

Change-Id: I73c23e735a51b56c94687b18894d01f605287a4b
Reviewed-on: http://gerrit.cloudera.org:8080/24703
Tested-by: Impala Public Jenkins <[email protected]>
Reviewed-by: Michael Smith <[email protected]>


> Enable long polling by default
> ------------------------------
>
>                 Key: IMPALA-14686
>                 URL: https://issues.apache.org/jira/browse/IMPALA-14686
>             Project: IMPALA
>          Issue Type: Improvement
>          Components: Clients, Frontend
>            Reporter: Michael Smith
>            Assignee: Joe McDonnell
>            Priority: Major
>             Fix For: Impala 5.0.0
>
>
> IMPALA-13294 added support for long polling in Impala and impala-shell. This 
> behavior is strictly better than the current behavior, allowing Impala 
> clients to eliminate delays in completing show queries and making the 
> experience of using Impala more responsive.
> On the fringes, clients that don't know about long polling may have slightly 
> different timing with certain queries, as the RPC may wait the 
> {{long_polling_time_ms}} timeout then do its own sleep.
> Set {{long_polling_time_ms}} to a short period - say 100ms - to provide 
> better support for low-latency queries.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to