官术网_书友最值得收藏!

.saveAsTextFile(...) action

The saveAsTextFile() action saves your RDD into a text file; note that each partition is a separate file. See the following snippet:

# Saves airports as a text file
# Note, each partition has their own file

# saveAsTextFile
airports.saveAsTextFile("/tmp/denny/airports")

This will actually save the following files:

# Review file structure
# Note that `airports` is a folder with two
# files (part-zzzzz) as the airports RDD is
# comprised of two partitions.
/tmp/denny/airports/_SUCCESS
/tmp/denny/airports/part-00000
/tmp/denny/airports/part-00001
主站蜘蛛池模板: 横山县| 昌图县| 武鸣县| 上栗县| 海盐县| 南和县| 贞丰县| 济阳县| 五大连池市| 金溪县| 商都县| 平顺县| 林口县| 宾川县| 霍山县| 依安县| 堆龙德庆县| 莱州市| 游戏| 东莞市| 承德市| 佛冈县| 哈密市| 清远市| 柞水县| 克山县| 鄄城县| 达孜县| 贵州省| 玉门市| 外汇| 遂昌县| 四川省| 漠河县| 东城区| 肥乡县| 开江县| 汕尾市| 镇平县| 浦江县| 永登县|