Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added initial thrift support #35

Merged
merged 1 commit into from
Aug 4, 2015
Merged

Conversation

bpanneton
Copy link
Contributor

Potential thrift support. I'm not sure if this is the best way to do it, but I manged to get it working. I was able to connect with happybase.

@chu11
Copy link
Member

chu11 commented Jul 31, 2015

Overall looks fine, a few nits & issues.

  1. Don't think you need a new variable "hbasewiththrift", I think the original is enough. You might have been copying code that created new variables b/c of the need to add things into hbase-env.sh or hbase-site.xml.

  2. Please add a check for correct input in magpie-check-inputs

  3. Shouldn't there be something to shutdown the server when we tear down?

  4. Instead of "HBASE_WITH_THRIFT" how about "HBASE_START_THRIFT_SERVER", since this is actually turning on a new server, it's not just another library/link/etc.

@bpanneton
Copy link
Contributor Author

  1. Please add a check for correct input in magpie-check-inputs
    I didn't add anything to magpie-check-inputs because I wanted it to default to 'no' if the variable was not set. I can still add the default code into magpie-check-inputs but I didn't see you doing anything like that there.

I went ahead and made the changes as you described. Let me know if anything else should be changed.

@chu11
Copy link
Member

chu11 commented Aug 4, 2015

Hey Brian, what I meant was a check like this:

if [ "${HADOOP_SETUP}X" != "X" ] \
    && ( [ "${HADOOP_SETUP}" != "yes" ] && [ "${HADOOP_SETUP}" != "no" ] )
then
    echo "HADOOP_SETUP must be set to yes or no"
    exit 1
fi

Just to make sure the input is "yes" or "no". That way it doesn't matter if the user set the environment variable or not when you check for == "yes". BTW, also noticed:

if [ ${HBASE_START_THRIFT_SERVER} == "yes" ]

for consistency to other code I think that should be quotes.

As for the shutdown code, shouldn't the hbase-daemon.sh call be before stop-hbase.sh? I would think it should go before it. But perhaps it's independent of the daemons launched by start-hbase.sh? I really have no idea, it just looks peculiar.

@chu11
Copy link
Member

chu11 commented Aug 4, 2015

LGTM

chu11 added a commit that referenced this pull request Aug 4, 2015
@chu11 chu11 merged commit 3a53678 into LLNL:master Aug 4, 2015
@bpanneton bpanneton deleted the thrift-support branch August 4, 2015 18:54
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