Quanlong Huang has posted comments on this change. ( 
http://gerrit.cloudera.org:8080/21128 )

Change subject: IMPALA-12264: Add limit on number of HS2 sessions per user.
......................................................................


Patch Set 1:

(1 comment)

> Patch Set 1:
>
> CDPD-58529 / IMPALA-12264 requests that we should “prevent a rogue 
> application from repeatedly connecting to and monopolizing Impala”, and 
> suggests “we can add configurations to limit concurrent connections”. The 
> structure of thrift is such that it is hard to limit actual connections. For 
> now the plan is to limit the number of HS2 sessions per user. This is a 
> fairly straightforward change that I believe implements the main idea which 
> is to prevent rogue applications as the jira says. As with some other 
> features (e.g. -disconnected_session_timeout) this is just implemented for 
> HiveServer2. As Beeswax is now deprecated it is suggested that customers 
> disable beeswax access  for clients by setting the  --beeswax_port (Impala 
> Daemon Beeswax Port) flag to 0.

HS2 session can be used across different connections. It seems a rogue 
application can still open lots of connections and saturate the fe service 
threads. Haven't looked into the thrift structure yet. Do we know the user info 
when creating the connection? Maybe we can reject connections there?

http://gerrit.cloudera.org:8080/#/c/21128/1/be/src/service/impala-server.cc
File be/src/service/impala-server.cc:

http://gerrit.cloudera.org:8080/#/c/21128/1/be/src/service/impala-server.cc@282
PS1, Line 282: DEFINE_int32(max_hs2_sessions_per_user, 0, "The maximum allowed 
number of HiveServer2 "
nit: maybe -1 is better since it's used more to mean "unlimited", e.g. 
query_log_size, catalog_operation_log_size



--
To view, visit http://gerrit.cloudera.org:8080/21128
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: Impala-ASF
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: Idd28edc352102d89774f6ece5376e7c79ae41aa8
Gerrit-Change-Number: 21128
Gerrit-PatchSet: 1
Gerrit-Owner: Andrew Sherman <[email protected]>
Gerrit-Reviewer: Abhishek Rawat <[email protected]>
Gerrit-Reviewer: Andrew Sherman <[email protected]>
Gerrit-Reviewer: Impala Public Jenkins <[email protected]>
Gerrit-Reviewer: Quanlong Huang <[email protected]>
Gerrit-Comment-Date: Wed, 13 Mar 2024 14:05:44 +0000
Gerrit-HasComments: Yes

Reply via email to