Skip to content
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

[FEATURE] how we can download mutiple region at same time. #169

Open
Hamza117411 opened this issue Oct 4, 2024 · 3 comments · May be fixed by #156
Open

[FEATURE] how we can download mutiple region at same time. #169

Hamza117411 opened this issue Oct 4, 2024 · 3 comments · May be fixed by #156
Labels
bug This issue reports broken functionality or another error needs verification This needs to be verified/tested before fixes (or not) can be made

Comments

@Hamza117411
Copy link

What do you want implemented?

FMTCStore('mapStore').download.startForeground(region: downloadable,
skipExistingTiles: true,
skipSeaTiles: true,
maxBufferLength:500,
instanceId:MapFunctions.generateRandomNumber(0, 1000),
)
i have added instance id for multiple downloading.
but when we can all region its just download last region that in queue.

What other alternatives are available?

No response

Can you provide any other information?

No response

Severity

Minimum: Not required for my use

@JaffaKetchup
Copy link
Owner

Hi @Hamza117411,
Can you please add a little more detail if this is not resolved already?
In general, you should also try to avoid downloading multiple regions simultaneously.

@JaffaKetchup JaffaKetchup added bug This issue reports broken functionality or another error needs verification This needs to be verified/tested before fixes (or not) can be made labels Oct 23, 2024
@m-hamza-tanbits
Copy link

image I have created three base regions that need to be downloaded. Currently, I'm unsure whether I should download each region one by one or if it's possible to initiate multiple downloads simultaneously. I've already implemented a random instanceId for each download using the following **instanceId:MapFunctions.generateRandomNumber(0, 1000),** However, the requirement is to download all regions at once, rather than one at a time. How can I modify the current implementation to ensure all regions are downloaded simultaneously?

@JaffaKetchup
Copy link
Owner

JaffaKetchup commented Oct 24, 2024

It may be that the multiple simultaneous download functionality is bugged. When you start each download, are you listening to each individually as a stream? You may need to listen to the download progress stream for it to begin.

However, I'm not sure it is necessary to download them simultaneously. It's likely to reduce the performance of all of them (although a larger buffer might help reduce this, as the database can only have one write at any one time). In v10, there is a new MultiRegion, which will download them sequentially, but in one download - this will remove the setup/teardown costs of multiple sequential downloads, and make it easier to track the progress. You can try this with the latest prerelease (usually stable, but not always for production quality), or by depending on the 'multi-store-provider' branch directly from Git (potentially unstable).

@JaffaKetchup JaffaKetchup linked a pull request Dec 11, 2024 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug This issue reports broken functionality or another error needs verification This needs to be verified/tested before fixes (or not) can be made
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants