@Override
  protected void startListeningForService(AxisService service) throws AxisFault {
    E endpoint = createEndpoint(service);
    endpoint.setListener(this);
    endpoint.setService(service);
    endpoint.setContentType(
        ParamUtils.getRequiredParam(service, "transport." + getTransportName() + ".contentType"));
    endpoint.setMetrics(metrics);

    try {
      dispatcher.addEndpoint(endpoint);
    } catch (IOException ex) {
      throw new AxisFault(
          "Unable to listen on endpoint " + endpoint.getEndpointReference(defaultIp), ex);
    }
    if (log.isDebugEnabled()) {
      log.debug(
          "Started listening on endpoint "
              + endpoint.getEndpointReference(defaultIp)
              + " [contentType="
              + endpoint.getContentType()
              + "; service="
              + service.getName()
              + "]");
    }
    endpoints.put(service.getName(), endpoint);
  }
  public EndpointReference[] getEPRsForService(String serviceName, String ip) throws AxisFault {

    // strip out the endpoint name if present
    if (serviceName.indexOf('.') != -1) {
      serviceName = serviceName.substring(0, serviceName.indexOf('.'));
    }

    E endpoint = endpoints.get(serviceName);
    if (endpoint == null) {
      return null;
    } else {
      return new EndpointReference[] {endpoint.getEndpointReference(ip == null ? defaultIp : ip)};
    }
  }