You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@knox.apache.org by "Satish Nambiar (JIRA)" <ji...@apache.org> on 2016/11/23 22:07:58 UTC
[jira] [Comment Edited] (KNOX-713) Knox Shell HDFS.get.Request is
Package Private
[ https://issues.apache.org/jira/browse/KNOX-713?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15691489#comment-15691489 ]
Satish Nambiar edited comment on KNOX-713 at 11/23/16 10:07 PM:
----------------------------------------------------------------
Yes is I tried similar code. I still see the error: "The type Get.Response is not visible"
was (Author: sdnambiar):
I still see the error: "The type Get.Response is not visible"
> Knox Shell HDFS.get.Request is Package Private
> ----------------------------------------------
>
> Key: KNOX-713
> URL: https://issues.apache.org/jira/browse/KNOX-713
> Project: Apache Knox
> Issue Type: Bug
> Components: ClientDSL
> Reporter: Larry McCay
> Assignee: Larry McCay
> Fix For: 0.9.1, 0.11.0
>
>
> As raised on the user@ list by Chris Snow, the Knox ClientDSL classes for the HDFS Request are package private. This causes compilation errors when developing a program that leverages them in a different package namespace.
> Chris provided the following example:
> {code}
> package net.christophersnow;
> import org.apache.hadoop.gateway.shell.Hadoop;
> import org.apache.hadoop.gateway.shell.hdfs.Hdfs;
> public class TestKnox {
> public static void main(String[] args) {
> Hadoop session = Hadoop.login( "test", "test", "test" );
> String text = Hdfs.get( session ).from( "test" ).now().getString();
> session.shutdown();
> }
> }
> {code}
> Which results in the following errors:
> {code}
> :compileJava/home/travis/build/snowch/knox-java-example/src/main/java/net/christophersnow/TestKnox.java:12: error: from(String) in Request is defined in an inaccessible class or interface
> String text = Hdfs.get( session ).from( "test" ).now().getString();
> ^
> /home/travis/build/snowch/knox-java-example/src/main/java/net/christophersnow/TestKnox.java:12: error: now() in AbstractRequest is defined in an inaccessible class or interface
> String text = Hdfs.get( session ).from( "test" ).now().getString();
> ^
> where T is a type-variable:
> T extends Object declared in class AbstractRequest
> /home/travis/build/snowch/knox-java-example/src/main/java/net/christophersnow/TestKnox.java:12: error: getString() in BasicResponse is defined in an inaccessible class or interface
> String text = Hdfs.get( session ).from( "test" ).now().getString();
> ^
> 3 errors
> FAILED
> {code}
> The Request inner classes need to be made public across all of the service clientDSL code.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)