public class GeospatialFileSystem extends FileSystem
FileSystem
for Geospatial data. This file system
manager assumes that the information being stored has both space and time
properties.
Relevant system properties include galileo.fs.GeospatialFileSystem.timeFormat and galileo.fs.GeospatialFileSystem.geohashPrecision to modify how the hierarchy is created.
BLOCK_EXTENSION, storageDirectory
Constructor and Description |
---|
GeospatialFileSystem(java.lang.String storageDirectory) |
Modifier and Type | Method and Description |
---|---|
protected FeaturePath<java.lang.String> |
createPath(java.lang.String physicalPath,
Metadata meta)
Using the Feature attributes found in the provided Metadata, a
path is created for insertion into the Metadata Graph.
|
MetadataGraph |
getMetadataGraph() |
java.util.List<Path<Feature,java.lang.String>> |
query(Query query) |
void |
shutdown()
Performs a clean shutdown of the FileSystem instance.
|
java.lang.String |
storeBlock(Block block)
Stores a
Block on disk. |
void |
storeMetadata(Metadata metadata,
java.lang.String blockPath)
Inserts Metadata into the file system.
|
fullRecovery, getFreeSpace, initialize, isReadOnly, loadBlock, loadMetadata, rebuildPaths, recover, scanDirectory
public GeospatialFileSystem(java.lang.String storageDirectory) throws FileSystemException, java.io.IOException, galileo.serialization.SerializationException
FileSystemException
java.io.IOException
galileo.serialization.SerializationException
public java.lang.String storeBlock(Block block) throws FileSystemException, java.io.IOException
PhysicalGraph
Block
on disk. The location of the Block will be
determined by the particular FileSystem implementation being used rather
than as a method parameter, so only the Block itself is provided.storeBlock
in interface PhysicalGraph
storeBlock
in class FileSystem
block
- the Block instance to persist to disk.FileSystemException
java.io.IOException
protected FeaturePath<java.lang.String> createPath(java.lang.String physicalPath, Metadata meta)
public void storeMetadata(Metadata metadata, java.lang.String blockPath) throws FileSystemException, java.io.IOException
PhysicalGraph
storeMetadata
in interface PhysicalGraph
storeMetadata
in class FileSystem
metadata
- the Metadata
to 'store,' which may just involve
updating index structures.blockPath
- the on-disk path of the Block the Metadata being stored
belongs to.FileSystemException
java.io.IOException
public MetadataGraph getMetadataGraph()
public void shutdown()
FileSystem
Note that this method may be called during a signal handling operation, which may mean that the logging subsystem has already shut down, so critical errors/information should be printed to stdout or stderr. Furthermore, there is no guarantee all the shutdown operations will be executed, so time is of the essence here.
shutdown
in class FileSystem