Package thredds.core
Class DataRootManager
java.lang.Object
thredds.core.DataRootManager
- All Implemented Interfaces:
org.springframework.beans.factory.InitializingBean
@Component
public class DataRootManager
extends Object
implements org.springframework.beans.factory.InitializingBean
The DataRootHandler manages all the "data roots" for a TDS
and provides mappings from URLs to catalog and datasets.
The "data roots" are read in from one or more trees of config catalogs and are defined by the datasetScan and datasetRoot and featureCollection elements in the config catalogs.
- Since:
- 1/23/2015
-
Nested Class Summary
Nested Classes -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionvoidfindDataRootMatch(String spath) thredds.server.catalog.FeatureCollectionReffindFeatureCollection(String collectionName) List<thredds.server.catalog.FeatureCollectionRef>static DataRootManagergetLocationFromRequestPath(String reqPath) Return the location to which the given path maps.voidvoidsetDataRootLocationAliasExpanders(Map<String, String> aliases) voidsetDataRootPathMatcher(thredds.server.catalog.DataRootPathMatcher dataRootPathMatcher) void
-
Field Details
-
debug
public static final boolean debug- See Also:
-
-
Method Details
-
getInstance
-
setDataRootLocationAliasExpanders
-
afterPropertiesSet
- Specified by:
afterPropertiesSetin interfaceorg.springframework.beans.factory.InitializingBean- Throws:
Exception
-
setDataRootPathMatcher
public void setDataRootPathMatcher(thredds.server.catalog.DataRootPathMatcher dataRootPathMatcher) -
findDataRootMatch
-
getLocationFromRequestPath
Return the location to which the given path maps. Null is returned if the dataset does not exist, the matching DatasetScan or DataRoot filters out the requested MFile, the MFile does not represent a File (i.e., it is not a CrawlableDatasetFile), or an I/O error occurs- Parameters:
reqPath- the request path.- Returns:
- the location of the file on disk, or null
- Throws:
IllegalStateException- if the request is not for a descendant of (or the same as) the matching DatasetRoot collection location.
-
showRoots
-
getFeatureCollections
-
findFeatureCollection
-
makeDebugActions
public void makeDebugActions()
-