Class ExceptionCatchingResourceModelSource
- java.lang.Object
-
- com.dtolabs.rundeck.core.resources.DelegateResourceModelSource
-
- com.dtolabs.rundeck.core.resources.ExceptionCatchingResourceModelSource
-
- All Implemented Interfaces:
ResourceModelSource
,ResourceModelSourceErrors
- Direct Known Subclasses:
CachingResourceModelSource
public abstract class ExceptionCatchingResourceModelSource extends DelegateResourceModelSource
Wraps a ResourceModelSource and provides resilience in case the underlying source throws checked or unchecked exceptions. Any exceptions thrown will be caught, andreturnResultNodes(com.dtolabs.rundeck.core.common.INodeSet)
called with either null (exception thrown), or the result of the underlying call to getNodes
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interface
ExceptionCatchingResourceModelSource.ExceptionHandler
-
Field Summary
Fields Modifier and Type Field Description static org.slf4j.Logger
logger
-
Constructor Summary
Constructors Modifier Constructor Description protected
ExceptionCatchingResourceModelSource(ResourceModelSource delegate)
protected
ExceptionCatchingResourceModelSource(ResourceModelSource delegate, java.lang.String identity)
protected
ExceptionCatchingResourceModelSource(ResourceModelSource delegate, java.lang.String identity, ExceptionCatchingResourceModelSource.ExceptionHandler handler)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description INodeSet
getNodes()
-
Methods inherited from class com.dtolabs.rundeck.core.resources.DelegateResourceModelSource
getDelegate, getModelSourceErrors, getSourceType, getWriteable
-
-
-
-
Constructor Detail
-
ExceptionCatchingResourceModelSource
protected ExceptionCatchingResourceModelSource(ResourceModelSource delegate)
-
ExceptionCatchingResourceModelSource
protected ExceptionCatchingResourceModelSource(ResourceModelSource delegate, java.lang.String identity)
-
ExceptionCatchingResourceModelSource
protected ExceptionCatchingResourceModelSource(ResourceModelSource delegate, java.lang.String identity, ExceptionCatchingResourceModelSource.ExceptionHandler handler)
-
-
Method Detail
-
getNodes
public INodeSet getNodes() throws ResourceModelSourceException
- Specified by:
getNodes
in interfaceResourceModelSource
- Overrides:
getNodes
in classDelegateResourceModelSource
- Throws:
ResourceModelSourceException
-
-