Hi,
I followed the README to run the routing application using the given config.yml. I got the following error please assist what I am doing wrong. The end goal is to get the routing engine to route on South African railway only and then integrate with leaflet but first I need to get this prototype running and currently I just cannot run it .Please assist.
root@ctc-tms-dss2 OpenRailRouting]# java -Xmx2500m -Xms50m -Ddw.graphhopper.prepare.ch.weightings=no -Ddw.graphhopper.datareader.file=berlin-latest.osm.pbf -Dgraphhoper.graph.location=graph-cache -Ddw.graphhopper.profiles=freight_diesel -jar target/railway_routing-0.0.1-SNAPSHOT.jar serve config.yml
INFO [2023-08-30 08:32:29,004] org.eclipse.jetty.util.log: Logging initialized @1307ms to org.eclipse.jetty.util.log.Slf4jLog
INFO [2023-08-30 08:32:29,058] io.dropwizard.server.DefaultServerFactory: Registering jersey handler with root path prefix: /
INFO [2023-08-30 08:32:29,059] io.dropwizard.server.DefaultServerFactory: Registering admin handler with root path prefix: /
WARN [2023-08-30 08:32:29,059] de.geofabrik.railway_routing.http.RailwayRoutingServerConfiguration: The key dw.graphhopper.profiles cannot be supplied using Java system properties.
WARN [2023-08-30 08:32:29,059] de.geofabrik.railwayrouting.http.RailwayRoutingServerConfiguration: The key dw.graphhopper.prepare.ch.weightings cannot be supplied using Java system properties.
INFO [2023-08-30 08:32:29,217] io.dropwizard.assets.AssetsBundle: Registering AssetBundle with name: assets for path /maps/
INFO [2023-08-30 08:32:29,219] io.dropwizard.assets.AssetsBundle: Registering AssetBundle with name: assets for path /map-matching/
WARN [2023-08-30 08:32:29,219] io.dropwizard.jetty.setup.ServletEnvironment: Overriding the existing servlet registered with the name: assets
INFO [2023-08-30 08:32:29,223] io.dropwizard.server.ServerFactory: Starting RailwayRoutingApplication
_
| | | | _
/ _| '__/ _ | ' | ' | ' \ / | ' | ' \ / _ \ '|
| (| | | | (| | |) | | | | | | | () | |) | |) | / |
_, || _,| ./|| ||| ||_/| ./| ./ _|_|
|__/ || || ||
INFO [2023-08-30 08:32:29,326] org.eclipse.jetty.setuid.SetUIDListener: Opened application@1bb9aa43{HTTP/1.1, (http/1.1)}{localhost:8989}
INFO [2023-08-30 08:32:29,326] org.eclipse.jetty.setuid.SetUIDListener: Opened admin@420bc288{HTTP/1.1, (http/1.1)}{localhost:8990}
INFO [2023-08-30 08:32:29,329] org.eclipse.jetty.server.Server: jetty-9.4.39.v20210325; built: 2021-03-25T14:42:11.471Z; git: 9fc7ca5a922f2a37b84ec9dbc26a5168cee7e667; jvm 1.8.0_382-b05
INFO [2023-08-30 08:32:29,343] com.graphhopper.GraphHopper: version 6.0|2022-10-25T13:32:20Z (9,21,6,5,2,9)
ERROR [2023-08-30 08:32:29,380] io.dropwizard.cli.ServerCommand: Unable to start server, shutting down
! java.lang.IllegalArgumentException: Encoder stadtbahn not found. Available encoders: [{name=tramtrain, railway=rail;light_rail;tram, electrified=contact_line, voltages=15000;15000;750, frequencies=16.7;16.67;0, gauges=1435, maxspeed=100, speed_factor=11.0, yardSpur=true}, {name=tgv_all, railway=rail, electrified=contact_line, voltages=15000;25000;1500;3000, frequencies=16.7;16.67;50;0, gauges=1435, maxspeed=319, speed_factor=11.0, yardSpur=true}, {name=non_tgv, railway=rail, electrified=, voltages=, frequencies=, gauges=1435, maxspeed=120, speed_factor=5.0, yardSpur=true}, {name=alltracks, railway=rail;light_rail;tram;subway;narrow_gauge, electrified=, voltages=, frequencies=, gauges=, maxspeed=120, speed_factor=5.0, yardSpur=true}, {name=allelectric, railway=rail, electrified=contact_line,yes, voltages=, frequencies=, gauges=, maxspeed=140, speed_factor=5.0, yardSpur=true}]
! at de.geofabrik.railway_routing.RailFlagEncoderFactory.createParser(RailFlagEncoderFactory.java:30)
! at com.graphhopper.GraphHopper.lambda$buildEncodingManagerAndOSMParsers$6(GraphHopper.java:658)
! at java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
! at com.graphhopper.GraphHopper.buildEncodingManagerAndOSMParsers(GraphHopper.java:657)
! at com.graphhopper.GraphHopper.process(GraphHopper.java:788)
! at com.graphhopper.GraphHopper.importOrLoad(GraphHopper.java:760)
! at de.geofabrik.railway_routing.http.RailwayRoutingManaged.start(RailwayRoutingManaged.java:32)
! at io.dropwizard.lifecycle.JettyManaged.doStart(JettyManaged.java:27)
! at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73)
! at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:169)
! at org.eclipse.jetty.server.Server.start(Server.java:423)
! at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:117)
! at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:97)
! at org.eclipse.jetty.server.Server.doStart(Server.java:387)
! at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73)
! at io.dropwizard.cli.ServerCommand.run(ServerCommand.java:53)
! at io.dropwizard.cli.EnvironmentCommand.run(EnvironmentCommand.java:60)
! at io.dropwizard.cli.ConfiguredCommand.run(ConfiguredCommand.java:98)
! at io.dropwizard.cli.Cli.run(Cli.java:78)
! at io.dropwizard.Application.run(Application.java:94)
! at de.geofabrik.railway_routing.http.RailwayRoutingApplication.main(RailwayRoutingApplication.java:36)
java.lang.IllegalArgumentException: Encoder stadtbahn not found. Available encoders: [{name=tramtrain, railway=rail;light_rail;tram, electrified=contact_line, voltages=15000;15000;750, frequencies=16.7;16.67;0, gauges=1435, maxspeed=100, speed_factor=11.0, yardSpur=true}, {name=tgv_all, railway=rail, electrified=contact_line, voltages=15000;25000;1500;3000, frequencies=16.7;16.67;50;0, gauges=1435, maxspeed=319, speed_factor=11.0, yardSpur=true}, {name=non_tgv, railway=rail, electrified=, voltages=, frequencies=, gauges=1435, maxspeed=120, speed_factor=5.0, yardSpur=true}, {name=alltracks, railway=rail;light_rail;tram;subway;narrow_gauge, electrified=, voltages=, frequencies=, gauges=, maxspeed=120, speed_factor=5.0, yardSpur=true}, {name=allelectric, railway=rail, electrified=contact_line,yes, voltages=, frequencies=, gauges=, maxspeed=140, speed_factor=5.0, yardSpur=true}]
at de.geofabrik.railway_routing.RailFlagEncoderFactory.createParser(RailFlagEncoderFactory.java:30)
at com.graphhopper.GraphHopper.lambda$buildEncodingManagerAndOSMParsers$6(GraphHopper.java:658)
at java.util.LinkedHashMap.forEach(LinkedHashMap.java:684)
at com.graphhopper.GraphHopper.buildEncodingManagerAndOSMParsers(GraphHopper.java:657)
at com.graphhopper.GraphHopper.process(GraphHopper.java:788)
at com.graphhopper.GraphHopper.importOrLoad(GraphHopper.java:760)
at de.geofabrik.railway_routing.http.RailwayRoutingManaged.start(RailwayRoutingManaged.java:32)
at io.dropwizard.lifecycle.JettyManaged.doStart(JettyManaged.java:27)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73)
at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:169)
at org.eclipse.jetty.server.Server.start(Server.java:423)
at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:117)
at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:97)
at org.eclipse.jetty.server.Server.doStart(Server.java:387)
at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73)
at io.dropwizard.cli.ServerCommand.run(ServerCommand.java:53)
at io.dropwizard.cli.EnvironmentCommand.run(EnvironmentCommand.java:60)
at io.dropwizard.cli.ConfiguredCommand.run(ConfiguredCommand.java:98)
at io.dropwizard.cli.Cli.run(Cli.java:78)
at io.dropwizard.Application.run(Application.java:94)
at de.geofabrik.railway_routing.http.RailwayRoutingApplication.main(RailwayRoutingApplication.java:36)
Hi, I followed the README to run the routing application using the given config.yml. I got the following error please assist what I am doing wrong. The end goal is to get the routing engine to route on South African railway only and then integrate with leaflet but first I need to get this prototype running and currently I just cannot run it .Please assist.
root@ctc-tms-dss2 OpenRailRouting]# java -Xmx2500m -Xms50m -Ddw.graphhopper.prepare.ch.weightings=no -Ddw.graphhopper.datareader.file=berlin-latest.osm.pbf -Dgraphhoper.graph.location=graph-cache -Ddw.graphhopper.profiles=freight_diesel -jar target/railway_routing-0.0.1-SNAPSHOT.jar serve config.yml INFO [2023-08-30 08:32:29,004] org.eclipse.jetty.util.log: Logging initialized @1307ms to org.eclipse.jetty.util.log.Slf4jLog INFO [2023-08-30 08:32:29,058] io.dropwizard.server.DefaultServerFactory: Registering jersey handler with root path prefix: / INFO [2023-08-30 08:32:29,059] io.dropwizard.server.DefaultServerFactory: Registering admin handler with root path prefix: / WARN [2023-08-30 08:32:29,059] de.geofabrik.railway_routing.http.RailwayRoutingServerConfiguration: The key dw.graphhopper.profiles cannot be supplied using Java system properties. WARN [2023-08-30 08:32:29,059] de.geofabrik.railwayrouting.http.RailwayRoutingServerConfiguration: The key dw.graphhopper.prepare.ch.weightings cannot be supplied using Java system properties. INFO [2023-08-30 08:32:29,217] io.dropwizard.assets.AssetsBundle: Registering AssetBundle with name: assets for path /maps/ INFO [2023-08-30 08:32:29,219] io.dropwizard.assets.AssetsBundle: Registering AssetBundle with name: assets for path /map-matching/ WARN [2023-08-30 08:32:29,219] io.dropwizard.jetty.setup.ServletEnvironment: Overriding the existing servlet registered with the name: assets INFO [2023-08-30 08:32:29,223] io.dropwizard.server.ServerFactory: Starting RailwayRoutingApplication _ | | | | _ / _
| '__/ _
| ' | ' | ' \ / | ' | ' \ / _ \ '| | (| | | | (| | |) | | | | | | | () | |) | |) | / | _, || _,| ./|| ||| ||_/| ./| ./ _|_| |__/ || || || INFO [2023-08-30 08:32:29,326] org.eclipse.jetty.setuid.SetUIDListener: Opened application@1bb9aa43{HTTP/1.1, (http/1.1)}{localhost:8989} INFO [2023-08-30 08:32:29,326] org.eclipse.jetty.setuid.SetUIDListener: Opened admin@420bc288{HTTP/1.1, (http/1.1)}{localhost:8990} INFO [2023-08-30 08:32:29,329] org.eclipse.jetty.server.Server: jetty-9.4.39.v20210325; built: 2021-03-25T14:42:11.471Z; git: 9fc7ca5a922f2a37b84ec9dbc26a5168cee7e667; jvm 1.8.0_382-b05 INFO [2023-08-30 08:32:29,343] com.graphhopper.GraphHopper: version 6.0|2022-10-25T13:32:20Z (9,21,6,5,2,9) ERROR [2023-08-30 08:32:29,380] io.dropwizard.cli.ServerCommand: Unable to start server, shutting down ! java.lang.IllegalArgumentException: Encoder stadtbahn not found. Available encoders: [{name=tramtrain, railway=rail;light_rail;tram, electrified=contact_line, voltages=15000;15000;750, frequencies=16.7;16.67;0, gauges=1435, maxspeed=100, speed_factor=11.0, yardSpur=true}, {name=tgv_all, railway=rail, electrified=contact_line, voltages=15000;25000;1500;3000, frequencies=16.7;16.67;50;0, gauges=1435, maxspeed=319, speed_factor=11.0, yardSpur=true}, {name=non_tgv, railway=rail, electrified=, voltages=, frequencies=, gauges=1435, maxspeed=120, speed_factor=5.0, yardSpur=true}, {name=alltracks, railway=rail;light_rail;tram;subway;narrow_gauge, electrified=, voltages=, frequencies=, gauges=, maxspeed=120, speed_factor=5.0, yardSpur=true}, {name=allelectric, railway=rail, electrified=contact_line,yes, voltages=, frequencies=, gauges=, maxspeed=140, speed_factor=5.0, yardSpur=true}] ! at de.geofabrik.railway_routing.RailFlagEncoderFactory.createParser(RailFlagEncoderFactory.java:30) ! at com.graphhopper.GraphHopper.lambda$buildEncodingManagerAndOSMParsers$6(GraphHopper.java:658) ! at java.util.LinkedHashMap.forEach(LinkedHashMap.java:684) ! at com.graphhopper.GraphHopper.buildEncodingManagerAndOSMParsers(GraphHopper.java:657) ! at com.graphhopper.GraphHopper.process(GraphHopper.java:788) ! at com.graphhopper.GraphHopper.importOrLoad(GraphHopper.java:760) ! at de.geofabrik.railway_routing.http.RailwayRoutingManaged.start(RailwayRoutingManaged.java:32) ! at io.dropwizard.lifecycle.JettyManaged.doStart(JettyManaged.java:27) ! at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73) ! at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:169) ! at org.eclipse.jetty.server.Server.start(Server.java:423) ! at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:117) ! at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:97) ! at org.eclipse.jetty.server.Server.doStart(Server.java:387) ! at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73) ! at io.dropwizard.cli.ServerCommand.run(ServerCommand.java:53) ! at io.dropwizard.cli.EnvironmentCommand.run(EnvironmentCommand.java:60) ! at io.dropwizard.cli.ConfiguredCommand.run(ConfiguredCommand.java:98) ! at io.dropwizard.cli.Cli.run(Cli.java:78) ! at io.dropwizard.Application.run(Application.java:94) ! at de.geofabrik.railway_routing.http.RailwayRoutingApplication.main(RailwayRoutingApplication.java:36) java.lang.IllegalArgumentException: Encoder stadtbahn not found. Available encoders: [{name=tramtrain, railway=rail;light_rail;tram, electrified=contact_line, voltages=15000;15000;750, frequencies=16.7;16.67;0, gauges=1435, maxspeed=100, speed_factor=11.0, yardSpur=true}, {name=tgv_all, railway=rail, electrified=contact_line, voltages=15000;25000;1500;3000, frequencies=16.7;16.67;50;0, gauges=1435, maxspeed=319, speed_factor=11.0, yardSpur=true}, {name=non_tgv, railway=rail, electrified=, voltages=, frequencies=, gauges=1435, maxspeed=120, speed_factor=5.0, yardSpur=true}, {name=alltracks, railway=rail;light_rail;tram;subway;narrow_gauge, electrified=, voltages=, frequencies=, gauges=, maxspeed=120, speed_factor=5.0, yardSpur=true}, {name=allelectric, railway=rail, electrified=contact_line,yes, voltages=, frequencies=, gauges=, maxspeed=140, speed_factor=5.0, yardSpur=true}] at de.geofabrik.railway_routing.RailFlagEncoderFactory.createParser(RailFlagEncoderFactory.java:30) at com.graphhopper.GraphHopper.lambda$buildEncodingManagerAndOSMParsers$6(GraphHopper.java:658) at java.util.LinkedHashMap.forEach(LinkedHashMap.java:684) at com.graphhopper.GraphHopper.buildEncodingManagerAndOSMParsers(GraphHopper.java:657) at com.graphhopper.GraphHopper.process(GraphHopper.java:788) at com.graphhopper.GraphHopper.importOrLoad(GraphHopper.java:760) at de.geofabrik.railway_routing.http.RailwayRoutingManaged.start(RailwayRoutingManaged.java:32) at io.dropwizard.lifecycle.JettyManaged.doStart(JettyManaged.java:27) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73) at org.eclipse.jetty.util.component.ContainerLifeCycle.start(ContainerLifeCycle.java:169) at org.eclipse.jetty.server.Server.start(Server.java:423) at org.eclipse.jetty.util.component.ContainerLifeCycle.doStart(ContainerLifeCycle.java:117) at org.eclipse.jetty.server.handler.AbstractHandler.doStart(AbstractHandler.java:97) at org.eclipse.jetty.server.Server.doStart(Server.java:387) at org.eclipse.jetty.util.component.AbstractLifeCycle.start(AbstractLifeCycle.java:73) at io.dropwizard.cli.ServerCommand.run(ServerCommand.java:53) at io.dropwizard.cli.EnvironmentCommand.run(EnvironmentCommand.java:60) at io.dropwizard.cli.ConfiguredCommand.run(ConfiguredCommand.java:98) at io.dropwizard.cli.Cli.run(Cli.java:78) at io.dropwizard.Application.run(Application.java:94) at de.geofabrik.railway_routing.http.RailwayRoutingApplication.main(RailwayRoutingApplication.java:36)