Examples of Commit()


Examples of org.apache.geronimo.transaction.context.ContainerTransactionContext.commit()

        assertTrue("Expected the same ManagedConnectionInfo in the TransactionContext as was returned",
                connectionInfo1.getManagedConnectionInfo() == getSharedManagedConnectionInfo(transactionContext));
        //commit, see if connection returned.
        //we didn't create any handles, so the "ManagedConnection" should be returned.
        assertTrue("Expected TransactionContext to report active", transactionContext.isActive());
        transactionContext.commit();
        assertTrue("Expected connection to be returned", returnedConnectionInfo != null);
        assertTrue("Expected TransactionContext to report inactive", !transactionContext.isActive());

    }

Examples of org.apache.geronimo.transaction.context.TransactionContext.commit()

                    if (newTransactionContext != transactionContextManager.getContext()) {
                        transactionContextManager.getContext().rollback();
                        newTransactionContext.rollback();
                        throw new RuntimeException("WRONG EXCEPTION! returned from servlet call with wrong tx context");
                    }
                    newTransactionContext.commit();

                } else {
                    if (oldTransactionContext != transactionContextManager.getContext()) {
                        if (transactionContextManager.getContext() != null) {
                            transactionContextManager.getContext().rollback();

Examples of org.apache.geronimo.transaction.manager.TransactionManagerImpl.commit()

        started = false;
        transactionEnlistingInterceptor.returnConnection(connectionInfo, ConnectionReturnAction.RETURN_HANDLE);
        assertTrue("Expected not started", !started);
        assertTrue("Expected ended", ended);
        assertTrue("Expected returned", returned);
        transactionManager.commit();
        assertTrue("Expected committed", committed);
    }

    //ConnectionInterceptor
    public void getConnection(ConnectionInfo connectionInfo) throws ResourceException {

Examples of org.apache.hadoop.hbase.HTable.commit()

    long id = t.startUpdate(row);
    info.setOffline(onlineOffline);
    t.put(id, HConstants.COL_REGIONINFO, Writables.getBytes(info));
    t.delete(id, HConstants.COL_SERVER);
    t.delete(id, HConstants.COL_STARTCODE);
    t.commit(id);
  }
}

Examples of org.apache.hadoop.hbase.client.HTable.commit()

    BatchUpdate b = new BatchUpdate(row);
    info.setOffline(onlineOffline);
    b.put(HConstants.COL_REGIONINFO, Writables.getBytes(info));
    b.delete(HConstants.COL_SERVER);
    b.delete(HConstants.COL_STARTCODE);
    t.commit(b);
  }
 
  /**
   * Offline version of the online TableOperation,
   * org.apache.hadoop.hbase.master.AddColumn.
 

Examples of org.apache.hadoop.hbase.ipc.TransactionalRegionInterface.commit()

      for (HRegionLocation location : transactionState
          .getParticipatingRegions()) {
        TransactionalRegionInterface transactionalRegionServer = (TransactionalRegionInterface) connection
            .getHRegionConnection(location.getServerAddress());
        transactionalRegionServer.commit(location.getRegionInfo()
            .getRegionName(), transactionState.getTransactionId());
      }
    } catch (Exception e) {
      LOG.debug("Commit of transaction [" + transactionState.getTransactionId()
          + "] was unsucsessful", e);

Examples of org.apache.harmony.auth.module.JndiLoginModule.commit()

        status.put("javax.security.auth.login.name", "tester");
        status.put("javax.security.auth.login.password", "testerPass");
        module.initialize(subject, new MockCallbackHandler(), status, options);
        try {
            module.login();
            module.commit();
        } catch (LoginException e) {
            fail("Login failed");
        } finally {
            module.logout();
        }

Examples of org.apache.harmony.auth.module.KeyStoreLoginModule.commit()

        KeyStoreLoginModule module = new KeyStoreLoginModule();
        Subject subject = new Subject();
        module.initialize(subject, null, null, options);
        try {
            assertTrue("Login should be successful", module.login());
            module.commit();
        } catch (LoginException e) {
            e.printStackTrace();
            fail("Login shouldn't fail");
        }
        Set<Principal> principals = subject.getPrincipals();

Examples of org.apache.harmony.auth.module.LdapLoginModule.commit()

        options.remove("useFirstPass");
        options.put("tryFirstPass", "true");
        module.initialize(subject, new MockCallbackHandler(), status, options);
        try {
            module.login();
            module.commit();
        }
        catch(LoginException e){
            fail("Login should be failed");
        }
        finally{

Examples of org.apache.hcatalog.data.transfer.HCatWriter.commit()

        WriteEntity.Builder builder = new WriteEntity.Builder();
        WriteEntity entity = builder.withTable("mytbl").build();
        HCatWriter writer = DataTransferFactory.getHCatWriter(entity, config);
        if (status) {
            writer.commit(context);
        } else {
            writer.abort(context);
        }
    }
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.