Class
Tree
          
SUMMARY: INNER | FIELD | CONSTR | METHODDETAIL: FIELD | CONSTR | METHOD
 

com.newstep.solid.management.runtime.component
Class ComponentErrorHandler
com.newstep.solid.management.ErrorHandler
  |
  +--com.newstep.solid.management.runtime.component.ComponentErrorHandler

public class ComponentErrorHandler      
 
Links:
Kernel Association Association Link
to Class MemoryReservoir
memory reservoir used to block memory that may be released in order to allow
graceful handling of even in severe out of memory conditions
Associates type:
association
Client cardinality:
1
Client navigability:
NOT NAVIGABLE
Client visibility:
private
Supplier cardinality:
1
Supplier navigability:
NAVIGABLE
Supplier visibility:
private
 
Kernel Association Association Link
to Class Component
the component who's error are being handled
Associates type:
association
Client cardinality:
1
Client navigability:
NOT NAVIGABLE
Client visibility:
private
Supplier cardinality:
1
Supplier navigability:
NAVIGABLE
Supplier visibility:
private
 
Generalization Generalization Link
to Class ErrorHandler
 
 

Field Summary
private final static String
private Component
private static Logger
private static MemoryReservoir
Constructor Summary
public void
Method Summary
public void
doHandle(Throwable throwable)
private void
handleOutOfMemory(Throwable throwable)
public void
Field Detail
className
private final static String className
Final.
Multiplicity:
1
Static.
 

component
private Component component
the component who's error are being handled
Multiplicity:
1
 

logger
private static Logger logger
logging members
Multiplicity:
1
Static.
 

memoryReservoir
private static MemoryReservoir memoryReservoir
memory reservoir used to block memory that may be released in order to allow
graceful handling of even in severe out of memory conditions
Multiplicity:
1
Static.
 
Constructor Detail
ComponentErrorHandler
public void ComponentErrorHandler (Component component)
 
default constructor
Stereotype:
create
 
Method Detail
doHandle
public void doHandle (Throwable throwable)
 
logs the unhandled throwable
 

handleOutOfMemory
private void handleOutOfMemory (Throwable throwable)
 
handle the out of memory by logging and alarming. If handling fails due
to lack of memory, the handle method attempts to regain some memory from
its reserves and retry the handling


NOTE: must be careful that attempted handling does not enter
undefined state if OutOfMemory generated so it can be retried

Parameters:
throwable the unhandled Throwable to be handled
 

init
public void init (ErrorHandlerConfig config)
 
initializes the memory reservoir base on the specified configuration
Parameters:
config the ComponentErrorHandlerConfig to apply to the handler
 

Class
Tree
          
SUMMARY: INNER | FIELD | CONSTR | METHODDETAIL: FIELD | CONSTR | METHOD