Examples of handle()


Examples of org.apache.clerezza.triaxrs.JaxRsHandler.handle()

    request.setMessageBody(messageBody);

    request.setMethod(Method.POST);

    handler.handle(request, response);

    Assert.assertEquals(queryParam, value);
    Assert.assertEquals(bodyString, body);
  }
View Full Code Here

Examples of org.apache.cocoon.Engine.handle()

            // Pass in the real response object.  If I wanted to
            //   filter the output further, I could easily construct
            //   a CocoonServletResponse object and pass that in,
            //   and pull the output out of it.
            out.println("Generate some content... <br />");
            cocoonEngine.handle(myReq, res);
           
        } catch (Exception e) {
            out.println("Error: " + e.getMessage());
        }
       
View Full Code Here

Examples of org.apache.commons.dbutils.ResultSetHandler.handle()

    super(name);
  }

  public void testHandle() throws SQLException {
    ResultSetHandler h = new BeanHandler(TestBean.class);
        TestBean results = (TestBean) h.handle(this.rs);
       
    assertNotNull(results);
    assertEquals("1", results.getOne());
    assertEquals("2", results.getTwo());
    assertEquals("3", results.getThree());
View Full Code Here

Examples of org.apache.felix.httplite.osgi.ServiceRegistrationHandler.handle()

                    ServiceRegistrationHandler processor = m_resolver.getProcessor(
                        request, response, request.getRequestURI());

                    if (processor != null)
                    {
                        processor.handle(close);

                        m_logger.log(Logger.LOG_DEBUG, "Processed " + request.toString());

                        // TODO: Adding next line to make test cases pass, but not sure if it is correct
                        // and needs further investigation.
View Full Code Here

Examples of org.apache.hadoop.hbase.security.HBaseSaslRpcClient.SaslClientCallbackHandler.handle()

    final RealmChoiceCallback realmChoiceCallback = mock(RealmChoiceCallback.class);

    Callback[] callbackArray = {nameCallback, passwordCallback,
        realmCallback, realmChoiceCallback};
    final SaslClientCallbackHandler saslClCallbackHandler = new SaslClientCallbackHandler(token);
    saslClCallbackHandler.handle(callbackArray);
    verify(nameCallback).setName(anyString());
    verify(realmCallback).setText(anyString());
    verify(passwordCallback).setPassword(any(char[].class));
  }
View Full Code Here

Examples of org.apache.hadoop.mapred.MapTaskAttemptImpl.handle()

    ContainerId contId = ContainerId.newInstance(appAttemptId, 3);
    Container container = mock(Container.class);
    when(container.getId()).thenReturn(contId);
    when(container.getNodeId()).thenReturn(nid);

    taImpl.handle(new TaskAttemptEvent(attemptId,
        TaskAttemptEventType.TA_SCHEDULE));
    taImpl.handle(new TaskAttemptContainerAssignedEvent(attemptId,
        container, mock(Map.class)));
    taImpl.handle(new TaskAttemptEvent(attemptId,
        TaskAttemptEventType.TA_KILL));
View Full Code Here

Examples of org.apache.hadoop.mapreduce.v2.app.job.impl.MapTaskImpl.handle()

    TaskInfo mockTaskInfo = mock(TaskInfo.class);
    when(mockTaskInfo.getTaskStatus()).thenReturn("SUCCEEDED");
    when(mockTaskInfo.getTaskId()).thenReturn(taskID);
    when(mockTaskInfo.getAllTaskAttempts()).thenReturn(mockTaskAttempts);

    recoverMapTask.handle(
        new TaskRecoverEvent(taskId, mockTaskInfo,mockCommitter, true));

    ArgumentCaptor<Event> arg = ArgumentCaptor.forClass(Event.class);
    verify(mockEventHandler,atLeast(1)).handle(
        (org.apache.hadoop.yarn.event.Event) arg.capture());
View Full Code Here

Examples of org.apache.hadoop.yarn.event.EventHandler.handle()

    metrics.releaseContainer(this.resource);

    // Inform the application
    @SuppressWarnings("rawtypes")
    EventHandler eventHandler = dispatcher.getEventHandler();
    eventHandler.handle(new ApplicationContainerFinishedEvent(containerId));
    // Remove the container from the resource-monitor
    eventHandler.handle(new ContainerStopMonitoringEvent(containerId));
    // Tell the logService too
    eventHandler.handle(new LogHandlerContainerFinishedEvent(
      containerId, exitCode));
View Full Code Here

Examples of org.apache.hadoop.yarn.server.nodemanager.containermanager.AuxServices.handle()

    buf.putChar('A');
    buf.putInt(65);
    buf.flip();
    AuxServicesEvent event = new AuxServicesEvent(
        AuxServicesEventType.APPLICATION_INIT, "user0", appId, "Asrv", buf);
    aux.handle(event);
    appId.setId(66);
    event = new AuxServicesEvent(
        AuxServicesEventType.APPLICATION_STOP, "user0", appId, "Bsrv", null);
    // verify all services got the stop event
    aux.handle(event);
View Full Code Here

Examples of org.apache.hadoop.yarn.server.nodemanager.containermanager.application.Application.handle()

    public void handle(ApplicationEvent event) {
      Application app =
          ContainerManagerImpl.this.context.getApplications().get(
              event.getApplicationID());
      if (app != null) {
        app.handle(event);
      } else {
        LOG.warn("Event " + event + " sent to absent application "
            + event.getApplicationID());
      }
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.