org.jasig.portal
Class ProblemsTable

java.lang.Object
  extended by org.jasig.portal.ProblemsTable

public class ProblemsTable
extends java.lang.Object

A cache of recently reported PortalExceptions.

Version:
$Revision: 1.7 $
Author:
Howard Gilbert, andrew.petro@yale.edu

Field Summary
private static int DEFAULT_MAX_RECENT_PER_SPECIFIC
          The default number of recent PortalExceptions that will be stored for each specific subcategory of ErrorID in the case where the relevant property is not set.
private static int DEFAULT_OVERALL_RECENT_ERRORS_COUNT
          The default number of recent PortalExceptions that will be stored in the overall FIFO queue regardless of ErrorID, which will be used in the case where the relevant property is not set.
static java.lang.String MAX_RECENT_ERRORS_PER_SPECIFIC_PROPERTY
          The name of the PropertiesManager property the value of which should be the number of recent PortalExceptions you would like stored for each specific subcategory of ErrorID.
private static int maxRecent
          The number of recent PortalExceptions that will be stored for each specific subcategory of ErrorID.
static java.lang.String OVERALL_RECENT_ERRORS_PROPERTY
          The name of the propertiesManager property the value of which should be the number of recent PortalExceptions you would like stored in the overall FIFO cache, regardless of ErrorID.
private static int overallErrorsCount
          The number of recent PortalExceptions that will be stored in the overall FIFO queue regardless of ErrorID.
static java.util.LinkedList recentIds
          List of recently modified CountID instances.
private static java.util.LinkedList recentPortalExceptions
          List of recently reported PortalExceptions, regardless of category.
static java.util.TreeMap registeredIds
          TreeMap from ErrorID Categories to TreeMaps.
 
Constructor Summary
ProblemsTable()
           
 
Method Summary
static java.util.List getRecentPortalExceptions()
          Get an unmodifiable shallow copy of the list of recent PortalExceptions.
static void register(ErrorID id)
          Add ErrorID to TreeMaps
static void store(PortalException pe)
          Store a PortalException in the tables.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

registeredIds

public static java.util.TreeMap registeredIds
TreeMap from ErrorID Categories to TreeMaps. The enclosed TreeMaps map from Specifics (ErrorID subcategories) to CountID objects. The CountID objects cache the PortalExceptions that were in the Specific.


recentIds

public static java.util.LinkedList recentIds
List of recently modified CountID instances.


recentPortalExceptions

private static java.util.LinkedList recentPortalExceptions
List of recently reported PortalExceptions, regardless of category.


MAX_RECENT_ERRORS_PER_SPECIFIC_PROPERTY

public static final java.lang.String MAX_RECENT_ERRORS_PER_SPECIFIC_PROPERTY
The name of the PropertiesManager property the value of which should be the number of recent PortalExceptions you would like stored for each specific subcategory of ErrorID.

See Also:
Constant Field Values

DEFAULT_MAX_RECENT_PER_SPECIFIC

private static final int DEFAULT_MAX_RECENT_PER_SPECIFIC
The default number of recent PortalExceptions that will be stored for each specific subcategory of ErrorID in the case where the relevant property is not set.

See Also:
Constant Field Values

maxRecent

private static final int maxRecent
The number of recent PortalExceptions that will be stored for each specific subcategory of ErrorID.


OVERALL_RECENT_ERRORS_PROPERTY

public static final java.lang.String OVERALL_RECENT_ERRORS_PROPERTY
The name of the propertiesManager property the value of which should be the number of recent PortalExceptions you would like stored in the overall FIFO cache, regardless of ErrorID.

See Also:
Constant Field Values

DEFAULT_OVERALL_RECENT_ERRORS_COUNT

private static final int DEFAULT_OVERALL_RECENT_ERRORS_COUNT
The default number of recent PortalExceptions that will be stored in the overall FIFO queue regardless of ErrorID, which will be used in the case where the relevant property is not set.

See Also:
Constant Field Values

overallErrorsCount

private static final int overallErrorsCount
The number of recent PortalExceptions that will be stored in the overall FIFO queue regardless of ErrorID.

Constructor Detail

ProblemsTable

public ProblemsTable()
Method Detail

register

public static void register(ErrorID id)
Add ErrorID to TreeMaps

Parameters:
id - ErrorID (ignored if duplicate)

store

public static void store(PortalException pe)
Store a PortalException in the tables.

Parameters:
pe - PortalException to be tabulated

getRecentPortalExceptions

public static java.util.List getRecentPortalExceptions()
Get an unmodifiable shallow copy of the list of recent PortalExceptions.

Returns:
an unmodifiable shallow copy of the list of recent PortalExceptions.