Error in transit option: Encoders are requesting 69 bits, more than 64 bits of edge flags


#1

I followed the instructions given at https://github.com/graphhopper/graphhopper/tree/master/reader-gtfs

I download data for Bogota, Colombia and Executed:

java -Xmx8g -Xms8g
-Dgraphhopper.datareader.file=bogota.osm.pbf
-Dgraphhopper.gtfs.file=gtfs-vbb.zip
-Dgraphhopper.graph.flag_encoders=pt
-Dgraphhopper.prepare.ch.weightings=no
-Dgraphhopper.graph.location=./graph-cache
-Dgraph.bytes_for_flags=12
-jar graphhopper-web-0.12.0.jar server config.yml

Graphhopper return:

2019-05-25 06:31:54.962 [main] INFO i.d.server.DefaultServerFactory - Registering jersey handler with root path prefix: /
2019-05-25 06:31:54.964 [main] INFO i.d.server.DefaultServerFactory - Registering admin handler with root path prefix: /
java.lang.IllegalArgumentException: Encoders are requesting 69 bits, more than 64 bits of edge flags. (Attempt to add EncodedValue car.average_speed) Decrease the number of vehicles or increase the flags to take long via graph.bytes_for_flags: 8
at com.graphhopper.routing.util.EncodingManager.addEncodedValue(EncodingManager.java:350)
at com.graphhopper.routing.util.EncodingManager.addEncoder(EncodingManager.java:329)
at com.graphhopper.routing.util.EncodingManager.access$300(EncodingManager.java:45)
at com.graphhopper.routing.util.EncodingManager$Builder.add(EncodingManager.java:213)
at com.graphhopper.http.GraphHopperBundle.runPtGraphHopper(GraphHopperBundle.java:212)
at com.graphhopper.http.GraphHopperBundle.run(GraphHopperBundle.java:202)
at com.graphhopper.http.GraphHopperBundle.run(GraphHopperBundle.java:64)
at io.dropwizard.setup.Bootstrap.run(Bootstrap.java:200)
at io.dropwizard.cli.EnvironmentCommand.run(EnvironmentCommand.java:42)
at io.dropwizard.cli.ConfiguredCommand.run(ConfiguredCommand.java:87)
at io.dropwizard.cli.Cli.run(Cli.java:78)
at io.dropwizard.Application.run(Application.java:93)
at com.graphhopper.http.GraphHopperApplication.main(GraphHopperApplication.java:33)

But, I compiled the source code with de grasshopper.sh, and execute:

java -Xmx8g -Xms8g
-Dgraphhopper.datareader.file=bogota.osm.pbf
-Dgraphhopper.gtfs.file=gtfs-vbb.zip
-Dgraphhopper.graph.flag_encoders=pt
-Dgraphhopper.prepare.ch.weightings=no
-Dgraphhopper.graph.location=./graph-cache
-Dgraphhopper.graph.bytes_for_flags=12
-jar web/target/graphhopper-web-0.13-SNAPSHOT.jar server config.yml

Apparently works:

2019-05-25 06:38:14.200 [main] INFO o.e.j.server.handler.ContextHandler - Started i.d.j.MutableServletContextHandler@4dc52559{/,null,AVAILABLE}
2019-05-25 06:38:14.208 [main] INFO o.e.jetty.server.AbstractConnector - Started application@7102ac3e{HTTP/1.1,[http/1.1]}{0.0.0.0:8989}
2019-05-25 06:38:14.209 [main] INFO o.e.jetty.server.AbstractConnector - Started admin@3f598450{HTTP/1.1,[http/1.1]}{localhost:8990}
2019-05-25 06:38:14.304 [main] INFO org.eclipse.jetty.server.Server - Started @28414ms

But, not working

I appreciate your help


#2

I’m sorry, it was my mistake.

In version 0.12, does not work.

In version 0.13, working. My mistake was to change port 8889 to 8989 in the file config.yml

Thanks for everything