Package bitronix.tm

Examples of bitronix.tm.BitronixXid


        class LocalVisitor implements XAResourceHolderStateVisitor {
            private XAResourceHolderState latestEnlistedHolder;
            public boolean visit(XAResourceHolderState xaResourceHolderState) {
                if (xaResourceHolderState != null && xaResourceHolderState.getXid() != null) {
                    BitronixXid bitronixXid = xaResourceHolderState.getXid();
                    Uid resourceGtrid = bitronixXid.getGlobalTransactionIdUid();
                    Uid currentTransactionGtrid = currentTransaction.getResourceManager().getGtrid();

                    if (currentTransactionGtrid.equals(resourceGtrid)) {
                        latestEnlistedHolder = xaResourceHolderState;
                    }
View Full Code Here


        if (alreadyEnlistedHolder != null) {
            if (log.isDebugEnabled()) { log.debug("resource already enlisted but has been ended eligible for join: " + alreadyEnlistedHolder); }
            toBeJoinedHolderState = getManagedResourceWithSameRM(xaResourceHolderState);
        }

        BitronixXid xid;
        int flag;

        if (toBeJoinedHolderState != null) {
            if (log.isDebugEnabled()) { log.debug("joining " + xaResourceHolderState + " with " + toBeJoinedHolderState); }
            xid = toBeJoinedHolderState.getXid();
View Full Code Here

     * Generate a XID with the specified globalTransactionId.
     * @param gtrid the GTRID to use to generate the Xid.
     * @return the generated Xid.
     */
    public static BitronixXid generateXid(Uid gtrid) {
        return new BitronixXid(gtrid, generateUid());
    }
View Full Code Here

                if (log.isDebugEnabled()) log.debug("skipping non-bitronix XID " + xid + "(format ID: " + xid.getFormatId() +
                     " GTRID: " + new Uid(xid.getGlobalTransactionId()) + "BQUAL: " + new Uid(xid.getBranchQualifier()) + ")");
                continue;
            }

            BitronixXid bitronixXid = new BitronixXid(xid);

            if (currentNodeOnly) {
                if (log.isDebugEnabled()) { log.debug("recovering XIDs generated by this node only - recovered XIDs' GTRID must contain this JVM uniqueId"); }
                byte[] extractedServerId = bitronixXid.getGlobalTransactionIdUid().extractServerId();
                byte[] jvmUniqueId = TransactionManagerServices.getConfiguration().buildServerIdArray();

                if (extractedServerId == null) {
                    log.error("skipping XID " + bitronixXid + " as its GTRID's serverId is null. It looks like the disk journal is corrupted!");
                    continue;
View Full Code Here

TOP

Related Classes of bitronix.tm.BitronixXid

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.