IBM.WebSphere.Caching NamespaceIBM WebSphere™ eXtreme Scale Client for .NET API Specification
IBM WebSphere™ eXtreme Scale Client for .NET Release 8.6.0.0 API Specification

The IBM.WebSphere.Caching namespace is the parent namespace for the the WebSphere eXtreme Scale C# client data access application programming interfaces.

The primary entry point for interacting with the data grid is the GridManagerFactory, which provides access to the IGridManager and IGrid interfaces.

The IGridManager interface provides methods to connect and disconnect from a catalog service domain. It also provides access to IGrid instances from the catalog service domain connections.

The IGrid interface allows clients to interact with a named data grid using various map interfaces, such as the IGridMapPessimisticTx TKey, TValue  and IGridMapPessimisticAutoTx TKey, TValue .

For additional information about data access APIs, see the IBM.WebSphere.Caching.Map namespace documentation.

Classes

  ClassDescription
Public classAvailabilityException
An AvailabilityException exception occurs when a target is not in the correct state to handle a request that it receives.
Public classClientServerTransactionCallbackException
A ClientServerTransactionCallbackException exception occurs when a method call to the client/server TransactionCallback encounters a remote request problem.
Public classGridConfigurationException
An GridConfigurationException exception occurs when a configuration problem is found. This exception might occur when the configuration specified in the deployment policy, ObjectGrid descriptor, or security descriptor is not correct.
Public classGridException
An GridException exception is the base exception class for all checked exceptions that occur in the product.
Public classGridManagerFactory
The GridManagerFactory is a factory for IGridManager instances, and is the entrypoint for all interactions with the data grid.
Public classGridServerRuntimeException
A GridServerRuntimeException exception is a generic wrapper for exceptions that occur in the server runtime.
Public classLifecycleFailedException
A LifecycleFailedException exception occurs on unexpected lifecycle states.
Public classMixedTransportException
A MixedTransportException is thrown when server and client have mismatched transport. For example, a server is using ORB, but the client is eXtremeIO
Public classNoActiveTransactionException
A NoActiveTransactionException exception indicates that no active transactions exist.
Public classNotReentrantException
A NotReentrantException occurs when a thread tries to run a map operation, such as calling a method on ObjectMap interface, when another thread is already running a map operation for the Session. A Session object can be used by a single thread only to perform concurrent map operations.
Public classOrderedDictionary TKey, TValue 
A generic version of the non-generic OrderedDictionary class.
Public classOrderedDictionary TKey, TValue  Enumerator
Public classReplicationVotedToRollbackTransactionException
A ReplicationVotedToRollbackTransactionException exception occurs when a transaction was rolled back because some or all of the synchronous replicas did not apply the transaction.
Public classTransactionAlreadyActiveException
A TransactionAlreadyActiveException exception occurs to indicate that a transaction is already active for the current Session. This exception does not cause the current active transaction to be rolled back, so the isTransactionActive method returns true.
Public classTransactionCallbackException
A TransactionCallbackException exception occurs when a TransactionCallback method call fails.
Public classTransactionException
A TransactionException exception is a general locking exception that indicates something went wrong with a transaction. Use the isTransactionActive() and wasTransactionRolledBack() methods to determine whether transaction is still active or was rolled back as a result of this exception.
Public classTransactionTimeoutException
A TransactionTimeoutException exception occurs when a transaction exceeds the transaction timeout value that was specified on the ObjectGrid or Session.
Interfaces

  InterfaceDescription
Public interfaceICatalogDomainInfo
Identifies a catalog service domain to be used for connecting to an eXtreme Scale data grid.
Public interfaceICatalogDomainManager
The ICatalogDomainManager is a factory for ICatalogDomainInfo objects used to connect to a catalog service domain. Use the CatalogDomainManager to retrieve an ICatalogDomainMananager instance.
Public interfaceIClientConnectionContext
The handle to a connection to a catalog service domain. An IClientConnectionContext is returned from the Connect(ICatalogDomainInfo) method when connecting to a data grid.

When finished with the data grid, use the Disconnect(IClientConnectionContext) method to disconnect from the data grid.

Public interfaceIGrid
An IGrid is the client's access to a named data grid and cooresponds to a configured ObjectGrid in the catalog service domain.

An IGrid is thread safe and should be cached and reused by the application and is valid until the connection is severed.

Use an IGrid to get map instances. Maps are defined on the data grid and have unique names within each configured ObjectGrid.

Public interfaceIGridManager
Provides methods for connecting to data grids. Use the GridManagerFactory to obtain an instance to an IGridManager instance.
Public interfaceIGridTransaction
Defines the interface for a transaction.
Public interfaceIOrderedDictionary TKey, TValue 
Specifies a generic version of the non-generic IOrderedDictionary interface.
Public interfaceITransactionable
Implementors of ITransactionable provide transaction demarcation semantics.
Enumerations

  EnumerationDescription
Public enumerationAvailabilityState
Each shard in a distributed data has an associated availability state. This state determines if the shard can process incoming requests.
Public enumerationTxnIsolationLevel
Specifies an enumeration that defines the valid transaction isolation level values.
Remarks

Note: The client API in this namespace and child namespaces will evolve in future releases. Therefore, to avoid problems with incompatible bindings in the future, interfaces should not be directly implemented nor extended unless explicitly noted in the interface documentation.
Examples

The following example illustrates how to connect to a data grid, retrieve an entry from a map, and disconnect from the grid:
// Retrieve the IGridManager instance.
IGridManager gm = GridManagerFactory.GetGridManager();

// Identify the catalog service domain to connect to, and create the  
// ICatalogDomainInfo object used to connect.
ICatalogDomainInfo catalogDomainInfo = 
    gm.CatalogDomainManager.CreateCatalogDomainInfo("com.acme.server1:2809,com.acme.server2:2809");

// Connect to the catalog service domain and get a IClientConnectionContext, 
// representing a handle to the catalog service domain connection.
IClientConnectionContext ccc = gm.Connect(catalogDomainInfo);

// Retrieve the IGrid instance for the specified data grid using 
// the IClientConnectionContext handle.  Subsequent calls to  
// GetGrid() for the same handle will produce the same IGrid instance.
IGrid grid = gm.GetGrid(ccc, "MyGrid");

// Retrieve an automatic transaction map instance.   
// All data access oprerations are performed thorugh a map.
IGridMapPessimisticAutoTx<long, string> autoTxMap = grid.GetGridMapPessimisticAutoTx<long, string>("PessimisticMap");

// Display an entry from the map
Console.WriteLine(autoTxMap.Get(123));

// Disconnect from the data grid when all done and  
// null out any references.
gm.Disconnect(ccc);
grid = null;
ccc = null;