public class TCCResourceManager extends AbstractResourceManager
LOGGER| Constructor and Description |
|---|
TCCResourceManager()
Instantiates a new Tcc resource manager.
|
| Modifier and Type | Method and Description |
|---|---|
BranchStatus |
branchCommit(BranchType branchType,
String xid,
long branchId,
String resourceId,
String applicationData)
TCC branch commit
|
BranchStatus |
branchRollback(BranchType branchType,
String xid,
long branchId,
String resourceId,
String applicationData)
TCC branch rollback
|
BranchType |
getBranchType()
Get the BranchType.
|
Map<String,Resource> |
getManagedResources()
Get all resources managed by this manager.
|
void |
registerResource(Resource resource)
registry TCC resource
|
branchRegister, branchReport, lockQuery, unregisterResourcepublic TCCResourceManager()
public void registerResource(Resource resource)
registerResource in interface ResourceManagerregisterResource in class AbstractResourceManagerresource - The resource to be managed.public Map<String,Resource> getManagedResources()
ResourceManagerpublic BranchStatus branchCommit(BranchType branchType, String xid, long branchId, String resourceId, String applicationData) throws TransactionException
branchType - xid - Transaction id.branchId - Branch id.resourceId - Resource id.applicationData - Application data bind with this branch.TransactionException - TransactionExceptionpublic BranchStatus branchRollback(BranchType branchType, String xid, long branchId, String resourceId, String applicationData) throws TransactionException
branchType - the branch typexid - Transaction id.branchId - Branch id.resourceId - Resource id.applicationData - Application data bind with this branch.TransactionException - TransactionExceptionpublic BranchType getBranchType()
ResourceManagerCopyright © 2023 Seata. All rights reserved.