01: /*
02: * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright
03: * notice. All rights reserved.
04: */
05: package com.tc.objectserver.persistence.api;
06:
07: import com.tc.net.groups.NodeID;
08: import com.tc.object.gtx.GlobalTransactionID;
09: import com.tc.object.tx.ServerTransactionID;
10: import com.tc.objectserver.gtx.GlobalTransactionDescriptor;
11:
12: import java.util.Collection;
13: import java.util.Set;
14:
15: public interface TransactionStore {
16:
17: public void commitTransactionDescriptor(
18: PersistenceTransaction transaction,
19: ServerTransactionID stxID);
20:
21: public GlobalTransactionDescriptor getTransactionDescriptor(
22: ServerTransactionID serverTransactionID);
23:
24: public GlobalTransactionDescriptor getOrCreateTransactionDescriptor(
25: ServerTransactionID serverTransactionID);
26:
27: public GlobalTransactionID getLeastGlobalTransactionID();
28:
29: /**
30: * This method clears the server transaction ids less than the low water mark, for that particular node.
31: */
32: public void clearCommitedTransactionsBelowLowWaterMark(
33: PersistenceTransaction transaction,
34: ServerTransactionID lowWaterMark);
35:
36: /**
37: * This is used by the passive to clear completed Transaction ids.
38: */
39: public void clearCommitedTransactionsBelowLowWaterMark(
40: PersistenceTransaction tx,
41: GlobalTransactionID lowGlobalTransactionIDWatermark);
42:
43: public void shutdownNode(PersistenceTransaction transaction,
44: NodeID nid);
45:
46: public void shutdownAllClientsExcept(PersistenceTransaction tx,
47: Set cids);
48:
49: public void createGlobalTransactionDescIfNeeded(
50: ServerTransactionID stxnID,
51: GlobalTransactionID globalTransactionID);
52:
53: public void commitAllTransactionDescriptor(
54: PersistenceTransaction persistenceTransaction,
55: Collection stxIDs);
56:
57: }
|