Example usage for org.apache.hadoop.fs PathNotFoundException getPath

List of usage examples for org.apache.hadoop.fs PathNotFoundException getPath

Introduction

In this page you can find the example usage for org.apache.hadoop.fs PathNotFoundException getPath.

Prototype

public Path getPath() 

Source Link

Usage

From source file:org.apache.slider.client.SliderClient.java

License:Apache License

/**
 * //ww  w  . j  a  va2s  . c om
 * Look up an instance
 * @param path path
 * @return instance data
 * @throws NotFoundException no path/no service record
 * at the end of the path
 * @throws SliderException other failures
 * @throws IOException IO problems or wrapped exceptions
 */
public ServiceRecord resolve(String path) throws IOException, SliderException {
    try {
        return getRegistryOperations().resolve(path);
    } catch (PathNotFoundException e) {
        throw new NotFoundException(e.getPath().toString(), e);
    } catch (NoRecordException e) {
        throw new NotFoundException(e.getPath().toString(), e);
    }
}