Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
spark
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
cs525-sp18-g07
spark
Commits
0a2a9bce
Commit
0a2a9bce
authored
11 years ago
by
Gavin Li
Browse files
Options
Downloads
Patches
Plain Diff
fix typo and coding style
parent
4508089f
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
core/src/main/scala/spark/RDD.scala
+7
-7
7 additions, 7 deletions
core/src/main/scala/spark/RDD.scala
core/src/main/scala/spark/rdd/PipedRDD.scala
+1
-1
1 addition, 1 deletion
core/src/main/scala/spark/rdd/PipedRDD.scala
with
8 additions
and
8 deletions
core/src/main/scala/spark/RDD.scala
+
7
−
7
View file @
0a2a9bce
...
...
@@ -368,13 +368,13 @@ abstract class RDD[T: ClassManifest](
* @param printPipeContext Before piping elements, this function is called as an oppotunity
* to pipe context data. Print line function (like out.println) will be
* passed as printPipeContext's parameter.
* @param print
PipeContex
t Use this function to customize how to pipe elements. This function
*
will be called with each RDD element as the 1st parameter, and the
*
print line function (like out.println()) as the 2nd parameter.
*
An example of pipe the RDD data of groupBy() in a streaming way,
*
instead of constructing a huge String to concat all the elements:
*
def printRDDElement(record:(String, Seq[String]), f:String=>Unit) =
*
for (e <- record._2){f(e)}
* @param print
RDDElemen
t Use this function to customize how to pipe elements. This function
* will be called with each RDD element as the 1st parameter, and the
* print line function (like out.println()) as the 2nd parameter.
* An example of pipe the RDD data of groupBy() in a streaming way,
* instead of constructing a huge String to concat all the elements:
* def printRDDElement(record:(String, Seq[String]), f:String=>Unit) =
* for (e <- record._2){f(e)}
* @return the result RDD
*/
def
pipe
(
...
...
This diff is collapsed.
Click to expand it.
core/src/main/scala/spark/rdd/PipedRDD.scala
+
1
−
1
View file @
0a2a9bce
...
...
@@ -62,7 +62,7 @@ class PipedRDD[T: ClassManifest](
val
out
=
new
PrintWriter
(
proc
.
getOutputStream
)
// input the pipe context firstly
if
(
printPipeContext
!=
null
)
{
if
(
printPipeContext
!=
null
)
{
printPipeContext
(
out
.
println
(
_
))
}
for
(
elem
<-
firstParent
[
T
].
iterator
(
split
,
context
))
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment