update imposm from JSON to YML

pull/45/head
Etienne Trimaille 2018-02-28 12:48:15 +03:00
rodzic 795955f5eb
commit 503b2f9af5
4 zmienionych plików z 604 dodań i 892 usunięć

Wyświetl plik

@ -32,7 +32,7 @@ from sys import stderr
class Importer(object):
def __init__(self):
# Default values which can be overwritten.
# Default values which can be overwritten by environment variable.
self.default = {
'TIME': 120,
'USER': 'docker',
@ -78,8 +78,11 @@ class Importer(object):
self.default[key] = environ[key]
def check_settings(self):
"""Perform various checking."""
"""Perform various checking.
This will run when the container is starting. If an error occurs, the
container will stop.
"""
# Check valid SRID.
if self.default['SRID'] not in ['4326', '3857']:
msg = 'SRID not supported : %s' % self.default['SRID']
@ -113,9 +116,13 @@ class Importer(object):
if f.endswith('.pbf'):
self.osm_file = join(self.default['SETTINGS'], f)
# JSON first then YML (YML is the new format)
if f.endswith('.json'):
self.mapping_file = join(self.default['SETTINGS'], f)
if f.endswith('.yml'):
self.mapping_file = join(self.default['SETTINGS'], f)
if f == 'post-pbf-import.sql':
self.post_import_file = join(self.default['SETTINGS'], f)
@ -135,7 +142,7 @@ class Importer(object):
self.error(msg)
if not self.mapping_file:
msg = 'Mapping file *.json is missing in %s' % self.default['SETTINGS']
msg = 'Mapping file *.yml is missing in %s' % self.default['SETTINGS']
self.error(msg)
if not self.post_import_file:
@ -165,18 +172,21 @@ class Importer(object):
sleep(45)
def create_timestamp(self):
"""Create the timestamp with the undefined value until the real one."""
file_path = join(self.default['SETTINGS'], 'timestamp.txt')
timestamp_file = open(file_path, 'w')
timestamp_file.write('UNDEFINED\n')
timestamp_file.close()
def update_timestamp(self, database_timestamp):
"""Update the current timestamp of the database."""
file_path = join(self.default['SETTINGS'], 'timestamp.txt')
timestamp_file = open(file_path, 'w')
timestamp_file.write('%s\n' % database_timestamp)
timestamp_file.close()
def check_postgis(self):
"""Test connection to PostGIS and create the URI."""
try:
connection = connect(
"dbname='%s' user='%s' host='%s' password='%s'" % (
@ -196,6 +206,7 @@ class Importer(object):
self.default['DATABASE'])
def import_custom_sql(self):
"""Import the custom SQL file into the database."""
self.info('Running the post import SQL file.')
command = ['psql']
command += ['-h', self.default['HOST']]
@ -205,6 +216,7 @@ class Importer(object):
call(command)
def import_qgis_styles(self):
"""Import the QGIS styles into the database."""
self.info('Installing QGIS styles.')
command = ['psql']
command += ['-h', self.default['HOST']]
@ -214,7 +226,10 @@ class Importer(object):
call(command)
def _import_clip_function(self):
"""Create function clean_tables()."""
"""Create function clean_tables().
The user must import the clip shapefile to the database!
"""
self.info('Import clip function.')
command = ['psql']
command += ['-h', self.default['HOST']]
@ -245,16 +260,22 @@ class Importer(object):
return self.cursor.fetchone()[0]
def run(self):
"""First checker."""
osm_tables = self.count_table('osm_%')
if osm_tables < 1:
# It means that the DB is empty. Let's import the PBF file.
self._first_pbf_import()
else:
self.info('The database is not empty. Let\'s import only diff files.')
self.info(
'The database is not empty. Let\'s import only diff files.')
self._import_diff()
if self.default['TIME'] != '0':
self._import_diff()
else:
self.info('No more update to the database. Leaving.')
def _first_pbf_import(self):
"""Run the first PBF import into the database."""
command = ['imposm3', 'import', '-diff', '-deployproduction']
command += ['-overwritecache', '-cachedir', self.default['CACHE']]
command += ['-srid', self.default['SRID']]
@ -325,13 +346,8 @@ class Importer(object):
self.error(msg)
if len(listdir(self.default['IMPORT_QUEUE'])) == 0:
if self.default['TIME'] != '0':
self.info(
'Sleeping for %s seconds.' % self.default['TIME'])
sleep(float(self.default['TIME']))
else:
self.info('No more update to the database. Leaving.')
quit()
self.info('Sleeping for %s seconds.' % self.default['TIME'])
sleep(float(self.default['TIME']))
if __name__ == '__main__':

Wyświetl plik

@ -19,15 +19,21 @@ cd settings
wget -c -O country.pbf http://download.openstreetmap.fr/extracts/africa/south_africa.osm.pbf
```
You must put only one PBF file in the settings folder. Only the last one will be read.
### OSM Features
In `settings`, you can edit the `mapping.json` to customize the PostGIS schema.
In `settings`, you can edit the `mapping.yml` to customize the PostGIS schema.
You can find the documentation about the mapping configuration on the imposm website: https://imposm.org/docs/imposm3/latest/mapping.html
The default file in Docker-OSM is coming from https://raw.githubusercontent.com/omniscale/imposm3/master/example-mapping.yml
### Updates
You can configure the time interval in the docker-compose file. By default, it's two minutes.
If you set the TIME variable to 0, no diff files will be imported. Only the first PBF file.
If you set the TIME variable to 0, no diff files will be imported.
The default update stream is worldwide.
So even if you imported a local PBF, if you don't set a clipping area, you will end with data from all over the world.
### Clipping

Wyświetl plik

@ -1,877 +0,0 @@
{
"generalized_tables": {
"waterareas_gen1": {
"source": "waterareas",
"sql_filter": "ST_Area(geometry)>50000.000000",
"tolerance": 50.0
},
"waterareas_gen0": {
"source": "waterareas_gen1",
"sql_filter": "ST_Area(geometry)>500000.000000",
"tolerance": 200.0
},
"roads_gen0": {
"source": "roads_gen1",
"sql_filter": null,
"tolerance": 200.0
},
"roads_gen1": {
"source": "roads",
"sql_filter": "type IN ('motorway', 'motorway_link', 'trunk', 'trunk_link', 'primary', 'primary_link', 'secondary', 'secondary_link', 'tertiary', 'tertiary_link') OR class IN('railway')",
"tolerance": 50.0
},
"waterways_gen0": {
"source": "waterways_gen1",
"sql_filter": null,
"tolerance": 200
},
"waterways_gen1": {
"source": "waterways",
"sql_filter": null,
"tolerance": 50.0
},
"landusages_gen1": {
"source": "landusages",
"sql_filter": "ST_Area(geometry)>50000.000000",
"tolerance": 50.0
},
"landusages_gen0": {
"source": "landusages_gen1",
"sql_filter": "ST_Area(geometry)>500000.000000",
"tolerance": 200.0
}
},
"tables": {
"landusages": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
},
{
"type": "pseudoarea",
"name": "area",
"key": null
},
{
"args": {
"values": [
"land",
"island",
"heath",
"railway",
"industrial",
"commercial",
"retail",
"residential",
"quarry",
"zoo",
"vineyard",
"orchard",
"scrub",
"hospital",
"place_of_worship",
"theatre",
"cinema",
"nature_reserve",
"parking",
"fuel",
"baracks",
"library",
"college",
"school",
"university",
"golf_course",
"allotments",
"common",
"pitch",
"sports_centre",
"garden",
"recreation_ground",
"village_green",
"wetland",
"grass",
"meadow",
"wood",
"farmland",
"farm",
"farmyard",
"cemetery",
"forest",
"park",
"playground",
"footway",
"pedestrian"
]
},
"type": "enumerate",
"name": "z_order"
}
],
"type": "polygon",
"mapping": {
"amenity": [
"university",
"school",
"college",
"library",
"fuel",
"parking",
"cinema",
"theatre",
"place_of_worship",
"hospital"
],
"barrier": [
"hedge"
],
"leisure": [
"park",
"garden",
"playground",
"golf_course",
"sports_centre",
"pitch",
"stadium",
"common",
"nature_reserve"
],
"tourism": [
"zoo"
],
"natural": [
"wood",
"land",
"scrub",
"wetland",
"heath"
],
"man_made": [
"pier"
],
"aeroway": [
"runway",
"taxiway"
],
"place": [
"island"
],
"military": [
"barracks"
],
"landuse": [
"park",
"forest",
"residential",
"retail",
"commercial",
"industrial",
"railway",
"cemetery",
"grass",
"farmyard",
"farm",
"farmland",
"orchard",
"vineyard",
"wood",
"meadow",
"village_green",
"recreation_ground",
"allotments",
"quarry"
],
"highway": [
"pedestrian",
"footway"
]
}
},
"buildings": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
}
],
"type": "polygon",
"mapping": {
"building": [
"__any__"
]
}
},
"places": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
},
{
"args": {
"values": [
"locality",
"suburb",
"hamlet",
"village",
"town",
"city",
"county",
"region",
"state",
"country"
]
},
"type": "enumerate",
"name": "z_order"
},
{
"type": "integer",
"name": "population",
"key": "population"
}
],
"type": "point",
"mapping": {
"place": [
"country",
"state",
"region",
"county",
"city",
"town",
"village",
"hamlet",
"suburb",
"locality"
]
}
},
"transport_areas": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
}
],
"type": "polygon",
"mapping": {
"railway": [
"station",
"platform"
],
"aeroway": [
"aerodrome",
"terminal",
"helipad",
"apron"
]
}
},
"admin": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
},
{
"type": "integer",
"name": "admin_level",
"key": "admin_level"
}
],
"type": "polygon",
"mapping": {
"boundary": [
"administrative"
]
}
},
"aeroways": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
}
],
"type": "linestring",
"mapping": {
"aeroway": [
"runway",
"taxiway"
]
}
},
"waterways": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
}
],
"type": "linestring",
"mapping": {
"waterway": [
"stream",
"river",
"canal",
"drain",
"ditch"
],
"barrier": [
"ditch"
]
}
},
"barrierways": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
}
],
"type": "linestring",
"mapping": {
"barrier": [
"city_wall",
"fence",
"hedge",
"retaining_wall",
"wall",
"bollard",
"gate",
"spikes",
"lift_gate",
"kissing_gate",
"embankment",
"yes",
"wire_fence"
]
}
},
"transport_points": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
},
{
"type": "string",
"name": "ref",
"key": "ref"
}
],
"type": "point",
"mapping": {
"railway": [
"station",
"halt",
"tram_stop",
"crossing",
"level_crossing",
"subway_entrance"
],
"aeroway": [
"aerodrome",
"terminal",
"helipad",
"gate"
],
"highway": [
"motorway_junction",
"turning_circle",
"bus_stop"
]
}
},
"amenities": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
}
],
"type": "point",
"mapping": {
"amenity": [
"university",
"school",
"library",
"fuel",
"hospital",
"fire_station",
"police",
"townhall"
]
}
},
"barrierpoints": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
}
],
"type": "point",
"mapping": {
"barrier": [
"block",
"bollard",
"cattle_grid",
"chain",
"cycle_barrier",
"entrance",
"horse_stile",
"gate",
"spikes",
"lift_gate",
"kissing_gate",
"fence",
"yes",
"wire_fence",
"toll_booth",
"stile"
]
}
},
"housenumbers_interpolated": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
},
{
"type": "string",
"name": "addr:street",
"key": "addr:street"
},
{
"type": "string",
"name": "addr:postcode",
"key": "addr:postcode"
},
{
"type": "string",
"name": "addr:city",
"key": "addr:city"
},
{
"type": "string",
"name": "addr:inclusion",
"key": "addr:inclusion"
}
],
"type": "linestring",
"mapping": {
"addr:interpolation": [
"__any__"
]
}
},
"roads": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "mapping_value",
"name": "type",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "boolint",
"name": "tunnel",
"key": "tunnel"
},
{
"type": "boolint",
"name": "bridge",
"key": "bridge"
},
{
"type": "direction",
"name": "oneway",
"key": "oneway"
},
{
"type": "string",
"name": "ref",
"key": "ref"
},
{
"type": "wayzorder",
"name": "z_order",
"key": "layer"
},
{
"type": "string",
"name": "access",
"key": "access"
},
{
"type": "string",
"name": "service",
"key": "service"
},
{
"type": "mapping_key",
"name": "class",
"key": null
}
],
"type": "linestring",
"filters": {
"exclude_tags": [
["area", "yes"]
]
},
"mappings": {
"railway": {
"mapping": {
"railway": [
"rail",
"tram",
"light_rail",
"subway",
"narrow_gauge",
"preserved",
"funicular",
"monorail",
"disused"
]
}
},
"roads": {
"mapping": {
"man_made": [
"pier",
"groyne"
],
"highway": [
"motorway",
"motorway_link",
"trunk",
"trunk_link",
"primary",
"primary_link",
"secondary",
"secondary_link",
"tertiary",
"tertiary_link",
"road",
"path",
"track",
"service",
"footway",
"bridleway",
"cycleway",
"steps",
"pedestrian",
"living_street",
"unclassified",
"residential",
"raceway"
]
}
}
}
},
"housenumbers": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
},
{
"type": "string",
"name": "addr:street",
"key": "addr:street"
},
{
"type": "string",
"name": "addr:postcode",
"key": "addr:postcode"
},
{
"type": "string",
"name": "addr:city",
"key": "addr:city"
}
],
"type": "point",
"mapping": {
"addr:housenumber": [
"__any__"
]
}
},
"waterareas": {
"fields": [
{
"type": "id",
"name": "osm_id",
"key": null
},
{
"type": "geometry",
"name": "geometry",
"key": null
},
{
"type": "string",
"name": "name",
"key": "name"
},
{
"type": "mapping_value",
"name": "type",
"key": null
},
{
"type": "pseudoarea",
"name": "area",
"key": null
}
],
"type": "polygon",
"mapping": {
"waterway": [
"riverbank"
],
"landuse": [
"basin",
"reservoir"
],
"natural": [
"water"
],
"amenity": [
"swimming_pool"
],
"leisure": [
"swimming_pool"
]
}
}
}
}

Wyświetl plik

@ -0,0 +1,567 @@
areas:
area_tags: [buildings, landuse, leisure, natural, aeroway]
linear_tags: [highway, barrier]
generalized_tables:
landusages_gen0:
source: landusages_gen1
sql_filter: ST_Area(geometry)>500000.000000
tolerance: 200.0
landusages_gen1:
source: landusages
sql_filter: ST_Area(geometry)>50000.000000
tolerance: 50.0
roads_gen0:
source: roads_gen1
tolerance: 200.0
roads_gen1:
source: roads
sql_filter:
type IN (
'motorway', 'motorway_link', 'trunk', 'trunk_link', 'primary',
'primary_link', 'secondary', 'secondary_link', 'tertiary', 'tertiary_link')
OR class IN('railway')
tolerance: 50.0
waterareas_gen0:
source: waterareas_gen1
sql_filter: ST_Area(geometry)>500000.000000
tolerance: 200.0
waterareas_gen1:
source: waterareas
sql_filter: ST_Area(geometry)>50000.000000
tolerance: 50.0
waterways_gen0:
source: waterways_gen1
tolerance: 200
waterways_gen1:
source: waterways
tolerance: 50.0
tables:
admin:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
- key: admin_level
name: admin_level
type: integer
mapping:
boundary:
- administrative
type: polygon
aeroways:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
mapping:
aeroway:
- runway
- taxiway
type: linestring
amenities:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
mapping:
amenity:
- university
- school
- library
- fuel
- hospital
- fire_station
- police
- townhall
type: point
barrierpoints:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
mapping:
barrier:
- block
- bollard
- cattle_grid
- chain
- cycle_barrier
- entrance
- horse_stile
- gate
- spikes
- lift_gate
- kissing_gate
- fence
- 'yes'
- wire_fence
- toll_booth
- stile
type: point
barrierways:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
mapping:
barrier:
- city_wall
- fence
- hedge
- retaining_wall
- wall
- bollard
- gate
- spikes
- lift_gate
- kissing_gate
- embankment
- 'yes'
- wire_fence
type: linestring
buildings:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
mapping:
building:
- __any__
type: polygon
housenumbers:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
- key: addr:street
name: addr:street
type: string
- key: addr:postcode
name: addr:postcode
type: string
- key: addr:city
name: addr:city
type: string
mapping:
addr:housenumber:
- __any__
type: point
housenumbers_interpolated:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
- key: addr:street
name: addr:street
type: string
- key: addr:postcode
name: addr:postcode
type: string
- key: addr:city
name: addr:city
type: string
- key: addr:inclusion
name: addr:inclusion
type: string
mapping:
addr:interpolation:
- __any__
type: linestring
landusages:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
- name: area
type: webmerc_area
- args:
values:
- land
- island
- heath
- railway
- industrial
- commercial
- retail
- residential
- quarry
- zoo
- vineyard
- orchard
- scrub
- hospital
- place_of_worship
- theatre
- cinema
- nature_reserve
- parking
- fuel
- baracks
- library
- college
- school
- university
- golf_course
- allotments
- common
- pitch
- sports_centre
- garden
- recreation_ground
- village_green
- wetland
- grass
- meadow
- wood
- farmland
- farm
- farmyard
- cemetery
- forest
- park
- playground
- footway
- pedestrian
name: z_order
type: enumerate
mapping:
aeroway:
- runway
- taxiway
amenity:
- university
- school
- college
- library
- fuel
- parking
- cinema
- theatre
- place_of_worship
- hospital
barrier:
- hedge
highway:
- pedestrian
- footway
landuse:
- park
- forest
- residential
- retail
- commercial
- industrial
- railway
- cemetery
- grass
- farmyard
- farm
- farmland
- orchard
- vineyard
- wood
- meadow
- village_green
- recreation_ground
- allotments
- quarry
leisure:
- park
- garden
- playground
- golf_course
- sports_centre
- pitch
- stadium
- common
- nature_reserve
man_made:
- pier
military:
- barracks
natural:
- wood
- land
- scrub
- wetland
- heath
place:
- island
tourism:
- zoo
type: polygon
places:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
- args:
values:
- locality
- suburb
- hamlet
- village
- town
- city
- county
- region
- state
- country
name: z_order
type: enumerate
- key: population
name: population
type: integer
mapping:
place:
- country
- state
- region
- county
- city
- town
- village
- hamlet
- suburb
- locality
type: point
roads:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- name: type
type: mapping_value
- key: name
name: name
type: string
- key: tunnel
name: tunnel
type: boolint
- key: bridge
name: bridge
type: boolint
- key: oneway
name: oneway
type: direction
- key: ref
name: ref
type: string
- key: layer
name: z_order
type: wayzorder
- key: access
name: access
type: string
- key: service
name: service
type: string
- name: class
type: mapping_key
filters:
reject:
area: ["yes"]
mappings:
railway:
mapping:
railway:
- rail
- tram
- light_rail
- subway
- narrow_gauge
- preserved
- funicular
- monorail
- disused
roads:
mapping:
highway:
- motorway
- motorway_link
- trunk
- trunk_link
- primary
- primary_link
- secondary
- secondary_link
- tertiary
- tertiary_link
- road
- path
- track
- service
- footway
- bridleway
- cycleway
- steps
- pedestrian
- living_street
- unclassified
- residential
- raceway
man_made:
- pier
- groyne
type: linestring
transport_areas:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
mapping:
aeroway:
- aerodrome
- terminal
- helipad
- apron
railway:
- station
- platform
type: polygon
transport_points:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
- key: ref
name: ref
type: string
mapping:
aeroway:
- aerodrome
- terminal
- helipad
- gate
highway:
- motorway_junction
- turning_circle
- bus_stop
railway:
- station
- halt
- tram_stop
- crossing
- level_crossing
- subway_entrance
type: point
waterareas:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
- name: area
type: webmerc_area
mapping:
amenity:
- swimming_pool
landuse:
- basin
- reservoir
leisure:
- swimming_pool
natural:
- water
waterway:
- riverbank
type: polygon
waterways:
columns:
- name: osm_id
type: id
- name: geometry
type: geometry
- key: name
name: name
type: string
- name: type
type: mapping_value
mapping:
barrier:
- ditch
waterway:
- stream
- river
- canal
- drain
- ditch
type: linestring