GigaSpaces XAP 10.0.1 API

com.j_spaces.core
Class MemoryShortageException

java.lang.Object
  extended by java.lang.Throwable
      extended by java.lang.Exception
          extended by java.lang.RuntimeException
              extended by com.gigaspaces.client.ResourceCapacityExceededException
                  extended by com.j_spaces.core.MemoryShortageException
All Implemented Interfaces:
Serializable

public class MemoryShortageException
extends com.gigaspaces.client.ResourceCapacityExceededException

This Exception indicates that the space server process reached the predefined percentage usage ratio.

See Also:
Serialized Form

Constructor Summary
MemoryShortageException(String spaceName, String containerName, String hostName, long memoryUsage, long maxMemory)
          Constructor
 
Method Summary
 String getContainerName()
           
 String getHostName()
           
 long getMaxMemory()
           
 long getMemoryUsage()
           
 String getSpaceName()
           
 String toString()
          Return the exception message
 
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

MemoryShortageException

public MemoryShortageException(String spaceName,
                               String containerName,
                               String hostName,
                               long memoryUsage,
                               long maxMemory)
Constructor

Parameters:
spaceName - the name of the space that caused this exception
containerName - the name of the container that contains the space that caused this exception.
hostName - the name of the machine that hosts the space that caused this exception
memoryUsage - the amount of memory in use
maxMemory - the maximum amount of memory that can be used
Method Detail

getSpaceName

public String getSpaceName()
Returns:
the name of the space that caused this exception

getContainerName

public String getContainerName()
Returns:
the name of the container that contains the space that caused this exception.

getHostName

public String getHostName()
Returns:
the name of the machine that hosts the space that caused this exception

getMemoryUsage

public long getMemoryUsage()
Returns:
the current memory usage

getMaxMemory

public long getMaxMemory()
Returns:
the maximum amount of memory that can be used

toString

public String toString()
Return the exception message

Overrides:
toString in class Throwable
Returns:
the exception message.
See Also:
Throwable.getMessage()

GigaSpaces XAP 10.0.1 API

Copyright © GigaSpaces.