[jboss-user] [JBossWS] - Re: Deployed service statistics

abdujaparov do-not-reply at jboss.com
Wed Oct 24 14:04:28 EDT 2007


Hi Alessio,
Let's see if I understand:

Could I write a web service method like this?

  | @WebMethod
  | public java.util.Date getStartDate(){
  | 		// get SPI provider and endpoint registry
  | 		SPIProvider spiProvider = SPIProviderResolver.getInstance()
  | 		        .getProvider();
  | 		EndpointRegistry epRegistry = spiProvider.getSPI(
  | 		        EndpointRegistryFactory.class).getEndpointRegistry();
  | 
  | 		// loop over all endpoints
  | 		Set<ObjectName> objectNames = epRegistry.getEndpoints();
  | 		for (ObjectName objectName : objectNames) {
  | 
  | 		    // get the endpoint by using its name
  | 		    Endpoint endpoint = epRegistry.getEndpoint(objectName);
  | 		    
  | 		    
  | 		    EndpointMetrics epm = endpoint.getEndpointMetrics();
  | 		    return epm.getStartTime();
  | }
  | 


In this simple way?

Thanks, bye bye.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4098470#4098470

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4098470



More information about the jboss-user mailing list