Example usage for org.apache.hadoop.hdfs.protocol CacheDirective getBytesNeeded

List of usage examples for org.apache.hadoop.hdfs.protocol CacheDirective getBytesNeeded

Introduction

In this page you can find the example usage for org.apache.hadoop.hdfs.protocol CacheDirective getBytesNeeded.

Prototype

public long getBytesNeeded() 

Source Link

Usage

From source file:io.hops.metadata.adaptor.CacheDirectiveDALAdaptor.java

License:Apache License

@Override
public io.hops.metadata.hdfs.entity.CacheDirective convertHDFStoDAL(CacheDirective cacheDirective)
        throws StorageException {
    return new io.hops.metadata.hdfs.entity.CacheDirective(cacheDirective.getId(), cacheDirective.getPath(),
            cacheDirective.getReplication(), cacheDirective.getExpiryTime(), cacheDirective.getBytesNeeded(),
            cacheDirective.getBytesCached(), cacheDirective.getFilesNeeded(), cacheDirective.getFilesCached(),
            cacheDirective.getPoolName());
}

From source file:io.hops.metadata.adaptor.CacheDirectiveDALAdaptor.java

License:Apache License

@Override
public CacheDirective convertDALtoHDFS(io.hops.metadata.hdfs.entity.CacheDirective cacheDirective) {
    if (cacheDirective == null) {
        return null;
    }//from   w  w  w  .  ja v a 2s.c  o m
    return new CacheDirective(cacheDirective.getId(), cacheDirective.getPath(), cacheDirective.getReplication(),
            cacheDirective.getExpiryTime(), cacheDirective.getBytesNeeded(), cacheDirective.getBytesCached(),
            cacheDirective.getFilesNeeded(), cacheDirective.getFilesCached(), cacheDirective.getPool());
}