https://github.com/globocom/ghdfs
Works with HDFS for common operations and Scala compatibility.
https://github.com/globocom/ghdfs
Last synced: 11 months ago
JSON representation
Works with HDFS for common operations and Scala compatibility.
- Host: GitHub
- URL: https://github.com/globocom/ghdfs
- Owner: globocom
- License: mit
- Created: 2018-11-16T19:22:08.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2020-10-26T01:13:44.000Z (almost 6 years ago)
- Last Synced: 2025-04-06T08:36:37.177Z (over 1 year ago)
- Language: Scala
- Size: 68.4 KB
- Stars: 5
- Watchers: 59
- Forks: 9
- Open Issues: 7
-
Metadata Files:
- Readme: README.md
- Contributing: CONTRIBUTING.md
- License: LICENSE
- Code of conduct: CODE_OF_CONDUCT.md
Awesome Lists containing this project
README
[](https://travis-ci.com/globocom/ghdfs)
# GHDFS
> Works with HDFS for common operations and Scala compatibility.
## Installation
Package is under com.globo.bigdata.ghdfs
- Include in your dependencies:
```branch
"com.globo.bigdata" %% "ghdfs" % "0.0.13"
```
## Usage
```branch
val hdfs = HdfsManager(Properties.envOrNone("HADOOP_CONF_DIR"))
hdfs.write(Path)
hdfs.write(Path, InputStream)
hdfs.read(Path)
hdfs.status(Path)
hdfs.move(Path, Path)
hdfs.listFiles(Path, recursive = false).foreach(...)
hdfs.delete(Path, recursive = true)
etc...
```
### Get Filesystem Instance
```branch
hdfs.getFS.exists(hadoopPath)
```
## Contribute
For development and contributing, please follow [Contributing Guide](https://github.com/globocom/ghdfs/blob/master/CONTRIBUTING.md) and ALWAYS respect the [Code of Conduct](https://github.com/globocom/ghdfs/blob/master/CODE_OF_CONDUCT.md)