Uploaded image for project: 'Apache Curator'
  1. Apache Curator
  2. CURATOR-586

NamespaceFacade return null if namespace is empty

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Trivial
    • Resolution: Not A Problem
    • None
    • None
    • Framework
    • None

    Description

      According to java doc framework should return empty string if namespace is empty instead of null:

       

      /**
       * Return the current namespace or "" if none
       *
       * @return namespace
       */
      public String getNamespace();
      

       

      If namespace is claimed from CuratorFramework client directly all is ok, but if NamespaceFacade is used then null is returned. 

      How to reproduce:

      RetryPolicy policy = ...;
      CuratorFramework client = CuratorFrameworkFactory.newClient("connectionString", policy);
      CuratorFramework clientWithNamespaceFacade = client.usingNamespace(null);
      clientWithNamespaceFacade.getNamespace(); // <- expected "", but got null
      

       

      Attachments

        Activity

          People

            Unassigned Unassigned
            nickRyan Nikita Ryanov
            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 - 1h 20m
                1h 20m