AKSW / building-navigator

The Gebäude-Navigator helps you to find accessible places in Leipzig.
https://behindertenverband-leipzig.de/gebaeude-navigator
GNU General Public License v3.0
3 stars 2 forks source link

Navigation component #54

Closed simeonackermann closed 6 years ago

simeonackermann commented 6 years ago

To implement the routing component, a routing service is required.

Available routing services are:

Questions:

k00ni commented 6 years ago

First a short feedback for each system.

mapbox

graphhopper

Project OSRM + Nominatim

I prefer mapbox, because they allow the most requests per day. But i am trust you, if you think another system fits better. Whats important for me is, that we have no fees, only services (not self-hosted) and if the routing-system stops working (e.g. if limitations reached), our app must keep working.

simeonackermann commented 6 years ago

Mapbox has its terms of services here: https://www.mapbox.com/tos/#geocoding and it says:

You may only use responses from the Geocoding API ("Geocodes") in conjunction with a Mapbox map.

That means we cannot use it, as we are using openstreetmap. The curious thing I wondered about is why the leaflet-routing plugin implements it.

OSRM should has its limitations here: https://github.com/Project-OSRM/osrm-backend/wiki/Api-usage-policy, but this page has only content in the history: https://github.com/Project-OSRM/osrm-backend/wiki/Api-usage-policy/_compare/5e5903fd7eb36fa8c56a178695edc7c030a7bf75

Its similar like Nomination: https://operations.osmfoundation.org/policies/nominatim/, which mainly brings 1 request per seconds as limitation.

k00ni commented 6 years ago

OK, and what will you do now?

simeonackermann commented 6 years ago

Currently I'm using OSRM and its working fine.

I also asked the mapbox support about the usage with leaflet.

simeonackermann commented 6 years ago

Ok, I got an answer of the Support. Mapbox is only available with the mapbox map.

simeonackermann commented 6 years ago

After playing around with OSRM/Nomination I already had issues with Too many requests (it seems a bit buggy, because I also get them after a longer time of waiting).

As an alternative, we could implement the mapbox routing. Its allowed if we even use the mapbox tiles (the images of the map), that is very easy to implement (just changing an url). BUT the style looks different than currently. A list of styles is available here: https://www.mapbox.com/maps/ . For us the mapbox streets might be the best. Its also possible to change all element styles on the map, but I think the default should be ok for the moment.

What do you say, staying purely OSM without navigation or using Mapbox with navigtion?

k00ni commented 6 years ago

Ok, so do you mean OSRM/Nomination is still valid?

Its allowed if we even use the mapbox tiles (the images of the map), that is very easy to implement (just changing an url).

Did they replace our OSM tiles/images? Can you paste me an image, of how it would looks like in the end?

I currently don't understand what each solution can bring to the table, also can't follow you on all the problems you mentioned. Whats important for me is:

I would suggest you try out the solution you prefer in a separate branch. If you gotten to a certain point, please send me some screenshots displaying the new solution. That would be great.

simeonackermann commented 6 years ago

Visually the only thing which would change with mapbox is the style of the map like the following:

bildschirmfoto vom 2018-05-30 10-25-49

Compared to the current:

bildschirmfoto vom 2018-05-30 10-24-41

Butt there are a lot more styles possible

simeonackermann commented 6 years ago
k00ni commented 6 years ago

Looks good. Can i still find information about local stores, like restaurants, in the map, displayed by icon? OSM provides such useful information currently.

simeonackermann commented 6 years ago

Stores, public buildings, restaurants etc are still available. In the end its the OSM data with another style

k00ni commented 6 years ago

Stores, public buildings, restaurants etc are still available. In the end its the OSM data with another style

Great! Mapbox data even looks a little bit cleaner. Would you mind adding a few words to our documentation (e.g. Mapbox) about how we use it? Do you we have to expand our license information for Mapbox?

simeonackermann commented 6 years ago

Great! Mapbox data even looks a little bit cleaner

Even my view.

As attribution we only have to add Mapbox beside the OpenStreetmap link on the right bottom on the map.

simeonackermann commented 6 years ago

Allright. The navigation component is implemented on branch round-4-navigation and even with rdfstorejs on round-4-rdfstorejs-navigation (handy for demonstration purposes).

The implemention details are listed in commit 2fdba262491c2961f959fa425543d4edf752b858

You can see a working demo at http://asimeon.de/building-navigator/

k00ni commented 6 years ago

I will send the demo to the BVL and Co. so that can get an impression of the new feature. Thank you!

k00ni commented 6 years ago

Is there a login to see how many requests were made in a months? Is this thing working via API key?

simeonackermann commented 6 years ago

Yes, but its currently my account. I will create I account for the Building Navigator...

k00ni commented 6 years ago

Do you use an API key? If so, how can we manage, that nobody else uses our key? That is especially important if you think of deployment or versioning control.

simeonackermann commented 6 years ago

I created a new mapbox account for the building-navigator. After login at https://www.mapbox.com/signin/ you can see the stats of map/navigatio requests. I will send you the login data via mail.

simeonackermann commented 6 years ago

To use mapbox the usage of an API key is required and there is currently no way to totally hide it. The only way to do this would be a proxy server.

Some other solutions, like rotating the key after some time, are listed at https://www.mapbox.com/help/how-to-use-mapbox-securely/

k00ni commented 6 years ago

Can you send me the access credentials to Mapbox please?

This issue seems done, isn't it?

simeonackermann commented 6 years ago

Further navigation TODO #57