Casey Ching has posted comments on this change. Change subject: Re-enable Kudu in build using client stubs when needed ......................................................................
Patch Set 1: (3 comments) After thinking about this a bit more, the original way of erroring at construction time made more sense. Now the code differences should be very small when Kudu is supported/not supported. If people still prefer the checks in each scan/sink node method I'll go back to that. Dan, I liked the idea about the weak symbols but couldn't get it to work. I spent about 30 mins on it. Getting that to work seemed more like a nice thing to have and not worth spending more time on. http://gerrit.cloudera.org:8080/#/c/2585/1/be/src/exec/kudu-table-sink.cc File be/src/exec/kudu-table-sink.cc: Line 294: if (!KuduIsAvailable()) return; > is this needed? looks like the code below should work (generally, Close() c Looks like it shouldn't be needed. I'd like to take a different approach though. It's just much easier to do this at a higher level so we don't have to think about stuff like this. http://gerrit.cloudera.org:8080/#/c/2585/1/be/src/exec/kudu-util.cc File be/src/exec/kudu-util.cc: Line 34: DECLARE_bool(enable_kudu); > I thought that if we were going to have the stubbing at the kudu client lev I tried Dan's suggestion about weak symbols but couldnt get it to work. I think we'll want both a flag and a build-time way to disable Kudu. The flag help with testing. The build-time stuff is more reliable when Kudu really isn't available. Line 196: DCHECK(KuduIsAvailable()); > how about making this an if-stmt and removing the one at the callsite? (to I kept it as is. The other stuff was also changed to use this pattern. It turned out to result in fewer code differences, I think it reads better too. -- To view, visit http://gerrit.cloudera.org:8080/2585 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: comment Gerrit-Change-Id: I4bf1c964faf21722137adc4f7ba7f78654f0f712 Gerrit-PatchSet: 1 Gerrit-Project: Impala Gerrit-Branch: cdh5-trunk Gerrit-Owner: Casey Ching <[email protected]> Gerrit-Reviewer: Casey Ching <[email protected]> Gerrit-Reviewer: Dan Hecht <[email protected]> Gerrit-Reviewer: Matthew Jacobs <[email protected]> Gerrit-HasComments: Yes
