public class SagaResourceManager extends AbstractResourceManager
| Constructor and Description |
|---|
SagaResourceManager()
Instantiates a new saga resource manager.
|
| Modifier and Type | Method and Description |
|---|---|
BranchStatus |
branchCommit(BranchType branchType,
String xid,
long branchId,
String resourceId,
String applicationData)
SAGA branch commit
|
BranchStatus |
branchRollback(BranchType branchType,
String xid,
long branchId,
String resourceId,
String applicationData)
SAGA branch rollback
|
BranchType |
getBranchType()
Get the BranchType.
|
Map<String,Resource> |
getManagedResources()
Get all resources managed by this manager.
|
void |
registerResource(Resource resource)
registry saga resource
|
branchRegister, branchReport, lockQuery, unregisterResourcepublic SagaResourceManager()
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 - the branch typexid - Transaction id.branchId - Branch id.resourceId - Resource id.applicationData - Application data bind with this branch.TransactionException - the transaction exceptionpublic 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 - the transaction exceptionpublic BranchType getBranchType()
ResourceManagerCopyright © 2023 Seata. All rights reserved.