Examples of Procedure


Examples of org.apache.hadoop.hbase.procedure.Procedure

    try {
      handler.rethrowExceptionIfFailed();
    } catch (ForeignException e) {
      // Give some procedure info on an exception.
      String status;
      Procedure p = coordinator.getProcedure(expected.getName());
      if (p != null) {
        status = p.getStatus();
      } else {
        status = expected.getName() + " not found in proclist " + coordinator.getProcedureNames();
      }
      throw new HBaseSnapshotException("Snapshot " + ssString +  " had an error.  " + status, e,
          expected);
View Full Code Here

Examples of org.apache.hadoop.hbase.procedure.Procedure

        regionServers.add(region.getSecond().toString());
      }
    }

    // start the snapshot on the RS
    Procedure proc = coordinator.startProcedure(this.monitor, this.snapshot.getName(),
      this.snapshot.toByteArray(), Lists.newArrayList(regionServers));
    if (proc == null) {
      String msg = "Failed to submit distributed procedure for snapshot '"
          + snapshot.getName() + "'";
      LOG.error(msg);
      throw new HBaseSnapshotException(msg);
    }

    try {
      // wait for the snapshot to complete.  A timer thread is kicked off that should cancel this
      // if it takes too long.
      proc.waitForCompleted();
      LOG.info("Done waiting - online snapshot for " + this.snapshot.getName());

      // Take the offline regions as disabled
      Path snapshotDir = SnapshotDescriptionUtils.getWorkingSnapshotDir(snapshot, rootDir);
      for (Pair<HRegionInfo, ServerName> region : regions) {
View Full Code Here

Examples of org.apache.hadoop.hbase.procedure.Procedure

    try {
      handler.rethrowExceptionIfFailed();
    } catch (ForeignException e) {
      // Give some procedure info on an exception.
      String status;
      Procedure p = coordinator.getProcedure(expected.getName());
      if (p != null) {
        status = p.getStatus();
      } else {
        status = expected.getName() + " not found in proclist " + coordinator.getProcedureNames();
      }
      throw new HBaseSnapshotException("Snapshot " + ssString +  " had an error.  " + status, e,
          expected);
View Full Code Here

Examples of org.h2.engine.Procedure

    }

    private Prepared parseExecute() {
        ExecuteProcedure command = new ExecuteProcedure(session);
        String procedureName = readAliasIdentifier();
        Procedure p = session.getProcedure(procedureName);
        if (p == null) {
            throw DbException.get(ErrorCode.FUNCTION_ALIAS_NOT_FOUND_1, procedureName);
        }
        command.setProcedure(p);
        if (readIf("(")) {
View Full Code Here

Examples of org.jboss.mbui.gui.behaviour.Procedure


    @Test
    public void testProcedureEquality()
    {
        Procedure proc1 = new TestProcedure(QName.valueOf("foo.bar:proc")) {};
        Procedure proc2 = new TestProcedure(QName.valueOf("foo.bar:proc")) {};
        Procedure proc3 = new TestProcedure(QName.valueOf("foo.bar:proc"), QName.valueOf("some:origin")) {};
        Procedure proc4 = new TestProcedure(QName.valueOf("foo.bar:proc2")) {};
        Procedure proc5 = new TestProcedure(QName.valueOf("foo.bar:proc"), QName.valueOf("some:origin")) {};

        assertEquals(proc1, proc2);
        assertFalse(proc2.equals(proc3));
        assertFalse(proc1.equals(proc4));
        assertEquals(proc3, proc5);
View Full Code Here

Examples of org.jrest4guice.persistence.ibatis.annotations.Procedure

  private static void processStatement(Class<?> clazz,
      StringBuffer statementSb) {
    Method[] methods = clazz.getDeclaredMethods();
    Statement statement;
    Procedure procedure;
    Select select;
    Update update;
    Insert insert;
    Delete delete;
    for (Method method : methods) {
      if (method.isAnnotationPresent(Statement.class)) {
        statement = method.getAnnotation(Statement.class);
        generateMethodSqlMapping(statementSb, "statement", method,
            statement.id(), statement.parameterMap(), statement
                .parameterClass(), statement.resltMap(),
            statement.resltClass(), statement.sql(), statement
                .cacheModel(), statement.xmlResultName());
      } else if (method.isAnnotationPresent(Procedure.class)) {
        procedure = method.getAnnotation(Procedure.class);
        generateMethodSqlMapping(statementSb, "procedure", method,
            procedure.id(), procedure.parameterMap(), procedure
                .parameterClass(), procedure.resltMap(),
            procedure.resltClass(), procedure.sql(), null,
            procedure.xmlResultName());
      } else if (method.isAnnotationPresent(Select.class)) {
        select = method.getAnnotation(Select.class);
        generateMethodSqlMapping(statementSb, "select", method, select
            .id(), select.parameterMap(), select.parameterClass(),
            select.resltMap(), select.resltClass(), select.sql(),
View Full Code Here

Examples of org.lealone.dbobject.Procedure

    }

    private Prepared parseExecute() {
        ExecuteProcedure command = new ExecuteProcedure(session);
        String procedureName = readAliasIdentifier();
        Procedure p = session.getProcedure(procedureName);
        if (p == null) {
            throw DbException.get(ErrorCode.FUNCTION_ALIAS_NOT_FOUND_1, procedureName);
        }
        command.setProcedure(p);
        if (readIf("(")) {
View Full Code Here

Examples of org.lealone.dbobject.Procedure

    public void checkParameters() {
        // no not check parameters
    }

    public int update() {
        Procedure proc = new Procedure(procedureName, prepared);
        prepared.setParameterList(parameters);
        prepared.setPrepareAlways(prepareAlways);
        prepared.prepare();
        session.addProcedure(proc);
        return 0;
View Full Code Here

Examples of org.nlogo.nvm.Procedure

  public Procedure compileForRun(String source, org.nlogo.nvm.Context context,
                                 boolean reporter)
      throws CompilerException {
    String key = source + "@" + context.activation.procedure.args.size() +
        "@" + context.agentBit;
    Procedure proc = codeBits.get(key);
    if (proc == null) {
      proc = evaluator.compileForRun(source, context, reporter);
      codeBits.put(key, proc);
    }
    return proc;
View Full Code Here

Examples of org.plugtree.training.billing.model.Procedure

    private Procedure createProcedure(BaseDateTime date, String code, double quantity) {
        return this.createProcedure(new Date(date.getMillis()), code, quantity);
    }

    private Procedure createProcedure(Date date, String code, double quantity) {
        Procedure p = new Procedure();
        p.setCode(code);
        p.setQuantity(quantity);
        p.setDate(date);

        return p;
    }
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.