public static Connection fromHostList(String... brokers) {
    return fromHostList(Arrays.asList(brokers), getDefault());
  }
@Test
  public void testBrokerListWithHeaders() {
    // Create the connection
    List<String> brokers = ImmutableList.of("127.0.0.1:1234", "localhost:2345");

    Map<String, String> headers = ImmutableMap.of("Caller", "curl");

    JsonAsyncHttpPinotClientTransportFactory factory = new JsonAsyncHttpPinotClientTransportFactory();
    factory.setHeaders(headers);

    Connection connection = ConnectionFactory.fromHostList(brokers, factory.buildTransport());

    // Check that the broker list has the right length and has the same servers
    Assert.assertEquals(connection.getBrokerList(), brokers);
  }