Details
Diff Detail
- Repository
- rDGRPH Compressed graph representation
- Branch
- aiohttp_server
- Lint
No Linters Available - Unit
No Unit Test Coverage - Build Status
Buildable 7984 Build 11505: tox-on-jenkins Jenkins Build 11504: arc lint + arc unit
Event Timeline
Build has FAILED
Link to build: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/48/
See console output for more information: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/48/console
In addition to the minor comment above, a few bare-bone tests that spawn the aiohttp daemon and try to actually query would be really nice. The toolchain has several moving parts, I can easily see it breaking unexpectedly.
@haltode: I didn't look much at the Java side, can you please have a look when you have a moment? TIA
swh/graph/server/__main__.py | ||
---|---|---|
42 | So, what is the return format here? Is this line-delimited JSON, and would it actually work with common JSON tools, e.g., jq? I'm fine with any approach to stream JSON, but we should make sure it is not an ad hoc format hard to use in practice. | |
swh/graph/server/backend.py | ||
32–33 | these suffixes should be constants | |
35 | left-over comment | |
123 | A prefix="swh-graph." for TemporaryDirectory would be nice here. (Yes, it's already in the FIFO name later, but having it in the dir name would be nice to ls /tmp users. |
FWIW, Jenkins fails on this diff with:
Checking patch java/server/src/main/java/org/softwareheritage/graph/Entry.java... error: java/server/src/main/java/org/softwareheritage/graph/Entry.java: does not exist in index
Looks like a spurious CI error?
Yes, the CI cherrypicked the commit with an incorrect base.
swh/graph/server/__main__.py | ||
---|---|---|
42 | I think you might have misread the code, I don't set the Content-Type to application/json anywhere for these views. |
Build has FAILED
Link to build: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/49/
See console output for more information: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/49/console
swh/graph/server/__main__.py | ||
---|---|---|
42 | oh it was only for stats indeed, my bad |
java/server/src/main/java/org/softwareheritage/graph/Entry.java | ||
---|---|---|
30–32 | We need the snake case conversion to be applied to *all* endpoints, not only the stats. For example in traversal endpoints you have the nbEdgesAccessed metadata that needs to be transformed in snake case. |
- Move example dataset in common tests/dataset directory, add binary maps
- Server API: handle visits of paths
- Server API: reorganize app/main
- API client: update to use the new streaming lines format
- Update tests to work with the new Python server
Build has FAILED
Link to build: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/54/
See console output for more information: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/54/console
Build has FAILED
Link to build: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/55/
See console output for more information: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/55/console
Build has FAILED
Link to build: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/56/
See console output for more information: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/56/console
Build has FAILED
Link to build: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/57/
See console output for more information: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/57/console
Build has FAILED
Link to build: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/58/
See console output for more information: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/58/console
Nice work!
I've only commented on minor stuff here and there.
java/server/src/main/java/org/softwareheritage/graph/Entry.java | ||
---|---|---|
30–32 | Ping on this comment by @haltode. I think you two discussed it on IRC after it, but I'm not 100% sure. | |
67 | a named constant would be nice(r) than -1 | |
75 | The FIFO is created by the client, right? (if not, we have a race condition…) If so this message should be something like "Cannot open client FIFO". | |
swh/graph/cli.py | ||
106 | (nice catch, thanks) | |
swh/graph/server/app.py | ||
1 | the usual copyright/license header is missing here … and while we are at it, a brief docstring stating that this is a proxy server talking to java via py4j + fifo would be welcome too. | |
16 | maybe add a link to https://docs.softwareheritage.org/devel/swh-graph/api.html in the response body? | |
swh/graph/server/backend.py | ||
51 | I've seen this list of simple traversal method names at least twice. Would be nice to have a constant with the list in one of the two module, and used in both cases. | |
55 | … oh, look, here's another place where you can reuse the path separator constant :-) | |
74 | we have this list in swh.model.identifiers.PID_TYPES |
swh/graph/server/__main__.py | ||
---|---|---|
15 | Even if you don't personally like click, it is the standard in the swh codebase and uniformity rocks. | |
18 | Given the multi-file on disk representation of compressed graph, users will have no idea what they should pass here. The help strings should be expanded to explain that. I've tried passing the basename (e.g., all, for a graph stored as all.{compressed,obl,…}, but it didn't work and there was no meaningful error message. |
swh/graph/server/__main__.py | ||
---|---|---|
15 | Oh, and in fact this main.py should be branched as a subcommand of the existing swh graph in cli.py. |
- server: proper JAR deployment method
- server: refactor some constants
- server: refactor handler proxying to backed
- server: move serve command to cli.py
Build has FAILED
Link to build: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/59/
See console output for more information: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/59/console
looks great ! I've only noticed minor stuff (this time for real ;-))
Makefile.local | ||
---|---|---|
4 ↗ | (On Diff #6863) | maybe it's just phabricator playing tricks here, but I see two spaces while it should be 1 TAB |
setup.py | ||
39 ↗ | (On Diff #6863) | I'm a bit worried about what will happen if multiple *.jar files, with different version numbers (e.g., due to previously built versions), are around. Does mvn compile ensure that previous versions will be removed? Is there a way to make it so? |
swh/graph/cli.py | ||
127 | looks like a copy-paste error in the port number, it should be 5009 | |
swh/graph/server/app.py | ||
16 | this is marked as done but it's not actually done in the diff (?) |
- cli: fix rpc-serve default port
- api client: handle stream decoding in swh.graph
- api server: add links to API doc to index
Build has FAILED
Link to build: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/60/
See console output for more information: https://jenkins.softwareheritage.org/job/DGRPH/job/tox/60/console
Makefile.local | ||
---|---|---|
4 ↗ | (On Diff #6863) | Yes, it's already a tab. |
setup.py | ||
39 ↗ | (On Diff #6863) | Here we just install everything. I think the proper way of doing that, theoretically, is to sync the versions between maven and the pypi package through a version.txt or similar, and then just load this one. I can investigate how to do that with our current setup. |