Skip to content

Commit 5391ec4

Browse files
committed
feat: added text index and geo spatial features
1 parent ab41054 commit 5391ec4

File tree

6 files changed

+29531
-27
lines changed

6 files changed

+29531
-27
lines changed

Dockerfile

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,18 @@ RUN sed "s|^com\.bigdata.journal\.AbstractJournal\.file=.*|com.bigdata.journal.A
4747
chown jetty.jetty "${JETTY_BASE}/RWStore.properties"
4848

4949

50+
####### Configure RWStore.properties file for lexical index and geospatial
51+
ARG TEXT_INDEX=true
52+
RUN if [ "$TEXT_INDEX" = "true" ]; then \
53+
sed -i -e 's/textIndex=false/textIndex=true/' "${JETTY_BASE}/RWStore.properties"; \
54+
fi
55+
56+
ARG GEO_SPATIAL=true
57+
RUN if [ "$GEO_SPATIAL" = "true" ]; then \
58+
echo "com.bigdata.rdf.store.AbstractTripleStore.geoSpatial=true" >> "${JETTY_BASE}/RWStore.properties"; \
59+
fi
60+
61+
5062
####### Configure startups scrips
5163
COPY helpers/sdaas-st* /
5264
RUN chown jetty.jetty /sdaas-st* ; \

README.md

Lines changed: 28 additions & 26 deletions
Original file line numberDiff line numberDiff line change
@@ -1,40 +1,38 @@
11
![logo](http://linkeddata.center/resources/v4/logo/Logo-colori-trasp_oriz-640x220.png)
22

33
# sdaas-rdfstore
4-
A dockerized blazegraph instance certified for sdaas
5-
6-
The sdaas-rdfstore requires [docker](https://www.docker.com/)
4+
A dockerized blazegraph instance certified for sdaas.
75

6+
By default quadstore, text index and geo spatial features are enabled in the default namespace.
87

9-
## Build local image
8+
The sdaas-rdfstore requires [docker](https://www.docker.com/)
109

11-
docker build -t sdaas-rdfstore .
1210

13-
## Smoke tests
11+
### 🚀 Quickstart
1412

15-
*Note on windows user: define `export MSYS_NO_PATHCONV=1` to avoid unwanted path conversion [see this note](https://stackoverflow.com/questions/7250130/how-to-stop-mingw-and-msys-from-mangling-path-names-given-at-the-command-line#34386471)*
16-
17-
```bash
18-
docker run -d --name rdfstore -p 8080:8080 sdaas-rdfstore
19-
sleep 10;docker exec rdfstore test -f /var/lib/rdfStore/rdfStore.jnl || echo KO
20-
curl -X POST \
21-
--data-binary "LOAD <http://wifo5-03.informatik.uni-mannheim.de/benchmarks-200801/homepages-fixed.nt.gz>" \
22-
--header "Content-Type: application/sparql-update" \
23-
http://localhost:8080/sdaas/sparql || echo KO
13+
```
14+
docker compose up -d --build
15+
sleep 3
16+
curl -X POST --data-binary "ASK {}" --header "Content-Type: application/sparql-query" http://localhost/sdaas/sparql
17+
# should result true
18+
curl -X POST --data-binary "LOAD <http://lp/data/milan.ttl>" --header "Content-Type: application/sparql-update" http://localhost/sdaas/sparql
19+
# should result in mutationCount=28036
2420
```
2521

22+
2623
Test workbench:
2724

28-
- point browser to http://localhost:8080/sdaas to see workbench interface
29-
- in the UPDATE tab, tray executing: `DROP ALL; LOAD <http://wifo5-03.informatik.uni-mannheim.de/benchmarks-200801/homepages-fixed.nt.gz>`
30-
- free docker resource typing `docker rm -f rdfstore`
25+
- point browser to http://localhost/sdaas to see workbench interface
26+
- in the UPDATE tab, tray executing: `DROP ALL; LOAD <http://lp/data/lecco.ttl> INTO GRAPH <urn:graph:test>`. You should read `mutationCount=29241`
27+
- in the QUERY tab, tray executing: `SELECT (COUNT(*) as ?n) {?s?p?o}`. You should read `1205` for "n" variable
28+
- free docker resource typing `docker compose down`
3129

3230
## sdaas-start options
3331

3432
To print sdaas-start usage: `docker run --rm -t sdaas-rdfstore --help`
3533

3634
Smart Data as a Service (SDaaS) knowledge graph engine
37-
Copyright (C) 2018-2020 http://linkeddata.center/
35+
Copyright (C) 2018-2024 http://linkeddata.center/
3836

3937
startup options:
4038

@@ -72,11 +70,15 @@ To persist data and improve performances, you should mount as a fast volume the
7270

7371
To push a new docker image to docker hub:
7472

75-
```bash
76-
docker login
77-
docker build -t linkeddatacenter/sdaas-rdfstore .
78-
docker tag linkeddatacenter/sdaas-rdfstore linkeddatacenter/sdaas-rdfstore:2.1.5
79-
docker push linkeddatacenter/sdaas-rdfstore
80-
docker push linkeddatacenter/sdaas-rdfstore:2.1.5
8173
```
82-
74+
docker login
75+
NAME="linkeddatacenter/sdaas-rdfstore" MAJOR="2" MINOR="2" PATCH="0"
76+
docker build -t $NAME:$MAJOR.$MINOR.$PATCH .
77+
docker tag $NAME:$MAJOR.$MINOR.$PATCH $NAME:$MAJOR.$MINOR
78+
docker tag $NAME:$MAJOR.$MINOR.$PATCH $NAME:$MAJOR
79+
docker tag $NAME:$MAJOR.$MINOR.$PATCH $NAME:latest
80+
docker push $NAME:$MAJOR.$MINOR.$PATCH
81+
docker push $NAME:$MAJOR.$MINOR
82+
docker push $NAME:$MAJOR
83+
docker push $NAME:latest
84+
```

docker-compose.yaml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
version: "3.3"
2+
3+
services:
4+
5+
kb:
6+
image: linkeddatacenter/sdaas-rdfstore
7+
build:
8+
context: .
9+
args:
10+
- TEXT_INDEX=true
11+
- GEO_SPATIAL=true
12+
ports:
13+
- "80:8080"
14+
15+
lp:
16+
image: linkeddatacenter/sdaas-lp
17+
volumes:
18+
- ./tests/data:/var/www/html/data
19+

helpers/sdaas-start

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ _ETC="${SDAAS_STORE_ETC:-"/etc/$_STORENAME"}"
2020
function USAGE {
2121
>&2 cat <<-EOT
2222
Smart Data as a Service (SDaaS) knowledge graph engine
23-
Copyright (C) 2018-2020 http://linkeddata.center/
23+
Copyright (C) 2018-2024 http://linkeddata.center/
2424
2525
startup options:
2626

0 commit comments

Comments
 (0)