[ https://issues.apache.org/jira/browse/HBASE-18393?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16090246#comment-16090246 ]
Sean Busbey commented on HBASE-18393: ------------------------------------- bq. 1. Can we break compatibility such that passing both non-interactive mode and a script to run is no longer supported? I think a workaround for these users would be to turn usage for the form command-generator | bin/hbase shell script -n into (cat script; command-generator) | bin/hbase shell -n sounds good to me, presuming this only impacts us on jruby 9k. given the major version, a release note should be sufficient. bq. 2. Can we presume that STDIN is bounded? Then we could read all of it up front, and treat that like a script file. All of the examples I've seen thus far have us reading a set of commands that are set when we begin. I'd be comfortable making this a requirement for {{--non-interactive}}, given that reading the results as someone goes and changing what commands are given sounds "interactive" to me. bq. 3. Related: do we need to process lines one at a time as we read them? I'm missing some subtly here. Is this just a question of whether we have all the input as a single string vs individual lines? Or the ability for lines we've read to impact reading of successive lines (effectively limiting what the user provided input can monkey patch)? > hbase shell non-interactive broken > ------------------------------------ > > Key: HBASE-18393 > URL: https://issues.apache.org/jira/browse/HBASE-18393 > Project: HBase > Issue Type: Bug > Components: scripts, shell > Affects Versions: 3.0.0, 2.0.0-alpha-1 > Reporter: Samir Ahmic > Assignee: Samir Ahmic > Priority: Blocker > Fix For: 2.0.0-beta-1 > > > Here is error for command line: > {code} > $ echo "list" | ./hbase shell -n > 2017-07-17 08:01:09,442 WARN [main] util.NativeCodeLoader: Unable to load > native-hadoop library for your platform... using builtin-java classes where > applicable > ERROR NoMethodError: undefined method `encoding' for #<IO:<STDIN>> > Did you mean? set_encoding > {code} -- This message was sent by Atlassian JIRA (v6.4.14#64029)