{"id":16841533,"url":"https://github.com/boldtrn/graphhopper-postgis","last_synced_at":"2025-04-11T05:51:31.169Z","repository":{"id":55622444,"uuid":"193664486","full_name":"boldtrn/graphhopper-postgis","owner":"boldtrn","description":"Postgis reader for GraphHopper","archived":false,"fork":false,"pushed_at":"2020-12-17T14:41:29.000Z","size":42,"stargazers_count":16,"open_issues_count":3,"forks_count":4,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-25T03:51:12.873Z","etag":null,"topics":["gis","graphhopper","postgis","postgres","routing"],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/boldtrn.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-06-25T08:14:09.000Z","updated_at":"2023-04-14T17:10:44.000Z","dependencies_parsed_at":"2022-08-15T04:40:47.813Z","dependency_job_id":null,"html_url":"https://github.com/boldtrn/graphhopper-postgis","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/boldtrn%2Fgraphhopper-postgis","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/boldtrn%2Fgraphhopper-postgis/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/boldtrn%2Fgraphhopper-postgis/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/boldtrn%2Fgraphhopper-postgis/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/boldtrn","download_url":"https://codeload.github.com/boldtrn/graphhopper-postgis/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248351417,"owners_count":21089271,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["gis","graphhopper","postgis","postgres","routing"],"created_at":"2024-10-13T12:42:14.466Z","updated_at":"2025-04-11T05:51:31.149Z","avatar_url":"https://github.com/boldtrn.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"# GraphHopper Postgis reader\n\nThis repository is based on the work by [mbasa](https://github.com/mbasa/graphhopper/tree/postgis) and by [PGWelch](https://github.com/graphhopper/graphhopper/pull/874).\n\nPlease note, this is a module for GraphHopper, you will need to combine it with [GraphHopper](https://github.com/graphhopper/graphhopper).\n\nTo get an idea of how to use it, have a look at the [OSMPostgisReaderTest](https://github.com/boldtrn/graphhopper-postgis/blob/master/src/main/test/java/com/graphhopper/reader/postgis/OSMPostgisReaderTest.java).\n\n## Setup Postgres \n\nCreate a Table or View in the specifed database and schema that has these necessary columns (refer to OSM documentation for the proper values of these columns) : \n\n``` \nosm_id, maxspeed, oneway, fclass, name, geom \n```\n\nFurthermore you can add more attributes and refer them in the config key `db.tagsToCopy`. These tags will be copied to the ReaderWay that you can use in your FlagEncoder. \n\nFor example:\n\n``` \n create view philview \n   (osm_id,maxspeed,oneway,fclass,name,geom ) \n   as select id,0,oneway,'tertiary'::text,name,geom from phil;\n```\n\n## Start GraphHopper\n\nPlease note, these instructions are only valid if you add this module to the main GraphHopper. I'd recommend to set it up along the lines of the [GraphHopper MapMatching Repository](https://github.com/graphhopper/map-matching). \n\nStart the GraphHopper server by adding the parameter ``/\u003cpath where graph will reside\u003e/\u003ctable or view name\u003e``. The example below will create a graph, philview-gh, in /Users/mbasa/t for the philveiw view of PostgreSQL:\n\n``` \n./graphhopper.sh web /Users/mbasa/t/philview\n```\n\n## Updating the Graph\n\nIf the data in PostgreSQL changes and the graph has to be updated, just delete the created graph directory and restart GraphHopper using the above method.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fboldtrn%2Fgraphhopper-postgis","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fboldtrn%2Fgraphhopper-postgis","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fboldtrn%2Fgraphhopper-postgis/lists"}