Uploaded image for project: 'JBoss Enterprise Application Platform'
  1. JBoss Enterprise Application Platform
  2. JBEAP-6672

Tab completion suggest writing attribute which has access type metric and is not writable

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Minor
    • 7.1.0.DR8
    • 7.1.0.DR7
    • CLI, User Experience
    • None
    • Hide

      Start EAP in standalone-full-ha profile

       sh standalone.sh -c standalone-full-ha.xml 

      Connect with CLI and navigate to jms-queue on messaging subsystem

       cd subsystem=messaging-activemq/server=default/jms-queue=DLQ
      

      Try to write attribute and as a name, attributes of type metric are also suggested.

       :write-attribute(name=
      consumer-count  delivering-count  entries  legacy-entries  message-count  messages-added  scheduled-count  
      
      Show
      Start EAP in standalone-full-ha profile sh standalone.sh -c standalone-full-ha.xml Connect with CLI and navigate to jms-queue on messaging subsystem cd subsystem=messaging-activemq/server= default /jms-queue=DLQ Try to write attribute and as a name, attributes of type metric are also suggested. :write-attribute(name= consumer-count delivering-count entries legacy-entries message-count messages-added scheduled-count

    Description

      CLI tab completion suggests attributes that are not writable and their access-type is metric
      Example

      /subsystem=messaging-activemq/server=default/jms-queue=DLQ:write-attribute(name=<TAB>
      consumer-count  delivering-count  entries  legacy-entries  message-count  messages-added  scheduled-count  
      

      From executing :read-resource-description we can see, attributes consumer-count, delivering-count, message-count, messages-added, scheduled-count are of type metric.

      On attempt to write metric attribute, for example message-count, non writable error is printed

      [standalone@localhost:9990 jms-queue=q] :write-attribute(name=message-count, value=5)
      {
          "outcome" => "failed",
          "failure-description" => "WFLYCTL0048: Attribute message-count is not writable",
          "rolled-back" => true
      }
      

      CLI should not suggest writing attributes that are not writable.

      Attachments

        Issue Links

          Activity

            People

              chaowan@redhat.com Chao Wang
              mstyk_jira Martin Styk (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: