DestinyItemManager / DIM

Destiny Item Manager
https://destinyitemmanager.com
MIT License
2.07k stars 643 forks source link

Parallelize moves across weapons and armor #404

Closed bhollis closed 8 years ago

bhollis commented 8 years ago

I know we generally serialize item moves because they have to squeeze through the vault, but one thought I had is that we could separate items by "armor" vs. "weapons" and run those completely in parallel, because weapons and armor have separate vaults.

SunburnedGoose commented 8 years ago

It's serialized because there is a throttle on the request of 1s that we bump to 1.25s. If it wasn't for that, then yes, we could make it parallel.

Now, what we might be able to do... and it's something we would have to test... Does the throttle apply to all requests or is it per endpoint. If it is per endpoint, then we could create channels for each endpoint and perform them in parallel.

We could go further and use the equipAll endpoint to equip all items at one time.

bhollis commented 8 years ago

I definitely want to start using the equipall API.

On Thursday, February 18, 2016, Rick Casey notifications@github.com wrote:

It's serialized because there is a throttle on the request of 1s that we bump to 1.25s. If it wasn't for that, then yes, we could make it parallel.

Now, what we might be able to do... and it's something we would have to test... Does the throttle apply to all requests or is it per endpoint. If it is per endpoint, then we could create channels for each endpoint and perform them in parallel.

We could go further and use the equipAll endpoint to equip all items at one time.

— Reply to this email directly or view it on GitHub https://github.com/DestinyItemManager/DIM/issues/404#issuecomment-185801646 .

Mulchman commented 8 years ago

Could multiple API keys be used to 'parallelize' transfers? I'm referring to something like this Destiny Trials Report issue talks about: https://github.com/DestinyTrialsReport/DestinyTrialsReport/issues/121

SunburnedGoose commented 8 years ago

No. Throttle is IP based based on that issue's comments.

kyleshay commented 8 years ago

linking #323 /EquipItems()

bhollis commented 8 years ago

Yeah, the best we can do is to use EquipItems (and some other move-planning optimizations). The throttling kills dreams of parallelizing requests.