{"action":"created","comment":{"url":"https://api.github.com/repos/tresata/spark-scalding/pulls/comments/23824358","id":23824358,"diff_hunk":"@@ -18,4 +25,44 @@ abstract class SparkJob(args: Args) extends Job(args) {\n   implicit lazy val sc: SparkContext = newSc(ConfigFactory.load, name, tmpJars)\n \n   override def run : Boolean\n+\n+  /**\n+   * Overrides the Scalding Job config method in order not to use the\n+   * default serializations, but to pass different ones instead.\n+   * \n+   * @return\n+   */\n+  override def config: Map[AnyRef, AnyRef] = {\n+    // this will overwrite the io.serializations option to what\n+    // we need it to be.\n+    super.config ++ setSerialization(ioSerializations).toMap\n+  }\n+\n+  /**\n+   * Hadoop and Cascading serialization needs to be first, and the Kryo serialization\n+   * needs to be last and this method handles this for you:\n+   * hadoop, cascading, [userHadoop,] kyro\n+   * is the order.\n+   *\n+   * Kryo uses a specific class here.\n+   *\n+   * @param userHadoop\n+   * @return\n+   */\n+  private[scalding] def setSerialization(userHadoop: Seq[Class[_ <: HSerialization[_]]] = Nil): Config = {","path":"src/main/scala/com/tresata/spark/scalding/SparkJob.scala","position":53,"original_position":53,"commit_id":"6ad46151facd92afa52612450c544314e2986036","original_commit_id":"6ad46151facd92afa52612450c544314e2986036","user":{"login":"koertkuipers","id":821284,"avatar_url":"https://avatars.githubusercontent.com/u/821284?v=3","gravatar_id":"","url":"https://api.github.com/users/koertkuipers","html_url":"https://github.com/koertkuipers","followers_url":"https://api.github.com/users/koertkuipers/followers","following_url":"https://api.github.com/users/koertkuipers/following{/other_user}","gists_url":"https://api.github.com/users/koertkuipers/gists{/gist_id}","starred_url":"https://api.github.com/users/koertkuipers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/koertkuipers/subscriptions","organizations_url":"https://api.github.com/users/koertkuipers/orgs","repos_url":"https://api.github.com/users/koertkuipers/repos","events_url":"https://api.github.com/users/koertkuipers/events{/privacy}","received_events_url":"https://api.github.com/users/koertkuipers/received_events","type":"User","site_admin":false},"body":"does it need to be private[scalding]? can it be private, or perhaps protected in case someone wants to call it in a Job that extends SparkJob to add some other serializations?","created_at":"2015-01-30T05:03:53Z","updated_at":"2015-01-30T05:03:53Z","html_url":"https://github.com/tresata/spark-scalding/pull/3#discussion_r23824358","pull_request_url":"https://api.github.com/repos/tresata/spark-scalding/pulls/3","_links":{"self":{"href":"https://api.github.com/repos/tresata/spark-scalding/pulls/comments/23824358"},"html":{"href":"https://github.com/tresata/spark-scalding/pull/3#discussion_r23824358"},"pull_request":{"href":"https://api.github.com/repos/tresata/spark-scalding/pulls/3"}}},"pull_request":{"url":"https://api.github.com/repos/tresata/spark-scalding/pulls/3","id":28329378,"html_url":"https://github.com/tresata/spark-scalding/pull/3","diff_url":"https://github.com/tresata/spark-scalding/pull/3.diff","patch_url":"https://github.com/tresata/spark-scalding/pull/3.patch","issue_url":"https://api.github.com/repos/tresata/spark-scalding/issues/3","number":3,"state":"open","locked":false,"title":"Cascading object serialization","user":{"login":"nikolovivan","id":3465575,"avatar_url":"https://avatars.githubusercontent.com/u/3465575?v=3","gravatar_id":"","url":"https://api.github.com/users/nikolovivan","html_url":"https://github.com/nikolovivan","followers_url":"https://api.github.com/users/nikolovivan/followers","following_url":"https://api.github.com/users/nikolovivan/following{/other_user}","gists_url":"https://api.github.com/users/nikolovivan/gists{/gist_id}","starred_url":"https://api.github.com/users/nikolovivan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nikolovivan/subscriptions","organizations_url":"https://api.github.com/users/nikolovivan/orgs","repos_url":"https://api.github.com/users/nikolovivan/repos","events_url":"https://api.github.com/users/nikolovivan/events{/privacy}","received_events_url":"https://api.github.com/users/nikolovivan/received_events","type":"User","site_admin":false},"body":"Hey Koert,\r\n\r\nI implemented this similarly to what you had, but the way it is in Scalding. Have a look at the pull request and let me know your thoughts.","created_at":"2015-01-30T00:46:29Z","updated_at":"2015-01-30T05:03:53Z","closed_at":null,"merged_at":null,"merge_commit_sha":"800a0f4dd6d60537c614435a09ac50035678b109","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/tresata/spark-scalding/pulls/3/commits","review_comments_url":"https://api.github.com/repos/tresata/spark-scalding/pulls/3/comments","review_comment_url":"https://api.github.com/repos/tresata/spark-scalding/pulls/comments/{number}","comments_url":"https://api.github.com/repos/tresata/spark-scalding/issues/3/comments","statuses_url":"https://api.github.com/repos/tresata/spark-scalding/statuses/6ad46151facd92afa52612450c544314e2986036","head":{"label":"nikolovivan:Cascading_Object_Serialization","ref":"Cascading_Object_Serialization","sha":"6ad46151facd92afa52612450c544314e2986036","user":{"login":"nikolovivan","id":3465575,"avatar_url":"https://avatars.githubusercontent.com/u/3465575?v=3","gravatar_id":"","url":"https://api.github.com/users/nikolovivan","html_url":"https://github.com/nikolovivan","followers_url":"https://api.github.com/users/nikolovivan/followers","following_url":"https://api.github.com/users/nikolovivan/following{/other_user}","gists_url":"https://api.github.com/users/nikolovivan/gists{/gist_id}","starred_url":"https://api.github.com/users/nikolovivan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nikolovivan/subscriptions","organizations_url":"https://api.github.com/users/nikolovivan/orgs","repos_url":"https://api.github.com/users/nikolovivan/repos","events_url":"https://api.github.com/users/nikolovivan/events{/privacy}","received_events_url":"https://api.github.com/users/nikolovivan/received_events","type":"User","site_admin":false},"repo":{"id":30045919,"name":"spark-scalding","full_name":"nikolovivan/spark-scalding","owner":{"login":"nikolovivan","id":3465575,"avatar_url":"https://avatars.githubusercontent.com/u/3465575?v=3","gravatar_id":"","url":"https://api.github.com/users/nikolovivan","html_url":"https://github.com/nikolovivan","followers_url":"https://api.github.com/users/nikolovivan/followers","following_url":"https://api.github.com/users/nikolovivan/following{/other_user}","gists_url":"https://api.github.com/users/nikolovivan/gists{/gist_id}","starred_url":"https://api.github.com/users/nikolovivan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nikolovivan/subscriptions","organizations_url":"https://api.github.com/users/nikolovivan/orgs","repos_url":"https://api.github.com/users/nikolovivan/repos","events_url":"https://api.github.com/users/nikolovivan/events{/privacy}","received_events_url":"https://api.github.com/users/nikolovivan/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/nikolovivan/spark-scalding","description":"","fork":true,"url":"https://api.github.com/repos/nikolovivan/spark-scalding","forks_url":"https://api.github.com/repos/nikolovivan/spark-scalding/forks","keys_url":"https://api.github.com/repos/nikolovivan/spark-scalding/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nikolovivan/spark-scalding/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nikolovivan/spark-scalding/teams","hooks_url":"https://api.github.com/repos/nikolovivan/spark-scalding/hooks","issue_events_url":"https://api.github.com/repos/nikolovivan/spark-scalding/issues/events{/number}","events_url":"https://api.github.com/repos/nikolovivan/spark-scalding/events","assignees_url":"https://api.github.com/repos/nikolovivan/spark-scalding/assignees{/user}","branches_url":"https://api.github.com/repos/nikolovivan/spark-scalding/branches{/branch}","tags_url":"https://api.github.com/repos/nikolovivan/spark-scalding/tags","blobs_url":"https://api.github.com/repos/nikolovivan/spark-scalding/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nikolovivan/spark-scalding/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nikolovivan/spark-scalding/git/refs{/sha}","trees_url":"https://api.github.com/repos/nikolovivan/spark-scalding/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nikolovivan/spark-scalding/statuses/{sha}","languages_url":"https://api.github.com/repos/nikolovivan/spark-scalding/languages","stargazers_url":"https://api.github.com/repos/nikolovivan/spark-scalding/stargazers","contributors_url":"https://api.github.com/repos/nikolovivan/spark-scalding/contributors","subscribers_url":"https://api.github.com/repos/nikolovivan/spark-scalding/subscribers","subscription_url":"https://api.github.com/repos/nikolovivan/spark-scalding/subscription","commits_url":"https://api.github.com/repos/nikolovivan/spark-scalding/commits{/sha}","git_commits_url":"https://api.github.com/repos/nikolovivan/spark-scalding/git/commits{/sha}","comments_url":"https://api.github.com/repos/nikolovivan/spark-scalding/comments{/number}","issue_comment_url":"https://api.github.com/repos/nikolovivan/spark-scalding/issues/comments/{number}","contents_url":"https://api.github.com/repos/nikolovivan/spark-scalding/contents/{+path}","compare_url":"https://api.github.com/repos/nikolovivan/spark-scalding/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nikolovivan/spark-scalding/merges","archive_url":"https://api.github.com/repos/nikolovivan/spark-scalding/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nikolovivan/spark-scalding/downloads","issues_url":"https://api.github.com/repos/nikolovivan/spark-scalding/issues{/number}","pulls_url":"https://api.github.com/repos/nikolovivan/spark-scalding/pulls{/number}","milestones_url":"https://api.github.com/repos/nikolovivan/spark-scalding/milestones{/number}","notifications_url":"https://api.github.com/repos/nikolovivan/spark-scalding/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nikolovivan/spark-scalding/labels{/name}","releases_url":"https://api.github.com/repos/nikolovivan/spark-scalding/releases{/id}","created_at":"2015-01-29T23:10:17Z","updated_at":"2015-01-29T23:10:31Z","pushed_at":"2015-01-30T00:43:13Z","git_url":"git://github.com/nikolovivan/spark-scalding.git","ssh_url":"git@github.com:nikolovivan/spark-scalding.git","clone_url":"https://github.com/nikolovivan/spark-scalding.git","svn_url":"https://github.com/nikolovivan/spark-scalding","homepage":"","size":288,"stargazers_count":0,"watchers_count":0,"language":"Scala","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"tresata:master","ref":"master","sha":"7ad1ab696bbdc5204e1f1151b99f2b041bf9d754","user":{"login":"tresata","id":823379,"avatar_url":"https://avatars.githubusercontent.com/u/823379?v=3","gravatar_id":"","url":"https://api.github.com/users/tresata","html_url":"https://github.com/tresata","followers_url":"https://api.github.com/users/tresata/followers","following_url":"https://api.github.com/users/tresata/following{/other_user}","gists_url":"https://api.github.com/users/tresata/gists{/gist_id}","starred_url":"https://api.github.com/users/tresata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tresata/subscriptions","organizations_url":"https://api.github.com/users/tresata/orgs","repos_url":"https://api.github.com/users/tresata/repos","events_url":"https://api.github.com/users/tresata/events{/privacy}","received_events_url":"https://api.github.com/users/tresata/received_events","type":"Organization","site_admin":false},"repo":{"id":24618635,"name":"spark-scalding","full_name":"tresata/spark-scalding","owner":{"login":"tresata","id":823379,"avatar_url":"https://avatars.githubusercontent.com/u/823379?v=3","gravatar_id":"","url":"https://api.github.com/users/tresata","html_url":"https://github.com/tresata","followers_url":"https://api.github.com/users/tresata/followers","following_url":"https://api.github.com/users/tresata/following{/other_user}","gists_url":"https://api.github.com/users/tresata/gists{/gist_id}","starred_url":"https://api.github.com/users/tresata/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tresata/subscriptions","organizations_url":"https://api.github.com/users/tresata/orgs","repos_url":"https://api.github.com/users/tresata/repos","events_url":"https://api.github.com/users/tresata/events{/privacy}","received_events_url":"https://api.github.com/users/tresata/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/tresata/spark-scalding","description":"","fork":false,"url":"https://api.github.com/repos/tresata/spark-scalding","forks_url":"https://api.github.com/repos/tresata/spark-scalding/forks","keys_url":"https://api.github.com/repos/tresata/spark-scalding/keys{/key_id}","collaborators_url":"https://api.github.com/repos/tresata/spark-scalding/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/tresata/spark-scalding/teams","hooks_url":"https://api.github.com/repos/tresata/spark-scalding/hooks","issue_events_url":"https://api.github.com/repos/tresata/spark-scalding/issues/events{/number}","events_url":"https://api.github.com/repos/tresata/spark-scalding/events","assignees_url":"https://api.github.com/repos/tresata/spark-scalding/assignees{/user}","branches_url":"https://api.github.com/repos/tresata/spark-scalding/branches{/branch}","tags_url":"https://api.github.com/repos/tresata/spark-scalding/tags","blobs_url":"https://api.github.com/repos/tresata/spark-scalding/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/tresata/spark-scalding/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/tresata/spark-scalding/git/refs{/sha}","trees_url":"https://api.github.com/repos/tresata/spark-scalding/git/trees{/sha}","statuses_url":"https://api.github.com/repos/tresata/spark-scalding/statuses/{sha}","languages_url":"https://api.github.com/repos/tresata/spark-scalding/languages","stargazers_url":"https://api.github.com/repos/tresata/spark-scalding/stargazers","contributors_url":"https://api.github.com/repos/tresata/spark-scalding/contributors","subscribers_url":"https://api.github.com/repos/tresata/spark-scalding/subscribers","subscription_url":"https://api.github.com/repos/tresata/spark-scalding/subscription","commits_url":"https://api.github.com/repos/tresata/spark-scalding/commits{/sha}","git_commits_url":"https://api.github.com/repos/tresata/spark-scalding/git/commits{/sha}","comments_url":"https://api.github.com/repos/tresata/spark-scalding/comments{/number}","issue_comment_url":"https://api.github.com/repos/tresata/spark-scalding/issues/comments/{number}","contents_url":"https://api.github.com/repos/tresata/spark-scalding/contents/{+path}","compare_url":"https://api.github.com/repos/tresata/spark-scalding/compare/{base}...{head}","merges_url":"https://api.github.com/repos/tresata/spark-scalding/merges","archive_url":"https://api.github.com/repos/tresata/spark-scalding/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/tresata/spark-scalding/downloads","issues_url":"https://api.github.com/repos/tresata/spark-scalding/issues{/number}","pulls_url":"https://api.github.com/repos/tresata/spark-scalding/pulls{/number}","milestones_url":"https://api.github.com/repos/tresata/spark-scalding/milestones{/number}","notifications_url":"https://api.github.com/repos/tresata/spark-scalding/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/tresata/spark-scalding/labels{/name}","releases_url":"https://api.github.com/repos/tresata/spark-scalding/releases{/id}","created_at":"2014-09-30T00:44:59Z","updated_at":"2015-01-13T16:25:16Z","pushed_at":"2015-01-29T21:03:12Z","git_url":"git://github.com/tresata/spark-scalding.git","ssh_url":"git@github.com:tresata/spark-scalding.git","clone_url":"https://github.com/tresata/spark-scalding.git","svn_url":"https://github.com/tresata/spark-scalding","homepage":null,"size":288,"stargazers_count":13,"watchers_count":13,"language":"Scala","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":7,"mirror_url":null,"open_issues_count":2,"forks":7,"open_issues":2,"watchers":13,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/tresata/spark-scalding/pulls/3"},"html":{"href":"https://github.com/tresata/spark-scalding/pull/3"},"issue":{"href":"https://api.github.com/repos/tresata/spark-scalding/issues/3"},"comments":{"href":"https://api.github.com/repos/tresata/spark-scalding/issues/3/comments"},"review_comments":{"href":"https://api.github.com/repos/tresata/spark-scalding/pulls/3/comments"},"review_comment":{"href":"https://api.github.com/repos/tresata/spark-scalding/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/tresata/spark-scalding/pulls/3/commits"},"statuses":{"href":"https://api.github.com/repos/tresata/spark-scalding/statuses/6ad46151facd92afa52612450c544314e2986036"}}}}