Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Alternatively, the MetricsFeature could be supplied directly to JAX-WS endpoint, for example:

EndpointImpl endpoint = new EndpointImpl(bus, new HelloPortImpl(), null, null, new WebServiceFeature[]{
    new MetricsFeature(metricsProvider)
});

Client

The client integration is no different from the server and uses the same MetricsFeature feature.

Code Block
final Bus bus = ...; /* MetricRegistry instance is taken from Bus instance */
final MetricsProvider metricsProvider = new CodahaleMetricsProvider(bus);

final JaxWsClientFactoryBean factory = new JaxWsClientFactoryBean();
factory.setFeatures(Arrays.asList(new MetricsFeature(new CodahaleMetricsProvider(bus))));
...

Integration with JAX-RS

Server

...