Sean Busbey created ACCUMULO-4557:
-------------------------------------

             Summary: Instance API should state when returning null is expected.
                 Key: ACCUMULO-4557
                 URL: https://issues.apache.org/jira/browse/ACCUMULO-4557
             Project: Accumulo
          Issue Type: Bug
          Components: client
    Affects Versions: 1.8.0, 1.7.2, 1.7.1
            Reporter: Sean Busbey
            Priority: Critical


This is an issue at least in 1.6.0+. Ran into during ACCUMULO-4556.

In that case the TablesServlet is making use of Instance to get root tablet 
location information via the Instance interface. The API for {{getRootTablet}} 
in master is:

{code}
  /**
   * Returns the location of the tablet server that is serving the root tablet.
   *
   * @return location in "hostname:port" form
   */
  String getRootTabletLocation();
{code}

When the root tablet is offline, all of our current implementations return 
{{null}}. The data structure used in TablesServlet can't handle nulls, so the 
code fails with an NPE.

We should review the current implementations for Instance and update the API to 
include details on the circumstances where a {{null}} will be returned from all 
of the defined methods.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to