0 Replies Latest reply: May 25, 2012 10:05 AM by Thomas H RSS

    jboss.cli data format

    Thomas H Newbie

      Hi,

      I have a simple question: What data format is jboss-cli returning?

      At first glance it looks like JSON, but instead of "name":"value" pairs it returns "name"=>"value" pairs.

       

      Example output:

       

      {

          "outcome" => "success",

          "result" => {

              "name" => "Code_Cache",

              "type" => "NON_HEAP",

              "valid" => true,

              "memory-manager-names" => ["CodeCacheManager"],

              "usage-threshold-supported" => true,

              "collection-usage-threshold-supported" => false,

              "usage-threshold" => 0L,

              "collection-usage-threshold" => undefined,

              "usage" => {

                  "init" => 2555904L,

                  "used" => 90153344L,

                  "committed" => 90963968L,

                  "max" => 100663296L

              },

              "peak-usage" => {

                  "init" => 2555904L,

                  "used" => 90161408L,

                  "committed" => 90963968L,

                  "max" => 100663296L

              },

              "usage-threshold-exceeded" => true,

              "usage-threshold-count" => 0L,

              "collection-usage-threshold-exceeded" => undefined,

              "collection-usage-threshold-count" => undefined,

              "collection-usage" => undefined

          }

      }

       

       

      I am asking because I want to parse jboss.cli output in a perl script by using the JSON module. But Perl throws an error:

      Thread 3 terminated abnormally: ':' expected, at character offset 16 (before "=> "success",\n    "...") at

       

      Regards

      Thomas