3.4.5. 查看运行时信息
每一 Web 服务端点通过提供端点实施的部署公开。每个端点可以作为部署资源查询。每个 Web 服务端点指定一个 Web 上下文和 WSDL URL。您可以使用管理 CLI 或管理控制台访问这些运行时信息。
以下管理 CLI 命令显示了 jaxws-samples-handlerchain.war 部署中的 TestService 端点的详细信息。
/deployment="jaxws-samples-handlerchain.war"/subsystem=webservices/endpoint="jaxws-samples-handlerchain:TestService":read-resource(include-runtime=true)
{
"outcome" => "success",
"result" => {
"average-processing-time" => 23L,
"class" => "org.jboss.test.ws.jaxws.samples.handlerchain.EndpointImpl",
"context" => "jaxws-samples-handlerchain",
"fault-count" => 0L,
"max-processing-time" => 23L,
"min-processing-time" => 23L,
"name" => "TestService",
"request-count" => 1L,
"response-count" => 1L,
"total-processing-time" => 23L,
"type" => "JAXWS_JSE",
"wsdl-url" => "http://localhost:8080/jaxws-samples-handlerchain?wsdl"
}
}
注意
在 read 标志,会在结果中返回运行时统计信息。但是,默认禁用 Web 服务端点的收集。您可以使用以下管理 CLI 命令为 Web 服务端点启用统计信息。
-resource 操作中使用 include-runtime=true
/subsystem=webservices:write-attribute(name=statistics-enabled,value=true)
您还可以从管理控制台的 Runtime 选项卡中查看 Web 服务端点的运行时信息,方法是选择适用的服务器,选择 Web 服务,然后选择端点。