Merge lp:~ben-hutchings/ensoft-sextant/render_timeout into lp:ensoft-sextant
Status: | Merged |
---|---|
Approved by: | Robert |
Approved revision: | 29 |
Merged at revision: | 29 |
Proposed branch: | lp:~ben-hutchings/ensoft-sextant/render_timeout |
Merge into: | lp:ensoft-sextant |
Diff against target: |
383 lines (+177/-131) 4 files modified
etc/sextant.conf (+4/-0) src/sextant/__main__.py (+1/-0) src/sextant/environment.py (+13/-3) src/sextant/web/server.py (+159/-128) |
To merge this branch: | bzr merge lp:~ben-hutchings/ensoft-sextant/render_timeout |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Robert | Approve | ||
Review via email: mp+237046@code.launchpad.net |
This proposal supersedes a proposal from 2014-10-01.
Commit message
Refactoring of the _render_plot method - now has a more obvious flow of logic (i.e. will always get to the bottom of the function rather than dropping out in one of the many if/elses).
It should be more straightforward to add more query functions - they are now stored in a dictionary which can be easily added to without changing any of the logic.
Description of the change
Refactoring of the _render_plot method - now has a more obvious flow of logic (i.e. will always get to the bottom of the function rather than dropping out in one of the many if/elses).
It should be more straightforward to add more query functions - they are now stored in a dictionary which can be easily added to without changing any of the logic.
The bulk of the new code is in a block at the bottom of the diff - the whole function has been re-written.
Timing out the neo4j query has proved difficult - it apparently needs a header to
be set on the http request with 'max-execution-
(http://
but attempts to modify the neo4j restclient library to allow this have been thus
far unsuccessful.
This is a bigger fix. In the description, you should explain how you've tested it.
Also, have you tested to see what happens if the Neo4J query takes ages? Ideally we want to abort the query if that is what is taking the time.