Package org.apache.storm.loadgen

# Class HttpForwardingMetricsServer

java.lang.Object
org.apache.storm.loadgen.HttpForwardingMetricsServer

Direct Known Subclasses:
  `LoadMetricsServer`

public abstract class HttpForwardingMetricsServer extends Object
A server that can listen for metrics from the HttpForwardingMetricsConsumer.

- ## Constructor Summary

  Constructors
  Constructor
  Description
  `HttpForwardingMetricsServer(Map<String,Object> conf)`
  Constructor.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `int`
  `getPort()`
  `String`
  `getUrl()`
  `abstract void`
  `handle(IMetricsConsumer.TaskInfo taskInfo, Collection<IMetricsConsumer.DataPoint> dataPoints, String topologyId)`
  `void`
  `serve()`
  `void`
  `serve(Integer port)`
  Start the server.

  ### Methods inherited from class java.lang.Object

  `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### HttpForwardingMetricsServer

    public HttpForwardingMetricsServer(Map<String,Object> conf)
    Constructor.
    Parameters:
      `conf` - the configuration for storm.

- ## Method Details

  - ### handle

    public abstract void handle(IMetricsConsumer.TaskInfo taskInfo, Collection<IMetricsConsumer.DataPoint> dataPoints, String topologyId)

  - ### serve

    public void serve(Integer port)
    Start the server.
    Parameters:
      `port` - the port it shuld listen on, or null/<= 0 to pick a free ephemeral port.

  - ### serve

    public void serve()

  - ### getPort

    public int getPort()

  - ### getUrl

    public String getUrl()