百度智能云

All Product Document

          Data Warehouse

          SET-PROPERTY

          SET PROPERTY

          description

          SET PROPERTY [FOR 'user']
          'key' = 'value' [, 'key' = 'value'];

          Set user property, such as number of connections etc..

          The user property set here is special for user but not for user_identity.

          That is, assuming that two users have been created by using CREATE USER statement, namely user 'jack'@'%' and user 'jack'@'192.%', then use SET PROPERTY statement, which is special for jack user, but not for 'jack'@'%' user or 'jack'@'192.%' user.

          • key

            Currently it supports the following properties:

            • max_user_connections

              Max number of connections allowed for the user.

          Example

          1. Modify the max number of connections for user jack as 1000

            SET PROPERTY FOR 'jack' 'max_user_connections' = '200';

          Keywords

          SET, PROPERTY

          Best Practices

          1. Max number of connections.

            The max number of connections refers to the limit on max connections of the user on one Leader Node, which defaults to 100. If a cluster has 3 Leader Nodes, then the max number of connections is 300 theoretically.

            The Palo cluster has upper limit on total number of connections, which defaults to 1024. That mean, the number of connections of all users should not exceed this upper limit.

            If it is a high concurrency application, it is recommended to connect and duplicate these connections at business side through thread pool. Generally the default limit on number of connections can satisfy the access scenario of high concurrency by thousands of QPSs.

          Previous
          Information View Statement
          Next
          SET-PASSWORD