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

[fiware-stackoverflow] Hive port is closed

    Details

      Description

      Created question in FIWARE Q/A platform on 17-08-2015 at 11:08
      Please, ANSWER this question AT https://stackoverflow.com/questions/32047191/hive-port-is-closed

      Question:
      Hive port is closed

      Description:
      I want to launch Hive queries remotely.

      For that, I am using the hive-jdbc library (0.14.0 version) and hadoop-core (1.2.1 version).

      Some weeks ago, I launch the following code:

      try

      { Class.forName("org.apache.hadoop.hive.jdbc.HiveDriver"); }

      catch (ClassNotFoundException e)

      { e.printStackTrace(); System.exit(1); }

      Connection con = DriverManager.getConnection(
      "jdbc:hive://cosmos.lab.fi-ware.org:10000/default", "user",
      "password");
      Statement stmt = con.createStatement();
      String sql = "select * from table_name";
      ResultSet res = stmt.executeQuery(sql);
      while (res.next())

      { System.out.println("value: " + res.getString(1)); }

      and it works, but now I am getting this error:

      java.sql.SQLException: Could not establish connection to cosmos.lab.fi-ware.org:10000/default: java.net.ConnectException: Conexión rehusada
      at org.apache.hadoop.hive.jdbc.HiveConnection.<init>(HiveConnection.java:117)
      at org.apache.hadoop.hive.jdbc.HiveDriver.connect(HiveDriver.java:107)
      at java.sql.DriverManager.getConnection(DriverManager.java:571)
      at java.sql.DriverManager.getConnection(DriverManager.java:215)

      I saw that now the Hive port (10000) is closed.

      So, I am wondering what is the correct way to use a remote hive client to access to cosmos, or If I have to change the way to get data from cosmos.

        Activity

        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open In Progress In Progress
        3d 18h 35m 1 Fernando Lopez 26/May/17 9:41 AM
        In Progress In Progress Answered Answered
        1s 1 Fernando Lopez 26/May/17 9:41 AM
        Answered Answered Closed Closed
        2s 1 Fernando Lopez 26/May/17 9:41 AM
        fla Fernando Lopez made changes -
        Fix Version/s 2021 [ 12600 ]
        fla Fernando Lopez made changes -
        Resolution Done [ 10000 ]
        Status Answered [ 10104 ] Closed [ 6 ]
        fla Fernando Lopez made changes -
        Status In Progress [ 3 ] Answered [ 10104 ]
        fla Fernando Lopez made changes -
        Status Open [ 1 ] In Progress [ 3 ]
        fla Fernando Lopez made changes -
        HD-Enabler Cosmos [ 10872 ]
        Description
        Created question in FIWARE Q/A platform on 17-08-2015 at 11:08
        {color: red}Please, ANSWER this question AT{color} https://stackoverflow.com/questions/32047191/hive-port-is-closed


        +Question:+
        Hive port is closed

        +Description:+
        I want to launch Hive queries remotely.

        For that, I am using the hive-jdbc library (0.14.0 version) and hadoop-core (1.2.1 version).

        Some weeks ago, I launch the following code:

            try {
                Class.forName("org.apache.hadoop.hive.jdbc.HiveDriver");
            } catch (ClassNotFoundException e) {
                e.printStackTrace();
                System.exit(1);
            }
            Connection con = DriverManager.getConnection(
                    "jdbc:hive://cosmos.lab.fi-ware.org:10000/default", "user",
                    "password");
            Statement stmt = con.createStatement();
            String sql = "select * from table_name";
            ResultSet res = stmt.executeQuery(sql);
            while (res.next()) {
                System.out.println("value: " + res.getString(1));
            }


        and it works, but now I am getting this error:

        java.sql.SQLException: Could not establish connection to cosmos.lab.fi-ware.org:10000/default: java.net.ConnectException: Conexión rehusada
        at org.apache.hadoop.hive.jdbc.HiveConnection.&lt;init&gt;(HiveConnection.java:117)
        at org.apache.hadoop.hive.jdbc.HiveDriver.connect(HiveDriver.java:107)
        at java.sql.DriverManager.getConnection(DriverManager.java:571)
        at java.sql.DriverManager.getConnection(DriverManager.java:215)


        I saw that now the Hive port (10000) is closed.

        So, I am wondering what is the correct way to use a remote hive client to access to cosmos, or If I have to change the way to get data from cosmos.
        Created question in FIWARE Q/A platform on 17-08-2015 at 11:08
        {color: red}Please, ANSWER this question AT{color} https://stackoverflow.com/questions/32047191/hive-port-is-closed


        +Question:+
        Hive port is closed

        +Description:+
        I want to launch Hive queries remotely.

        For that, I am using the hive-jdbc library (0.14.0 version) and hadoop-core (1.2.1 version).

        Some weeks ago, I launch the following code:

            try {
                Class.forName("org.apache.hadoop.hive.jdbc.HiveDriver");
            } catch (ClassNotFoundException e) {
                e.printStackTrace();
                System.exit(1);
            }
            Connection con = DriverManager.getConnection(
                    "jdbc:hive://cosmos.lab.fi-ware.org:10000/default", "user",
                    "password");
            Statement stmt = con.createStatement();
            String sql = "select * from table_name";
            ResultSet res = stmt.executeQuery(sql);
            while (res.next()) {
                System.out.println("value: " + res.getString(1));
            }


        and it works, but now I am getting this error:

        java.sql.SQLException: Could not establish connection to cosmos.lab.fi-ware.org:10000/default: java.net.ConnectException: Conexión rehusada
        at org.apache.hadoop.hive.jdbc.HiveConnection.&lt;init&gt;(HiveConnection.java:117)
        at org.apache.hadoop.hive.jdbc.HiveDriver.connect(HiveDriver.java:107)
        at java.sql.DriverManager.getConnection(DriverManager.java:571)
        at java.sql.DriverManager.getConnection(DriverManager.java:215)


        I saw that now the Hive port (10000) is closed.

        So, I am wondering what is the correct way to use a remote hive client to access to cosmos, or If I have to change the way to get data from cosmos.
        HD-Chapter Data [ 10838 ]
        fla Fernando Lopez made changes -
        Assignee Francisco Romero [ frb ]
        backlogmanager Backlog Manager made changes -
        Field Original Value New Value
        Component/s FIWARE-TECH-HELP [ 10278 ]
        Hide
        backlogmanager Backlog Manager added a comment -

        2017-05-22 15:06|CREATED monitor | # answers= 0, accepted answer= False

        Show
        backlogmanager Backlog Manager added a comment - 2017-05-22 15:06|CREATED monitor | # answers= 0, accepted answer= False
        backlogmanager Backlog Manager created issue -

          People

          • Assignee:
            frb Francisco Romero
            Reporter:
            backlogmanager Backlog Manager
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: