Uploaded image for project: 'Accumulo'
  1. Accumulo
  2. ACCUMULO-3199

RPC options in client configuration are passed to the RPC layer poorly

    XMLWordPrintableJSON

Details

    • Task
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 1.7.0
    • client
    • None

    Description

      The client configuration options for SSL, timeout, and (possibly) other RPC-related options are wrapped into an AccumuloConfiguration object to pass down to the RPC layer. This is done in a bit of a convoluted way, by leveraging the deprecated Instance.getConfiguration() method and relying on the fact that the Instance object is already passed through, instead of passing it through the Connector and internally to the the RPC layer where it's needed.

      The problem with this is that only the ZooKeeperInstance holds client configuration for this purpose, and simply calling instance.getConfiguration() will not always work as expected if you don't know what kind of Instance object you have. Further, this configuration object is occasionally incorrectly used in server code to read the server-side site configuration, when new ServerConfigurationFactory(instance).getConfiguration() should be used instead. This can lead to unexpected behavior if you are relying on the HdfsZooInstance implementation to provide the site configuration, but instead you have a different Instance, because all you'll get back is the DefaultConfiguration.

      The code that uses Instance.getConfiguration() needs to be changed, and the RPC-related configuration needs to be passed more explicitly through to the RPC layer, so we are less prone to bugs which make assumptions about which configuration is being retrieved with the deprecated API.

      Attachments

        Issue Links

          Activity

            People

              ctubbsii Christopher Tubbs
              ctubbsii Christopher Tubbs
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 20m
                  20m