You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@impala.apache.org by jo...@apache.org on 2019/04/05 15:51:40 UTC

[impala] 02/03: IMPALA-6216: Make PYTHON_EGG_CACHE configurable

This is an automated email from the ASF dual-hosted git repository.

joemcdonnell pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/impala.git

commit f3f7774d1a6dc41bd3d3a347bec5909d2ec4910f
Author: Yongzhi Chen <yc...@cloudera.com>
AuthorDate: Tue Apr 2 09:40:23 2019 -0400

    IMPALA-6216: Make PYTHON_EGG_CACHE configurable
    
    User can set environment variable PYTHON_EGG_CACHE before call
    impala-shell.
    
    Testing:
    Run impala-shell with or w/o PYTHON_EGG_CACHE configured
    
    Change-Id: I695b2b31d9045eef1a53268f6516858935aed508
    Reviewed-on: http://gerrit.cloudera.org:8080/12911
    Tested-by: Impala Public Jenkins <im...@cloudera.com>
    Reviewed-by: Bharath Vissapragada <bh...@cloudera.com>
---
 shell/impala-shell | 8 +++++---
 1 file changed, 5 insertions(+), 3 deletions(-)

diff --git a/shell/impala-shell b/shell/impala-shell
index 9e17c26..48dcf60 100755
--- a/shell/impala-shell
+++ b/shell/impala-shell
@@ -35,9 +35,11 @@ SHELL_HOME=${IMPALA_SHELL_HOME:-${SCRIPT_DIR}}
 # Set the envrionment's locale settings to allow for utf-8 compatibility
 export LC_CTYPE=${LC_CTYPE:-en_US.UTF-8}
 
-# We should set the EGG_CACHE to a per-user temporary location.
-# This follows what hue does.
-PYTHON_EGG_CACHE=/tmp/impala-shell-python-egg-cache-${USER}
+# User can configure EGG_CACHE by setting PYTHON_EGG_CACHE.
+# By default it is set to a per-user temporary location,
+# which follows what hue does.
+PYTHON_EGG_CACHE=${PYTHON_EGG_CACHE:-/tmp/impala-shell-python-egg-cache-${USER}}
+
 if [ ! -d ${PYTHON_EGG_CACHE} ]; then
   mkdir ${PYTHON_EGG_CACHE}
 fi