{"action":"created","comment":{"url":"https://api.github.com/repos/pnancke/trip-planner/pulls/comments/68039914","id":68039914,"diff_hunk":"@@ -75,35 +89,28 @@ class HomeController {\n         json.toString()\n     }\n \n-    private\n-    static List<List<String>> getRouteCoordinates(RestBuilder rest, Point start, Point destination, List<Point> via, String lang) {\n+    private static RouteSegment getRouteCoordinates(Point start, Point destination) {\n         ActiveTimer timer = new ActiveTimer()\n-        Collections.sort(via, new SortPoints(start));\n-        Joiner joiner = Joiner.on(' ').skipNulls()\n-        String viaString = joiner.join(via.stream().map({ it -> it.lon + \",\" + it.lat }).collect(Collectors.toList()))\n-\n-        String url = \"http://openls.geog.uni-heidelberg.de/route?start=$start.lon,$start.lat&end=$destination.lon,\" +\n-                \"$destination.lat&via=$viaString&lang=$lang&distunit=KM&routepref=Car&weighting=Recommended&useTMC=false\" +\n-                \"&noMotorways=false&noTollways=false&noUnpavedroads=false&noSteps=false&noFerries=false&instructions=false\"\n-        log.info(\"Request to routing URL: $url\")\n-\n-        def get = rest.get(url)\n-        def xml = new XmlSlurper().parseText(get.responseEntity.body.toString())\n-        def travelTime = xml.'Response'.'DetermineRouteResponse'.'RouteSummary'.'TotalTime'\n+        RestBuilder rest = new RestBuilder()\n+        def url = \"http://www.yournavigation.org/api/1.0/gosmore.php?format=kml&flat=$start.lat&flon=$start.lon\" +\n+                \"&tlat=$destination.lat&tlon=$destination.lon\"\n+        def xml = new XmlSlurper().parseText(rest.get(url).text)\n+        Integer travelTime = xml.Document.traveltime.toInteger()\n         log.info \"found a route with a travel-time of: $travelTime\"\n-        LinkedList routeCoordinates = xml.'Response'.'DetermineRouteResponse'.'RouteGeometry'.'LineString'.'pos'.list()\n-\n-        timer.stopAndLog(log, \"creating route with waypoints\")\n-        routeCoordinates.collect { it.toString().tokenize(\" \") }\n+        def routeCoordinates = xml.Document.Folder.Placemark.LineString.coordinates.text().trim().tokenize(\"\\n\")","path":"grails-app/controllers/trip/planner/HomeController.groovy","position":120,"original_position":120,"commit_id":"0650a817c14d7196bb20ef55d176e316ae298ac7","original_commit_id":"0650a817c14d7196bb20ef55d176e316ae298ac7","user":{"login":"MZober1993","id":13154013,"avatar_url":"https://avatars.githubusercontent.com/u/13154013?v=3","gravatar_id":"","url":"https://api.github.com/users/MZober1993","html_url":"https://github.com/MZober1993","followers_url":"https://api.github.com/users/MZober1993/followers","following_url":"https://api.github.com/users/MZober1993/following{/other_user}","gists_url":"https://api.github.com/users/MZober1993/gists{/gist_id}","starred_url":"https://api.github.com/users/MZober1993/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MZober1993/subscriptions","organizations_url":"https://api.github.com/users/MZober1993/orgs","repos_url":"https://api.github.com/users/MZober1993/repos","events_url":"https://api.github.com/users/MZober1993/events{/privacy}","received_events_url":"https://api.github.com/users/MZober1993/received_events","type":"User","site_admin":false},"body":"routeCoordinates is a List<String>, please use this type","created_at":"2016-06-22T11:59:17Z","updated_at":"2016-06-22T11:59:17Z","html_url":"https://github.com/pnancke/trip-planner/pull/70#discussion_r68039914","pull_request_url":"https://api.github.com/repos/pnancke/trip-planner/pulls/70","_links":{"self":{"href":"https://api.github.com/repos/pnancke/trip-planner/pulls/comments/68039914"},"html":{"href":"https://github.com/pnancke/trip-planner/pull/70#discussion_r68039914"},"pull_request":{"href":"https://api.github.com/repos/pnancke/trip-planner/pulls/70"}}},"pull_request":{"url":"https://api.github.com/repos/pnancke/trip-planner/pulls/70","id":74563021,"html_url":"https://github.com/pnancke/trip-planner/pull/70","diff_url":"https://github.com/pnancke/trip-planner/pull/70.diff","patch_url":"https://github.com/pnancke/trip-planner/pull/70.patch","issue_url":"https://api.github.com/repos/pnancke/trip-planner/issues/70","number":70,"state":"open","locked":false,"title":"Reimplement old routing api parallel ","user":{"login":"pnancke","id":12659443,"avatar_url":"https://avatars.githubusercontent.com/u/12659443?v=3","gravatar_id":"","url":"https://api.github.com/users/pnancke","html_url":"https://github.com/pnancke","followers_url":"https://api.github.com/users/pnancke/followers","following_url":"https://api.github.com/users/pnancke/following{/other_user}","gists_url":"https://api.github.com/users/pnancke/gists{/gist_id}","starred_url":"https://api.github.com/users/pnancke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pnancke/subscriptions","organizations_url":"https://api.github.com/users/pnancke/orgs","repos_url":"https://api.github.com/users/pnancke/repos","events_url":"https://api.github.com/users/pnancke/events{/privacy}","received_events_url":"https://api.github.com/users/pnancke/received_events","type":"User","site_admin":false},"body":"closes #64 ","created_at":"2016-06-21T07:28:11Z","updated_at":"2016-06-22T11:59:17Z","closed_at":null,"merged_at":null,"merge_commit_sha":"9248803041899c9191fd5d520c07762b7d1989c9","assignee":{"login":"MZober1993","id":13154013,"avatar_url":"https://avatars.githubusercontent.com/u/13154013?v=3","gravatar_id":"","url":"https://api.github.com/users/MZober1993","html_url":"https://github.com/MZober1993","followers_url":"https://api.github.com/users/MZober1993/followers","following_url":"https://api.github.com/users/MZober1993/following{/other_user}","gists_url":"https://api.github.com/users/MZober1993/gists{/gist_id}","starred_url":"https://api.github.com/users/MZober1993/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MZober1993/subscriptions","organizations_url":"https://api.github.com/users/MZober1993/orgs","repos_url":"https://api.github.com/users/MZober1993/repos","events_url":"https://api.github.com/users/MZober1993/events{/privacy}","received_events_url":"https://api.github.com/users/MZober1993/received_events","type":"User","site_admin":false},"milestone":null,"commits_url":"https://api.github.com/repos/pnancke/trip-planner/pulls/70/commits","review_comments_url":"https://api.github.com/repos/pnancke/trip-planner/pulls/70/comments","review_comment_url":"https://api.github.com/repos/pnancke/trip-planner/pulls/comments{/number}","comments_url":"https://api.github.com/repos/pnancke/trip-planner/issues/70/comments","statuses_url":"https://api.github.com/repos/pnancke/trip-planner/statuses/0650a817c14d7196bb20ef55d176e316ae298ac7","head":{"label":"pnancke:parallel-routing-api-2","ref":"parallel-routing-api-2","sha":"0650a817c14d7196bb20ef55d176e316ae298ac7","user":{"login":"pnancke","id":12659443,"avatar_url":"https://avatars.githubusercontent.com/u/12659443?v=3","gravatar_id":"","url":"https://api.github.com/users/pnancke","html_url":"https://github.com/pnancke","followers_url":"https://api.github.com/users/pnancke/followers","following_url":"https://api.github.com/users/pnancke/following{/other_user}","gists_url":"https://api.github.com/users/pnancke/gists{/gist_id}","starred_url":"https://api.github.com/users/pnancke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pnancke/subscriptions","organizations_url":"https://api.github.com/users/pnancke/orgs","repos_url":"https://api.github.com/users/pnancke/repos","events_url":"https://api.github.com/users/pnancke/events{/privacy}","received_events_url":"https://api.github.com/users/pnancke/received_events","type":"User","site_admin":false},"repo":{"id":56146698,"name":"trip-planner","full_name":"pnancke/trip-planner","owner":{"login":"pnancke","id":12659443,"avatar_url":"https://avatars.githubusercontent.com/u/12659443?v=3","gravatar_id":"","url":"https://api.github.com/users/pnancke","html_url":"https://github.com/pnancke","followers_url":"https://api.github.com/users/pnancke/followers","following_url":"https://api.github.com/users/pnancke/following{/other_user}","gists_url":"https://api.github.com/users/pnancke/gists{/gist_id}","starred_url":"https://api.github.com/users/pnancke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pnancke/subscriptions","organizations_url":"https://api.github.com/users/pnancke/orgs","repos_url":"https://api.github.com/users/pnancke/repos","events_url":"https://api.github.com/users/pnancke/events{/privacy}","received_events_url":"https://api.github.com/users/pnancke/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/pnancke/trip-planner","description":"","fork":false,"url":"https://api.github.com/repos/pnancke/trip-planner","forks_url":"https://api.github.com/repos/pnancke/trip-planner/forks","keys_url":"https://api.github.com/repos/pnancke/trip-planner/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pnancke/trip-planner/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pnancke/trip-planner/teams","hooks_url":"https://api.github.com/repos/pnancke/trip-planner/hooks","issue_events_url":"https://api.github.com/repos/pnancke/trip-planner/issues/events{/number}","events_url":"https://api.github.com/repos/pnancke/trip-planner/events","assignees_url":"https://api.github.com/repos/pnancke/trip-planner/assignees{/user}","branches_url":"https://api.github.com/repos/pnancke/trip-planner/branches{/branch}","tags_url":"https://api.github.com/repos/pnancke/trip-planner/tags","blobs_url":"https://api.github.com/repos/pnancke/trip-planner/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pnancke/trip-planner/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pnancke/trip-planner/git/refs{/sha}","trees_url":"https://api.github.com/repos/pnancke/trip-planner/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pnancke/trip-planner/statuses/{sha}","languages_url":"https://api.github.com/repos/pnancke/trip-planner/languages","stargazers_url":"https://api.github.com/repos/pnancke/trip-planner/stargazers","contributors_url":"https://api.github.com/repos/pnancke/trip-planner/contributors","subscribers_url":"https://api.github.com/repos/pnancke/trip-planner/subscribers","subscription_url":"https://api.github.com/repos/pnancke/trip-planner/subscription","commits_url":"https://api.github.com/repos/pnancke/trip-planner/commits{/sha}","git_commits_url":"https://api.github.com/repos/pnancke/trip-planner/git/commits{/sha}","comments_url":"https://api.github.com/repos/pnancke/trip-planner/comments{/number}","issue_comment_url":"https://api.github.com/repos/pnancke/trip-planner/issues/comments{/number}","contents_url":"https://api.github.com/repos/pnancke/trip-planner/contents/{+path}","compare_url":"https://api.github.com/repos/pnancke/trip-planner/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pnancke/trip-planner/merges","archive_url":"https://api.github.com/repos/pnancke/trip-planner/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pnancke/trip-planner/downloads","issues_url":"https://api.github.com/repos/pnancke/trip-planner/issues{/number}","pulls_url":"https://api.github.com/repos/pnancke/trip-planner/pulls{/number}","milestones_url":"https://api.github.com/repos/pnancke/trip-planner/milestones{/number}","notifications_url":"https://api.github.com/repos/pnancke/trip-planner/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pnancke/trip-planner/labels{/name}","releases_url":"https://api.github.com/repos/pnancke/trip-planner/releases{/id}","deployments_url":"https://api.github.com/repos/pnancke/trip-planner/deployments","created_at":"2016-04-13T11:38:49Z","updated_at":"2016-06-02T21:03:39Z","pushed_at":"2016-06-21T07:43:34Z","git_url":"git://github.com/pnancke/trip-planner.git","ssh_url":"git@github.com:pnancke/trip-planner.git","clone_url":"https://github.com/pnancke/trip-planner.git","svn_url":"https://github.com/pnancke/trip-planner","homepage":null,"size":1752,"stargazers_count":1,"watchers_count":1,"language":"Groovy","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":15,"forks":0,"open_issues":15,"watchers":1,"default_branch":"master"}},"base":{"label":"pnancke:master","ref":"master","sha":"2e89de134b94d95b0472d59eded042063d9003b8","user":{"login":"pnancke","id":12659443,"avatar_url":"https://avatars.githubusercontent.com/u/12659443?v=3","gravatar_id":"","url":"https://api.github.com/users/pnancke","html_url":"https://github.com/pnancke","followers_url":"https://api.github.com/users/pnancke/followers","following_url":"https://api.github.com/users/pnancke/following{/other_user}","gists_url":"https://api.github.com/users/pnancke/gists{/gist_id}","starred_url":"https://api.github.com/users/pnancke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pnancke/subscriptions","organizations_url":"https://api.github.com/users/pnancke/orgs","repos_url":"https://api.github.com/users/pnancke/repos","events_url":"https://api.github.com/users/pnancke/events{/privacy}","received_events_url":"https://api.github.com/users/pnancke/received_events","type":"User","site_admin":false},"repo":{"id":56146698,"name":"trip-planner","full_name":"pnancke/trip-planner","owner":{"login":"pnancke","id":12659443,"avatar_url":"https://avatars.githubusercontent.com/u/12659443?v=3","gravatar_id":"","url":"https://api.github.com/users/pnancke","html_url":"https://github.com/pnancke","followers_url":"https://api.github.com/users/pnancke/followers","following_url":"https://api.github.com/users/pnancke/following{/other_user}","gists_url":"https://api.github.com/users/pnancke/gists{/gist_id}","starred_url":"https://api.github.com/users/pnancke/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/pnancke/subscriptions","organizations_url":"https://api.github.com/users/pnancke/orgs","repos_url":"https://api.github.com/users/pnancke/repos","events_url":"https://api.github.com/users/pnancke/events{/privacy}","received_events_url":"https://api.github.com/users/pnancke/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/pnancke/trip-planner","description":"","fork":false,"url":"https://api.github.com/repos/pnancke/trip-planner","forks_url":"https://api.github.com/repos/pnancke/trip-planner/forks","keys_url":"https://api.github.com/repos/pnancke/trip-planner/keys{/key_id}","collaborators_url":"https://api.github.com/repos/pnancke/trip-planner/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/pnancke/trip-planner/teams","hooks_url":"https://api.github.com/repos/pnancke/trip-planner/hooks","issue_events_url":"https://api.github.com/repos/pnancke/trip-planner/issues/events{/number}","events_url":"https://api.github.com/repos/pnancke/trip-planner/events","assignees_url":"https://api.github.com/repos/pnancke/trip-planner/assignees{/user}","branches_url":"https://api.github.com/repos/pnancke/trip-planner/branches{/branch}","tags_url":"https://api.github.com/repos/pnancke/trip-planner/tags","blobs_url":"https://api.github.com/repos/pnancke/trip-planner/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/pnancke/trip-planner/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/pnancke/trip-planner/git/refs{/sha}","trees_url":"https://api.github.com/repos/pnancke/trip-planner/git/trees{/sha}","statuses_url":"https://api.github.com/repos/pnancke/trip-planner/statuses/{sha}","languages_url":"https://api.github.com/repos/pnancke/trip-planner/languages","stargazers_url":"https://api.github.com/repos/pnancke/trip-planner/stargazers","contributors_url":"https://api.github.com/repos/pnancke/trip-planner/contributors","subscribers_url":"https://api.github.com/repos/pnancke/trip-planner/subscribers","subscription_url":"https://api.github.com/repos/pnancke/trip-planner/subscription","commits_url":"https://api.github.com/repos/pnancke/trip-planner/commits{/sha}","git_commits_url":"https://api.github.com/repos/pnancke/trip-planner/git/commits{/sha}","comments_url":"https://api.github.com/repos/pnancke/trip-planner/comments{/number}","issue_comment_url":"https://api.github.com/repos/pnancke/trip-planner/issues/comments{/number}","contents_url":"https://api.github.com/repos/pnancke/trip-planner/contents/{+path}","compare_url":"https://api.github.com/repos/pnancke/trip-planner/compare/{base}...{head}","merges_url":"https://api.github.com/repos/pnancke/trip-planner/merges","archive_url":"https://api.github.com/repos/pnancke/trip-planner/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/pnancke/trip-planner/downloads","issues_url":"https://api.github.com/repos/pnancke/trip-planner/issues{/number}","pulls_url":"https://api.github.com/repos/pnancke/trip-planner/pulls{/number}","milestones_url":"https://api.github.com/repos/pnancke/trip-planner/milestones{/number}","notifications_url":"https://api.github.com/repos/pnancke/trip-planner/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/pnancke/trip-planner/labels{/name}","releases_url":"https://api.github.com/repos/pnancke/trip-planner/releases{/id}","deployments_url":"https://api.github.com/repos/pnancke/trip-planner/deployments","created_at":"2016-04-13T11:38:49Z","updated_at":"2016-06-02T21:03:39Z","pushed_at":"2016-06-21T07:43:34Z","git_url":"git://github.com/pnancke/trip-planner.git","ssh_url":"git@github.com:pnancke/trip-planner.git","clone_url":"https://github.com/pnancke/trip-planner.git","svn_url":"https://github.com/pnancke/trip-planner","homepage":null,"size":1752,"stargazers_count":1,"watchers_count":1,"language":"Groovy","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":15,"forks":0,"open_issues":15,"watchers":1,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/pnancke/trip-planner/pulls/70"},"html":{"href":"https://github.com/pnancke/trip-planner/pull/70"},"issue":{"href":"https://api.github.com/repos/pnancke/trip-planner/issues/70"},"comments":{"href":"https://api.github.com/repos/pnancke/trip-planner/issues/70/comments"},"review_comments":{"href":"https://api.github.com/repos/pnancke/trip-planner/pulls/70/comments"},"review_comment":{"href":"https://api.github.com/repos/pnancke/trip-planner/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/pnancke/trip-planner/pulls/70/commits"},"statuses":{"href":"https://api.github.com/repos/pnancke/trip-planner/statuses/0650a817c14d7196bb20ef55d176e316ae298ac7"}}}}
{"actor":{"display_login":"MZober1993"}}