Skip to content

Promise.all with concurrency limitation implementation #122

Open
@windmemory

Description

@windmemory

Related to wechaty/puppet-service#31

Currently the code logic for roomSearch in wechaty-puppet is not using batch operation, like below:

https://github.com/wechaty/wechaty-puppet/blob/804b31b970e931547238d59de43847178a2869cd/src/puppet.ts#L1174-L1212

When the query is passed to the function, it will do a Promise.all() of all rooms, which might cause the problem that we've been fighting for a long time, the grpc issue. So I think we need to use batch operation for this method to avoid the grpc problem.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions