-
Notifications
You must be signed in to change notification settings - Fork 195
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix #23821: Ensure that a new layer is loaded ''prior to'' loading ad…
…ditional data to that layer This occurred due to a race condition, whereby the `/load_and_zoom` call would return immediately ''prior to'' the download finishing for the new layer and the next `/load_and_zoom` call merging onto a pre-existing layer. This could be fixed in one of two different ways: 1. Block the RemoteControl thread 2. Have some method for ensuring that a new layer is loaded first While we are effectively doing (1), it was easier to do (2) as well for testing purposes. This means the RemoteControl thread could spin off a thread for each request to `/load_and_zoom` and this particular issue should not reappear. This does ''not'' control for cases where a user calls `/load_and_zoom` like so: 1. `new_layer=true` + `layer_name=first` 2. `new_layer=true` + `layer_name=second` 3. `new_layer=false` + `layer_name=first` 4. `new_layer=false` + `layer_name=second` Both (1) and (2) will complete before (3) and (4) are run. However, both (3) and (4) will be loaded into the ''last layer loaded''. git-svn-id: https://josm.openstreetmap.de/svn/trunk@19153 0c6e7542-c601-0410-84e7-c038aed88b3b
- Loading branch information
taylor.smock
committed
Jul 25, 2024
1 parent
40aafb4
commit 8c1d937
Showing
2 changed files
with
155 additions
and
16 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters