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

Multi-path Flow breaks when one path skips the request and parallel>1 #2910

Closed
nan-wang opened this issue Jul 10, 2021 · 0 comments · Fixed by #2911
Closed

Multi-path Flow breaks when one path skips the request and parallel>1 #2910

nan-wang opened this issue Jul 10, 2021 · 0 comments · Fixed by #2911

Comments

@nan-wang
Copy link
Member

nan-wang commented Jul 10, 2021

Describe the bug
When using parallel>1 and the target_peapod is not the one with multiple parallel, it keeps hanging.

from jina import Document, Executor, Flow, requests
class UpExecutor(Executor):
    @requests
    def foo(self, **kwargs):
        print(f'hello, up')
class DownExecutor(Executor):
    @requests
    def foo(self, **kwargs):
        print(f'hello, down')
f = (Flow()
     .add(uses=UpExecutor, parallel=3, name='up')
     .add(uses=DownExecutor, needs='gateway', name='down')
     .join(needs=['up', 'down']))
with f:
    f.post(on='/foo', target_peapod='down', inputs=Document())

Describe how you solve it


Environment

- jina 2.0.6
- jina-proto 0.0.84
- jina-vcs-tag (unset)
- libzmq 4.3.4
- pyzmq 1.20.3
- protobuf 3.17.0
- proto-backend cpp
- grpcio 1.37.1
- pyyaml 5.4.1
- python 3.8.5
- platform Darwin
- platform-release 20.3.0
- platform-version Darwin Kernel Version 20.3.0: Thu Jan 21 00:07:06 PST 2021;
  root:xnu-7195.81.3~1/RELEASE_X86_64
- architecture x86_64
- processor i386
- uid 154505279077031
- session-id 55bd87ac-e185-11eb-b4a4-8c8590467aa7
- uptime 2021-07-10T21:47:14.809177
- ci-vendor (unset)
* JINA_ARRAY_QUANT (unset)
* JINA_CONTROL_PORT (unset)
* JINA_DEFAULT_HOST (unset)
* JINA_DISABLE_UVLOOP (unset)
* JINA_FULL_CLI (unset)
* JINA_HUBBLE_REGISTRY (unset)
* JINA_HUB_CACHE_DIR (unset)
* JINA_HUB_ROOT (unset)
* JINA_LOG_CONFIG (unset)
* JINA_LOG_ID (unset)
* JINA_LOG_LEVEL DEBUG
* JINA_LOG_NO_COLOR (unset)
* JINA_LOG_WORKSPACE (unset)
* JINA_OPTIMIZER_TRIAL_WORKSPACE(unset)
* JINA_POD_NAME (unset)
* JINA_RANDOM_PORT_MAX (unset)
* JINA_RANDOM_PORT_MIN (unset)
* JINA_VCS_VERSION (unset)

Screenshots

nan-wang added a commit that referenced this issue Jul 11, 2021
* fix: fix the issue 2910

* fix: fix a bug in matching target_peapod

* fix: rename tests

* chore: clean up

* fix: revert to re.match
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant