Uploaded image for project: 'Zeppelin'
  1. Zeppelin
  2. ZEPPELIN-1707

Pass userName when creating interpreter through thrift

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 0.6.2
    • Fix Version/s: 0.7.0
    • Component/s: None
    • Labels:
      None

      Description

      In ZEPPELIN-1607, I'd like refactor livy interpreter to scoped mode by default, this require username when open this interpreter. So I propose to pass username when creating interpreter through thrift.

        Issue Links

          Activity

          Hide
          githubbot ASF GitHub Bot added a comment -

          GitHub user zjffdu opened a pull request:

          https://github.com/apache/zeppelin/pull/1679

          ZEPPELIN-1707. Pass userName when creating interpreter through thrift

              1. What is this PR for?
                In ZEPPELIN-1607, I'd like refactor livy interpreter to scoped mode by default, this require username when open this interpreter. So I propose to pass username when creating interpreter through thrift.
                What I did in this PR.
          • update RemoteInterpreterService.thrift and regenerate the java thrift code.
          • I use thrift 0.9.2 because I notice in zeppelin/pom.xml, the libthrift.version we use is 0.9.2
          • update genthrift.sh, otherwise hashCode method won't be generated correctly.
              1. What type of PR is it?
                [Improvement]
              1. Todos
          • [ ] - Task
              1. What is the Jira issue?
              1. Screenshots (if appropriate)
              1. Questions:
          • Does the licenses files need update? No
          • Is there breaking changes for older versions? No
          • Does this needs documentation? No

          You can merge this pull request into a Git repository by running:

          $ git pull https://github.com/zjffdu/zeppelin ZEPPELIN-1707

          Alternatively you can review and apply these changes as the patch at:

          https://github.com/apache/zeppelin/pull/1679.patch

          To close this pull request, make a commit to your master/trunk branch
          with (at least) the following in the commit message:

          This closes #1679


          commit 223a48f0ce8d0d768bc2eb0364b82e25f7a633ff
          Author: Jeff Zhang <zjffdu@apache.org>
          Date: 2016-11-25T01:32:14Z

          ZEPPELIN-1707. Pass userName when creating interpreter through thrift


          Show
          githubbot ASF GitHub Bot added a comment - GitHub user zjffdu opened a pull request: https://github.com/apache/zeppelin/pull/1679 ZEPPELIN-1707 . Pass userName when creating interpreter through thrift What is this PR for? In ZEPPELIN-1607 , I'd like refactor livy interpreter to scoped mode by default, this require username when open this interpreter. So I propose to pass username when creating interpreter through thrift. What I did in this PR. update RemoteInterpreterService.thrift and regenerate the java thrift code. I use thrift 0.9.2 because I notice in zeppelin/pom.xml, the libthrift.version we use is 0.9.2 update genthrift.sh, otherwise hashCode method won't be generated correctly. What type of PR is it? [Improvement] Todos [ ] - Task What is the Jira issue? https://issues.apache.org/jira/browse/ZEPPELIN-1707 Screenshots (if appropriate) Questions: Does the licenses files need update? No Is there breaking changes for older versions? No Does this needs documentation? No You can merge this pull request into a Git repository by running: $ git pull https://github.com/zjffdu/zeppelin ZEPPELIN-1707 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/zeppelin/pull/1679.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #1679 commit 223a48f0ce8d0d768bc2eb0364b82e25f7a633ff Author: Jeff Zhang <zjffdu@apache.org> Date: 2016-11-25T01:32:14Z ZEPPELIN-1707 . Pass userName when creating interpreter through thrift
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user zjffdu closed the pull request at:

          https://github.com/apache/zeppelin/pull/1679

          Show
          githubbot ASF GitHub Bot added a comment - Github user zjffdu closed the pull request at: https://github.com/apache/zeppelin/pull/1679
          Hide
          githubbot ASF GitHub Bot added a comment -

          GitHub user zjffdu reopened a pull request:

          https://github.com/apache/zeppelin/pull/1679

          ZEPPELIN-1707. Pass userName when creating interpreter through thrift

              1. What is this PR for?
                In ZEPPELIN-1607, I'd like refactor livy interpreter to scoped mode by default, this require username when open this interpreter. So I propose to pass username when creating interpreter through thrift.
                What I did in this PR.
          • update `RemoteInterpreterService.thrift` and regenerate the java thrift code.
          • update `genthrift.sh`, otherwise hashCode method won't be generated correctly.
          • This is one compilation issue (`PythonDockerInterpreterTest.java`) in the existing master branch, I also fix it here.
              1. What type of PR is it?
                [Improvement]
              1. Todos
          • [ ] - Task
              1. What is the Jira issue?
              1. Screenshots (if appropriate)
              1. Questions:
          • Does the licenses files need update? No
          • Is there breaking changes for older versions? No
          • Does this needs documentation? No

          You can merge this pull request into a Git repository by running:

          $ git pull https://github.com/zjffdu/zeppelin ZEPPELIN-1707

          Alternatively you can review and apply these changes as the patch at:

          https://github.com/apache/zeppelin/pull/1679.patch

          To close this pull request, make a commit to your master/trunk branch
          with (at least) the following in the commit message:

          This closes #1679


          commit cbb829cc3754ce9090939c3deebe304300ef44f8
          Author: Jeff Zhang <zjffdu@apache.org>
          Date: 2016-11-25T01:58:15Z

          ZEPPELIN-1707. Pass userName when creating interpreter through thrift

          commit e8e913fd85f2b627e096a3eeb1840af7157113e9
          Author: Jeff Zhang <zjffdu@apache.org>
          Date: 2016-11-25T08:33:39Z

          regenerate it using thrift 0.9.2


          Show
          githubbot ASF GitHub Bot added a comment - GitHub user zjffdu reopened a pull request: https://github.com/apache/zeppelin/pull/1679 ZEPPELIN-1707 . Pass userName when creating interpreter through thrift What is this PR for? In ZEPPELIN-1607 , I'd like refactor livy interpreter to scoped mode by default, this require username when open this interpreter. So I propose to pass username when creating interpreter through thrift. What I did in this PR. update `RemoteInterpreterService.thrift` and regenerate the java thrift code. update `genthrift.sh`, otherwise hashCode method won't be generated correctly. This is one compilation issue (`PythonDockerInterpreterTest.java`) in the existing master branch, I also fix it here. What type of PR is it? [Improvement] Todos [ ] - Task What is the Jira issue? https://issues.apache.org/jira/browse/ZEPPELIN-1707 Screenshots (if appropriate) Questions: Does the licenses files need update? No Is there breaking changes for older versions? No Does this needs documentation? No You can merge this pull request into a Git repository by running: $ git pull https://github.com/zjffdu/zeppelin ZEPPELIN-1707 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/zeppelin/pull/1679.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #1679 commit cbb829cc3754ce9090939c3deebe304300ef44f8 Author: Jeff Zhang <zjffdu@apache.org> Date: 2016-11-25T01:58:15Z ZEPPELIN-1707 . Pass userName when creating interpreter through thrift commit e8e913fd85f2b627e096a3eeb1840af7157113e9 Author: Jeff Zhang <zjffdu@apache.org> Date: 2016-11-25T08:33:39Z regenerate it using thrift 0.9.2
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user zjffdu commented on the issue:

          https://github.com/apache/zeppelin/pull/1679

          @Leemoonsoo @prabhjyotsingh Please help review.

          Show
          githubbot ASF GitHub Bot added a comment - Github user zjffdu commented on the issue: https://github.com/apache/zeppelin/pull/1679 @Leemoonsoo @prabhjyotsingh Please help review.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user bzz commented on the issue:

          https://github.com/apache/zeppelin/pull/1679

          Looks good to me.

          CI is green now, so will merge it to master if there is no further discussion.

          Show
          githubbot ASF GitHub Bot added a comment - Github user bzz commented on the issue: https://github.com/apache/zeppelin/pull/1679 Looks good to me. CI is green now, so will merge it to master if there is no further discussion.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user astroshim commented on the issue:

          https://github.com/apache/zeppelin/pull/1679

          Sorry for late review.

          User name is already passed to interpreter.
          We can get the user id on interpreterContext.getAuthenticationInfo().getUser()

          I think passing password is valuable in this PR because we can use the login account information(username + password) on interpreter like JDBC.

          What do you think?

          Show
          githubbot ASF GitHub Bot added a comment - Github user astroshim commented on the issue: https://github.com/apache/zeppelin/pull/1679 Sorry for late review. User name is already passed to interpreter. We can get the user id on interpreterContext.getAuthenticationInfo().getUser() I think passing password is valuable in this PR because we can use the login account information(username + password) on interpreter like JDBC. What do you think?
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user zjffdu commented on the issue:

          https://github.com/apache/zeppelin/pull/1679

          @astroshim `InterpreterContext` is only available when interpreting paragraph (after Interpreter is opened). What I need here is to get username when opening interpreter.

          Show
          githubbot ASF GitHub Bot added a comment - Github user zjffdu commented on the issue: https://github.com/apache/zeppelin/pull/1679 @astroshim `InterpreterContext` is only available when interpreting paragraph (after Interpreter is opened). What I need here is to get username when opening interpreter.
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user astroshim commented on the issue:

          https://github.com/apache/zeppelin/pull/1679

          @zjffdu It's my misunderstanding. LGTM!

          Show
          githubbot ASF GitHub Bot added a comment - Github user astroshim commented on the issue: https://github.com/apache/zeppelin/pull/1679 @zjffdu It's my misunderstanding. LGTM!
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user Leemoonsoo commented on the issue:

          https://github.com/apache/zeppelin/pull/1679

          LGTM

          Show
          githubbot ASF GitHub Bot added a comment - Github user Leemoonsoo commented on the issue: https://github.com/apache/zeppelin/pull/1679 LGTM
          Hide
          githubbot ASF GitHub Bot added a comment -

          Github user asfgit closed the pull request at:

          https://github.com/apache/zeppelin/pull/1679

          Show
          githubbot ASF GitHub Bot added a comment - Github user asfgit closed the pull request at: https://github.com/apache/zeppelin/pull/1679

            People

            • Assignee:
              zjffdu Jeff Zhang
              Reporter:
              zjffdu Jeff Zhang
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development