I am using Glassfish 3.1.2.2. I have deployed Glassfish to localhost. I have enabled the monitoring service and set the log level to HIGH for all components.
I should be able to use the view the server logs at a REST end point at http://host:port/management/domain/view-log
according to the official documentation, but I get a generic response:
$ curl -H "Accept: application/json" http://localhost:4848/monitoring/domain/view-log
{"message":"","command":"Monitoring Data","exit_code":"SUCCESS"}
I get a proper response at this address, so I think my configuration is mostly correct:
$ curl -H "Accept: application/json" http://localhost:4848/monitoring/domain/
{
"message":"",
"command":"Monitoring Data",
"exit_code":"SUCCESS",
"extraProperties":{
"entity":{
},
"childResources":{
"server":"http:\/\/localhost:4848\/monitoring\/domain\/server"
}
}
}
Note that the generic response I received is sent for any invalid endpoint under domain
:
$ curl -H "Accept: application/json" http://localhost:4848/monitoring/domain/jklnjkn
{"message":"","command":"Monitoring Data","exit_code":"SUCCESS"}
How can I access the Glassfish 3.1.2.2 server logs using the monitoring REST end point?