Skip to content

PHOENIX-5907 Remove unused part from phoenix_utils.py#35

Closed
infraio wants to merge 2 commits intoapache:masterfrom
infraio:remove-unused
Closed

PHOENIX-5907 Remove unused part from phoenix_utils.py#35
infraio wants to merge 2 commits intoapache:masterfrom
infraio:remove-unused

Conversation

@infraio
Copy link
Copy Markdown
Contributor

@infraio infraio commented May 20, 2020

No description provided.


# The command is run through subprocess so environment variables are automatically inherited
java_cmd = '%(java)s -cp ' + hbase_config_path + os.pathsep + hadoop_config_path + os.pathsep + \
java_cmd = '%(java)s -cp ' + hbase_config_path + os.pathsep + \
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think that we should remove hadoop_config_path
We need the Hadoop config files for operation, and there is no guarantee that the hbase config dir contains a copy. It seems to be deployment dependent.

See https://hbase.apache.org/book.html#fully_dist

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But the hadoop_conf is only used to start a hbase cluster? For queryserver, it only need to know the hbase cluster, such as a hbase client, which don't need to know the hdfs config? I read queryserver's doc and start queryserver which only have hbase's config. I miss something?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, the Hadoop config is also is also used by all Hadoop clients, i.e. anything that uses HDFS, MR, etc.

HBase is designed to work on top of Hadoop, and uses many of its features. It needs the Hadoop config even for its clients.

One example is the proxyuser settings that are defined in the Hadoop config files, and HBase and Phoenix both need to access those.

The Phoenix client also uses HDFS directly (at least for loading UDF jars), so its needs to have access to all HDFS settings as well.

I am sure that there are plenty of other cases where HBase (client) and Phoenix need to have access to the full Hadoop config, the above two are just the ones that have caused problems for me personally.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Got it. Thanks for explanation.

global phoenix_test_jar_path
phoenix_test_jar_path = os.path.join(current_dir, "..", "phoenix-core", "target","*")

global hadoop_conf
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

see comment for queryserver

@asfgit asfgit closed this in 87cebd3 Jun 3, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants