Max has posted comments on this change. ( https://gerrit.osmocom.org/12139 )

Change subject: ctrl2cgi: properly limit number of requests
......................................................................


Patch Set 1:

(3 comments)

https://gerrit.osmocom.org/#/c/12139/1//COMMIT_MSG
Commit Message:

https://gerrit.osmocom.org/#/c/12139/1//COMMIT_MSG@9
PS1, Line 9: Manual acquire()/release() of semaphore does not limit number of
> How did you arrive to this conclusion?
That's the result of testing - see related ticket.


https://gerrit.osmocom.org/#/c/12139/1/scripts/ctrl2cgi.py
File scripts/ctrl2cgi.py:

https://gerrit.osmocom.org/#/c/12139/1/scripts/ctrl2cgi.py@a104
PS1, Line 104:
> Could the issue be that the POST request is sent over here? Can you try 
> moving these 3 lines inside  […]
No, because "post" returns deferred object, it does not issue any requests - 
see https://treq.readthedocs.io/en/release-17.8.0/api.html#module-treq


https://gerrit.osmocom.org/#/c/12139/1/scripts/ctrl2cgi.py@a108
PS1, Line 108:
> The API use looks good to me, according to  […]
I think the code using run() is much simpler to read and reason about.



--
To view, visit https://gerrit.osmocom.org/12139
To unsubscribe, or for help writing mail filters, visit 
https://gerrit.osmocom.org/settings

Gerrit-Project: python/osmo-python-tests
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: I47b8b9f5b726ca0905bb7c023d63b325c7f7d85f
Gerrit-Change-Number: 12139
Gerrit-PatchSet: 1
Gerrit-Owner: Max <[email protected]>
Gerrit-Reviewer: Jenkins Builder (1000002)
Gerrit-Reviewer: Max <[email protected]>
Gerrit-Reviewer: Pau Espin Pedrol <[email protected]>
Gerrit-Reviewer: daniel <[email protected]>
Gerrit-Comment-Date: Wed, 05 Dec 2018 15:20:40 +0000
Gerrit-HasComments: Yes
Gerrit-HasLabels: No

Reply via email to