When Impala editor is not installed, then the importer fails to get the USER_SCRATCH_DIR_PERMISSION from impala conf.
Jira:
@@ -170,7 +170,7 @@ class SQLIndexer(object):
user_scratch_dir = self.fs.get_home_dir() + '/.scratchdir/%s' % str(uuid.uuid4()) # Make sure it's unique.
self.fs.do_as_user(self.user, self.fs.mkdir, user_scratch_dir, 0o0777)
self.fs.do_as_user(self.user, self.fs.rename, source['path'], user_scratch_dir)
- if USER_SCRATCH_DIR_PERMISSION.get():
+ if editor_type == 'impala' and USER_SCRATCH_DIR_PERMISSION.get():
self.fs.do_as_user(self.user, self.fs.chmod, user_scratch_dir, 0o0777, True)
source_path = user_scratch_dir + '/' + source['path'].split('/')[-1]
