Comments (11)
Strange, I don't have an asyncsrv.pl example in the repository... did you write it?
from zguide.
Sorry, my fault. is not the perl that i'm talking about, but the python that is in the repo. (I have also changed the issue title)
from zguide.
I coded this example and it works.. can you tell what do not work? I'm sorry but cant understand your patch
from zguide.
My console output
Client worker-3 startedClient worker-0 started
Client worker-4 startedWorker started
Worker started
Worker started
Worker started
Worker started
Req #1 sent..
Req #1 sent..
Server received worker-0
Req #1 sent..
Worker received worker-0
Server received request #1
Worker received request #1
Server received worker-4
Worker received worker-4
Server received request #1
Worker received request #1
Server received worker-3
Worker received worker-3
Server received request #1
Worker received request #1
^CReq #2 sent..
Req #2 sent..
Req #2 sent..
Server received worker-0
Worker received worker-0
Server received request #2
Worker received request #2
Server received worker-4
Worker received worker-4
Server received request #2
Worker received request #2
Server received worker-3
Worker received worker-3
Server received request #2
Worker received request #2
from zguide.
Sorry, I should tell that on my first post...
The client shouldn't receive any response? AFAICS the client doesn't receive any response.
The patch is what change to able the messages to be send to the clients. Actually i don't understand why the first change is needed (the change of while "scope" by the device call) but it doesn't work before it.
from zguide.
i'll take a look.. what zmq version are you using?
from zguide.
the pyzmq is the last one from your repository and if 'm not wrong the ZMQv2.1.7 (I don't have access to the PC on i have done that)
EDIT:
The ZMQ version was confirmed, 2.1.7
from zguide.
Felipe, thanks for looking at Patrick's issue. If/when you have a new version of asyncsrv.py, give me a shout. :-)
from zguide.
Patrick.. sorry about so late reply
you found a bug :)
checkout this version..
https://github.com/felipecruz/zguide/blob/fc01da8e1e35f5d6e55b28f73e2b725ec061ac2f/examples/Python/asyncsrv.py
if runs ok i`ll do a pull request to the guide
Req #1 sent..
Server received worker-5
Server received request #1
Server received worker-0
Req #1 sent..
Server received request #1
Server received worker-9
Server received request #1
Worker received request #1 from worker-5
Sending to frontend request #1 id worker-5
Sending to frontend request #1 id worker-5
Client worker-5 received: request #1
Sending to frontend request #1 id worker-5
Sending to frontend request #1 id worker-5
Client worker-5 received: request #1
from zguide.
as far as i can see it is ok (i've also tested it). but.... I now understand why the while loop is not running before, (line 62) and in this version the problem persistes when the server frontend receive a message... you should use the same work flow there. This is the diff(erences):
65a66
> _id = frontend.recv()
67c68,69
< print 'Server received %s\n' % (msg)
---
> print 'Server received %s id %s\n' % (msg, _id)
> backend.send(_id, zmq.SNDMORE)
from zguide.
done.
pulling.
thanks man!
from zguide.
Related Issues (20)
- Contradicting description of zero copy receive
- Update to Python examples HOT 1
- hwserver and hwclient erlang example with Chumak
- SUB or XSUB? HOT 4
- C++ examples - ppqueue.cpp : Can't send reply to client
- `examples/C#` causes errors in deployment HOT 3
- Erlang hwserver, hwclient links missing from guide
- cppzmq docs for poll are wrong HOT 3
- wuserver, wuclient Erlang examples not using Chumak
- Erlang files for taskvent, taskwork, tasksink do not use chumak
- zmq guide can not change programming language HOT 9
- Erlang scripts for lpserver and lpclinet not present HOT 1
- Trying to get in touch regarding a security issue
- REQ socket drop message silently if two message coming together very fast
- Pub-Proxy-Sub Mode,High frequency sending long message,easy to cause release error after cache application HOT 2
- C++mdworker,the example running in the linux aborted after throwing an ewhat
- "Experimental" status of ZMQ_PAIR sockets. HOT 6
- Sample clonecli4 does Not Work Due to KVSimple not Handling SUBTREE
- rtreq.cpp
- may be a bug that ttl not handle in pending list HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from zguide.