glassfish
  1. glassfish
  2. GLASSFISH-20493

Command Model cache not always updated

    Details

    • Type: Bug Bug
    • Status: Open
    • Priority: Blocker Blocker
    • Resolution: Unresolved
    • Affects Version/s: 4.0_b87_RC3
    • Fix Version/s: 4.1.1
    • Component/s: command_line_interface
    • Labels:
      None

      Description

      I've encountered a case where we changed the default value of a command, but that did not result in the command model cache being invalidated and updated. Details:

      The default value for a parameter was changed from "3.0" to "3.2" in the
      code like this:

      @Param(optional=true, defaultValue="3.2", acceptableValues="3.0,3.2")
      String ovmversion; 
      

      But the command cache in $HOME/.gfclient/cache/localhost.localdomain_7001/create-virtualization-provider-type-ovm still lists the old default value for ovmversion:

      $ cat create-virtualization-provider-type-ovm
      ETag: qa1JOZJjbBkTh8bbvYyQFQ==
      {"command":{"@name":"create-virtualization-provider-type-ovm",
      "option":[{"@name":"configName","@type":"STRING","@primary":"true"},
      {"@name":"_ovaburl","@type":"STRING","@optional":"true","@default":"http:\/\/localhost:7001"},
      {"@name":"_ovabuser","@type":"STRING","@optional":"true"},
      {"@name":"_ovabpassword","@type":"PASSWORD","@optional":"true"},
      {"@name":"ovmurl","@type":"STRING"},{"@name":"ovmuser","@type":"STRING"},
      {"@name":"ovmpassword","@type":"PASSWORD"},{"@name":"ovmpool","@type":"STRING"},
      {"@name":"ovmtimeout","@type":"STRING","@optional":"true","@default":"3600"},
      {"@name":"ovmversion","@type":"STRING","@optional":"true","@default":"3.0","@acceptable-values":"3.0,3.2"},
      {"@name":"defaultconfig","@type":"BOOLEAN","@optional":"true","@default":"false"},
      {"@name":"force","@type":"BOOLEAN","@optional":"true","@default":"false"}]}}
      

        Activity

        Joe Di Pol created issue -
        Joe Di Pol made changes -
        Field Original Value New Value
        Description I've encountered a case where we changed the default value of a command, but that did not result in the command model cache being invalidated and updated. Details:

        The default value for a parameter was changed from "3.0" to "3.2" in the
        code like this:

        {code}
        @Param(optional=true, defaultValue="3.2", acceptableValues="3.0,3.2")
        String ovmversion;
        {code}

        But the command cache in $HOME/.gfclient/cache/localhost.localdomain_7001/create-virtualization-provider-type-ovm still lists the old default value for ovmversion:

        {code}
        $ cat create-virtualization-provider-type-ovm
        ETag: qa1JOZJjbBkTh8bbvYyQFQ==
        {"command":{"@name":"create-virtualization-provider-type-ovm","option":[{"@name":"configName","@type":"STRING","@primary":"true"},{"@name":"_ovaburl","@type":"STRING","@optional":"true","@default":"http:\/\/localhost:7001"},{"@name":"_ovabuser","@type":"STRING","@optional":"true"},{"@name":"_ovabpassword","@type":"PASSWORD","@optional":"true"},{"@name":"ovmurl","@type":"STRING"},{"@name":"ovmuser","@type":"STRING"},{"@name":"ovmpassword","@type":"PASSWORD"},{"@name":"ovmpool","@type":"STRING"},{"@name":"ovmtimeout","@type":"STRING","@optional":"true","@default":"3600"},{"@name":"ovmversion","@type":"STRING","@optional":"true","@default":"3.0","@acceptable-values":"3.0,3.2"},{"@name":"defaultconfig","@type":"BOOLEAN","@optional":"true","@default":"false"},{"@name":"force","@type":"BOOLEAN","@optional":"true","@default":"false"}]}}
        {code}


        I've encountered a case where we changed the default value of a command, but that did not result in the command model cache being invalidated and updated. Details:

        The default value for a parameter was changed from "3.0" to "3.2" in the
        code like this:

        {code}
        @Param(optional=true, defaultValue="3.2", acceptableValues="3.0,3.2")
        String ovmversion;
        {code}

        But the command cache in $HOME/.gfclient/cache/localhost.localdomain_7001/create-virtualization-provider-type-ovm still lists the old default value for ovmversion:

        {code}
        $ cat create-virtualization-provider-type-ovm
        ETag: qa1JOZJjbBkTh8bbvYyQFQ==
        {"command":{"@name":"create-virtualization-provider-type-ovm",
        "option":[{"@name":"configName","@type":"STRING","@primary":"true"},
        {"@name":"_ovaburl","@type":"STRING","@optional":"true","@default":"http:\/\/localhost:7001"},
        {"@name":"_ovabuser","@type":"STRING","@optional":"true"},
        {"@name":"_ovabpassword","@type":"PASSWORD","@optional":"true"},
        {"@name":"ovmurl","@type":"STRING"},{"@name":"ovmuser","@type":"STRING"},
        {"@name":"ovmpassword","@type":"PASSWORD"},{"@name":"ovmpool","@type":"STRING"},
        {"@name":"ovmtimeout","@type":"STRING","@optional":"true","@default":"3600"},
        {"@name":"ovmversion","@type":"STRING","@optional":"true","@default":"3.0","@acceptable-values":"3.0,3.2"},
        {"@name":"defaultconfig","@type":"BOOLEAN","@optional":"true","@default":"false"},
        {"@name":"force","@type":"BOOLEAN","@optional":"true","@default":"false"}]}}
        {code}


        Byron Nevins made changes -
        Priority Major [ 3 ] Blocker [ 1 ]
        Romain Grécourt made changes -
        Fix Version/s 4.1 [ 16387 ]
        Fix Version/s 4.0.1 [ 16061 ]
        Romain Grécourt made changes -
        Fix Version/s 4.1.1 [ 17211 ]
        Fix Version/s 4.1 [ 16387 ]

          People

          • Assignee:
            martin.mares
            Reporter:
            Joe Di Pol
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated: