Package org.apache.avro.ipc

Examples of org.apache.avro.ipc.HttpTransceiver


        .get(new Utf8("doubleAttr")) == 0.5);
  }

  @Test
  public void testGetReportByName() throws IOException {
    transport = new HttpTransceiver(url);
    try {
      this.avroClient = (AvroFlumeReportServer) SpecificRequestor.getClient(
          AvroFlumeReportServer.class, transport);
    } catch (Exception e) {
      throw new IOException("Failed to open AvroReportServer at " + PORT
View Full Code Here


   */
  AvroMasterRPC(String masterHost, int masterPort) throws IOException {
    this.masterHostname = masterHost;
    this.masterPort = masterPort;
    URL url = new URL("http", masterHostname, masterPort, "/");
    trans = new HttpTransceiver(url);
    this.masterClient = (AvroFlumeClientServer) SpecificRequestor.getClient(
        AvroFlumeClientServer.class, trans);
    LOG.info("Connected to master at " + masterHostname + ":" + masterPort);
  }
View Full Code Here

  public AdminRPCAvro(String masterHost, int masterPort) throws IOException {
    this.masterHostname = masterHost;
    this.masterPort = masterPort;
    URL url = new URL("http", masterHostname, this.masterPort, "/");
    trans = new HttpTransceiver(url);
    this.masterClient = (FlumeMasterAdminServerAvro) SpecificRequestor
        .getClient(FlumeMasterAdminServerAvro.class, trans);
    LOG.info("Connected to master at " + masterHostname + ":" + masterPort);
  }
View Full Code Here

   */
  @Override
  public void open() throws IOException {

    URL url = new URL("http", host, port, "/");
    Transceiver http = new HttpTransceiver(url);
    transport = new AccountingTransceiver(http);
    try {
      this.avroClient = (FlumeEventAvroServer) SpecificRequestor.getClient(
          FlumeEventAvroServer.class, transport);
    } catch (Exception e) {
View Full Code Here

    }
  }
 
  @Test(expected = Exception.class)
  public void testConnectionRefusedOneWay() throws IOException {
    Transceiver client = new HttpTransceiver(new URL("http://localhost:4444"));
    SpecificRequestor req = new SpecificRequestor(Simple.class, client);
    addRpcPlugins(req);
    Simple proxy = SpecificRequestor.getClient(Simple.class, (SpecificRequestor)req);
    proxy.ack();
  }
View Full Code Here

  }

  @Test
  public void testGetAllReports() throws IOException {

    transport = new HttpTransceiver(url);
    try {
      this.avroClient = (AvroFlumeReportServer) SpecificRequestor.getClient(
          AvroFlumeReportServer.class, transport);
    } catch (Exception e) {
      throw new IOException("Failed to open AvroReportServer at " + PORT
View Full Code Here

        .get(new Utf8("doubleAttr")) == 0.5);
  }

  @Test
  public void testGetReportByName() throws IOException {
    transport = new HttpTransceiver(url);
    try {
      this.avroClient = (AvroFlumeReportServer) SpecificRequestor.getClient(
          AvroFlumeReportServer.class, transport);
    } catch (Exception e) {
      throw new IOException("Failed to open AvroReportServer at " + PORT
View Full Code Here

   */
  @Override
  public void open() throws IOException {

    URL url = new URL("http", host, port, "/");
    transport = new HttpTransceiver(url);
    try {
      this.avroClient = (FlumeEventAvroServer) SpecificRequestor.getClient(
          FlumeEventAvroServer.class, transport);
    } catch (Exception e) {
      throw new IOException("Failed to open Avro event sink at " + host + ":"
View Full Code Here

TOP

Related Classes of org.apache.avro.ipc.HttpTransceiver

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.