Changeset View
Changeset View
Standalone View
Standalone View
java/server/README.md
Graph service - Server side | Graph service - Server side | ||||
=========================== | =========================== | ||||
Server side Java REST API. | Server side Java REST API. | ||||
Build | Build | ||||
----- | ----- | ||||
```bash | ```bash | ||||
$ mvn compile assembly:single | $ mvn compile assembly:single | ||||
``` | ``` | ||||
Start REST API | Start REST API | ||||
-------------- | -------------- | ||||
```bash | ```bash | ||||
$ java -cp target/swh-graph-0.0.1-jar-with-dependencies.jar \ | $ java -cp target/swh-graph-0.0.2-jar-with-dependencies.jar \ | ||||
org.softwareheritage.graph.App \ | org.softwareheritage.graph.App \ | ||||
<compressed_graph_path> | <compressed_graph_path> | ||||
``` | ``` | ||||
Default port is 5009 (use the `--port` option to change port number). If you | Default port is 5009 (use the `--port` option to change port number). If you | ||||
need timings metadata send back to the client in addition to the result, use the | need timings metadata send back to the client in addition to the result, use the | ||||
`--timings` flag. | `--timings` flag. | ||||
Show All 12 Lines | |||||
```bash | ```bash | ||||
# Graph compression | # Graph compression | ||||
$ cd src/test/dataset | $ cd src/test/dataset | ||||
$ ./generate_graph.sh | $ ./generate_graph.sh | ||||
$ cd ../../../ | $ cd ../../../ | ||||
$ mvn compile assembly:single | $ mvn compile assembly:single | ||||
# Dump mapping files | # Dump mapping files | ||||
$ java -cp target/swh-graph-0.0.1-jar-with-dependencies.jar \ | $ java -cp target/swh-graph-0.0.2-jar-with-dependencies.jar \ | ||||
org.softwareheritage.graph.backend.Setup \ | org.softwareheritage.graph.backend.Setup \ | ||||
src/test/dataset/example.nodes.csv.gz \ | src/test/dataset/example.nodes.csv.gz \ | ||||
src/test/dataset/output/example | src/test/dataset/output/example | ||||
``` | ``` |