API Calls
Get Consolidated
GET
https://target-domain.com/consolidated
This endpoint allows you to get the consolidated changes.
{
"@graph": [
{
"@id": "http://data.lblod.info/id/account/0fb4ae50-04af-11ec-a9b1-4120a1f8c146",
"@type": "http://xmlns.com/foaf/0.1/OnlineAccount",
"http://mu.semte.ch/vocabularies/core/uuid": "0fb4ae50-04af-11ec-a9b1-4120a1f8c146",
"http://purl.org/dc/terms/created": {
"@type": "http://www.w3.org/2001/XMLSchema#dateTime",
"@value": "2021-08-24T07:44:07.093Z"
},
"http://purl.org/dc/terms/identifier": "be334098-97ab-4a15-8baf-82e05bad4063",
"http://xmlns.com/foaf/0.1/accountServiceHomepage": {
"@id": "https://github.com/lblod/acmidm-login-service"
}
},
],
"@id": "http://mu.semte.ch/graphs/kalliope/consolidated",
"date": "2021-08-24T13:03:43.296282884Z",
"@context": {
"date": {
"@id": "http://purl.org/dc/terms/date",
"@type": "http://www.w3.org/2001/XMLSchema#dateTime"
}
}
}
Troubleshooting
ACC KAL API returns either:
A 200 response with outdated data, or
400 BAD_REQUEST body:{"message":"Not found: file://share/delta-producer-dumps/dump-organizations/dump-organizations-20230405134201256-a49caa80-d3b7-11ed-bd10-9b648c666422.ttl"}
Cause
Sync from PRD to ACC causes OP to have a missmatch between file meta data and actual files.
This causes problems with the cleanup of old dumps on ACC, which confuses the KAL API which looks for the latest dump.
Fix
Cleanup metadata:
PREFIX prov: <http://www.w3.org/ns/prov#>
PREFIX nie: <http://www.semanticdesktop.org/ontologies/2007/01/19/nie#>
PREFIX dct: <http://purl.org/dc/terms/>
PREFIX dcat: <http://www.w3.org/ns/dcat#>
DELETE {
GRAPH ?g {
?sub dct:subject <http://data.lblod.info/datasets/delta-producer/dumps/OrganizationsCacheGraphDump> ;
dcat:distribution ?distribution.
?distribution
dct:subject ?file;
dct:created ?created.
?phyiscalFile nie:dataSource ?file.
}
} WHERE {
GRAPH ?g {
?sub dct:subject <http://data.lblod.info/datasets/delta-producer/dumps/OrganizationsCacheGraphDump> ;
dcat:distribution ?distribution.
FILTER NOT EXISTS {
?revision prov:wasRevisionOf ?sub.
}
?distribution
dct:subject ?file;
dct:created ?created.
?phyiscalFile nie:dataSource ?file.
}
}
Either wait an hour (max) for a new dump file to be created automatically or trigger the immediate creation:
drc exec delta-producer-bg-jobs-initiator-organizations bash
wget --post-data='' http://localhost/dump-publication-graph-jobs
Inspect the dump file creation:
ls -lrt data/files/delta-producer-dumps/dump-organizations/