opentripplanner / OpenTripPlanner

An open source multi-modal trip planner
http://www.opentripplanner.org
Other
2.22k stars 1.03k forks source link

Remove StateData #2879

Closed abyrd closed 2 years ago

abyrd commented 5 years ago

As an AStar search progresses it makes new States at each iteration. When we handled transit within AStar, there was a lot of Transit-related data that didn't change from one State to the next. Many fields were pulled out into StateData object that would change less often. In OTP2 transit is handled by Raptor, so we need a lot fewer fields in AStar States.

We still plan to keep the State immutable, and use StateEditors (or Builders) to copy them. But we'll remove the two-tiered structure and just clone all the fields in the State.

So many fields have been removed that this new approach should still use less memory than the older approach.

github-actions[bot] commented 2 years ago

This issue is stale because it has been open 90 days with no activity. Remove stale label or comment or this will be closed in 30 days