New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use parameters instead of custom profile upload #666
Comments
Yes, that would be one of the tasks with some higher priority. @abrensch mentioned a while ago that those are only a hack:
What is the current state there? |
It seems like it hasn't changed much. The special handling for |
subtile difference between "provided by/to the profiles" The way I did it in KinematicModel is to inject the url-parameter when the Model queries a parameter from the profile (If you look at https://github.com/abrensch/brouter/blob/master/brouter-core/src/main/java/btools/router/StdModel.java here the parameter keyValues of the init method is ignored) But that means it does not work for parameters which are used BY the profile. So we would need to inject the parameter before the profile is parsed, same way/same syntax as BRouter-Web already does it. And be careful with profile caching to invalid a cached profile when a url-param changes, , but that should be o.k. already ( rc.getKeyValueChecksum() is part of the cache-key in https://github.com/abrensch/brouter/blob/master/brouter-core/src/main/java/btools/router/ProfileCache.java ) |
This is done in lib 1.6.4. |
Best would actually be to be able to upload a profile from a URL. This way, we could store our profile on our personal github for example and then just upload it from a "raw" url to the file. |
Currently changing profile parameters using brouter-web causes a new custom profile to be uploaded to BRouter. Because custom profiles are only cached and not stored persistently the brouter-web URL doesn't contain a reference of the profile. I sometimes store routes as bookmarks, but this doesn't work for profiles with adapted parameters.
BRouter provides an undocumented way to pass profile parameters as parameters of the request which would offer the possibility for persistent urls even with adapted parameters.
The text was updated successfully, but these errors were encountered: