stops for location cost

26 views
Skip to first unread message

kossavot

unread,
Nov 6, 2021, 4:11:55 PM11/6/21
to onebusaway-developers
Hi,

I'm currently using  the stops-for-location API to to convert the user-facing stop code to the actual stop id before calling the arrivals-and-departures-for-stop API.

Now, stops-for-location in case of my dataset, always returns one result ,that is, for one given stop code there's just one related stop id.

My idea is that the client doesn't necessarily need to call stops-for-location but instead the same operation (stop code -> stop id) can be  implemented in the arrivals-and-departures-for-stop API code before fetching the actual arrivals.
So the client would do just one http call instead of two although stops-for-location can be cached.

I was wondering what could be the implications or side effects if ArrivalsAndDeparturesForStopAction.java is modified to do the stop code -> stop id translation (basically calling _service.getStops() before _service.getStopWithArrivalsAndDepartures() )?

Any drawbacks or negatives ?

Thank you


Reply all
Reply to author
Forward
0 new messages