public Set<DiscoveredResourceDetails> discoverResources(ResourceDiscoveryContext<PlatformComponent> discoveryContext)
throws Exception {
Set<DiscoveredResourceDetails> results = new LinkedHashSet<DiscoveredResourceDetails>();
SystemInfo sysInfo = discoveryContext.getSystemInformation();
if (!sysInfo.isNative()) {
log.debug("Skipping " + discoveryContext.getResourceType().getName()
+ " discovery, since native system info is not available.");
return results;
}
for (FileSystemInfo fsInfo : sysInfo.getFileSystems()) {
FileSystem fs = fsInfo.getFileSystem();
int fsType = fs.getType();
// We only support local, network (nfs), lofs, or tmpfs filesystems - skip any other types.
switch (fsType) {
case FileSystem.TYPE_LOCAL_DISK: