Uploaded image for project: 'Help-Desk'
  1. Help-Desk
  2. HELP-3388

FIWARE.Request.Tech.Data.BigData-Analysis.WebHDFSAndC#

    Details

    • Type: extRequest
    • Status: Closed
    • Priority: Major
    • Resolution: Done
    • Fix Version/s: 2021
    • Component/s: FIWARE-TECH-HELP
    • Labels:
      None

      Description

      Hello,
      I'm writing a .net application with C# to programmatically run REST apis against hdfs on fiware but on http POST operations it fails with 401 (access denied). it works for simple GET operations but I'm not sure how to do authentication. From the spec it seems SPEGNA and delegated auth tokens are two options but how do i do this programmatically? I only have my user name and password to go off of. I'm using the RestSharp library to make rest interactions easier.
      This code works
      var client = new RestClient("http://cosmos.lab.fi-ware.org:14000");
      request = new RestRequest("webhdfs/v1/user/<userID>");
      request.AddParameter("op", "LISTSTATUS");
      request.AddParameter("user.name", "<userID>");
      IRestResponse response = client.Execute(request);
      var content = response.Content; // raw content as string
      this code fails with http 401
      var client = new RestClient("http://cosmos.lab.fi-ware.org:14000");
      var request = new RestRequest("webhdfs/v1/user/<userID>/structured_data123.txt",Method.PUT);
      request.AddParameter("op", "CREATE");
      request.AddParameter("user.name", "<userID>");
      IRestResponse response = client.Execute(request);
      HTTP Status 401 - org.apache.hadoop.security.authentication.client.AuthenticationException: Anonymous requests are disallowed
      Thoughts? ideas? thank you in advance!

      _______________________________________________
      Fiware-lab-help mailing list
      Fiware-lab-help@lists.fi-ware.org
      https://lists.fi-ware.org/listinfo/fiware-lab-help

      [Created via e-mail received from: Saad Ansari <saada@connecterra.io>]

        Activity

        fw.ext.user FW External User created issue -
        danielepavia Daniele Pavia (Inactive) made changes -
        Field Original Value New Value
        Status Open [ 1 ] In Progress [ 3 ]
        danielepavia Daniele Pavia (Inactive) made changes -
        Assignee Daniele Pavia [ danielepavia ]
        mev Manuel Escriche made changes -
        Component/s FIWARE-TECH-HELP [ 10278 ]
        mev Manuel Escriche made changes -
        Assignee Daniele Pavia [ danielepavia ] Francisco Romero [ frb ]
        frb Francisco Romero made changes -
        Status In Progress [ 3 ] Answered [ 10104 ]
        frb Francisco Romero made changes -
        Resolution Done [ 10000 ]
        Status Answered [ 10104 ] Closed [ 6 ]
        frb Francisco Romero made changes -
        Summary [Fiware-lab-help] FI-Lab Assistance FIWARE.Request.Lab.Data.BigData-Analysis.WebHDFSAndC#
        mev Manuel Escriche made changes -
        Summary FIWARE.Request.Lab.Data.BigData-Analysis.WebHDFSAndC# FIWARE.Request.Tech.Data.BigData-Analysis.WebHDFSAndC#
        mev Manuel Escriche made changes -
        Sender Email saada@connecterra.io
        mev Manuel Escriche made changes -
        HD-Enabler Cosmos [ 10872 ]
        HD-Chapter Data [ 10838 ]
        fla Fernando Lopez made changes -
        Fix Version/s 2021 [ 12600 ]

          People

          • Assignee:
            frb Francisco Romero
            Reporter:
            fw.ext.user FW External User
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: