Hide
Step 1. Restart a JBoss server or host;
Step 2. During the upstart of the server/host, run the command:
or equivalent for your environment. Notice that the response will NOT be in JSON-format, it will be in the DMR format.
The following output was generated following the above steps:
—
However, when the server is completely restarted, the json ouput works properly:
Show
Step 1. Restart a JBoss server or host;
Step 2. During the upstart of the server/host, run the command:
/opt/jboss/jboss7_2/jboss-eap-7.2/bin/jboss-cli.sh --connect --controller=localhost:9990 --command="/host=*/server=*/deployment=*/:read-resource(recursive=false,include-runtime=true)" --output-json
or equivalent for your environment. Notice that the response will NOT be in JSON-format, it will be in the DMR format.
The following output was generated following the above steps:
[tosorio@localhost bin]$ ./jboss-cli.sh --connect --controller=localhost:9990 --command="/host=*/server='*'/deployment=*/:read-resource(recursive=false,include-runtime=true)" --output-json
{
"outcome" => "failed",
"result" => [{
"address" => [
("host" => "master"),
("server" => "server-two"),
("deployment" => "fabrica.war")
],
"outcome" => "failed",
"result" => {
"content" => [{
"hash" => bytes {
0x73, 0xa2, 0x23, 0xaf, 0x5b, 0xb3, 0x3f, 0xc0,
0xaf, 0x84, 0x56, 0x33, 0x99, 0xfb, 0x6c, 0xa6,
0xd1, 0xf1, 0x58, 0x40
},
"archive" => undefined
(...)
"rolled-back" => true
—
However, when the server is completely restarted, the json ouput works properly: