-
Notifications
You must be signed in to change notification settings - Fork 2
KMS-545: Streamlined download of legacy data to use new KMS endpoint. #39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In both skos:definition and in changeNote, the text is coming in with '. Will need to format text in both places. See 027286de-800d-4141-b17b-6df71fbef30c in concepts_draft
I think this is just your browser showing it, try: |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #39 +/- ##
==========================================
+ Coverage 99.74% 99.79% +0.04%
==========================================
Files 120 120
Lines 1998 1986 -12
Branches 476 471 -5
==========================================
- Hits 1993 1982 -11
+ Misses 5 4 -1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Overview
What is the feature?
The focus of this ticket is to streamline the creation of RDF from a single source, legacy JSON, and no longer use legacy XML. The old code would use both legacy json and xml and now KMS provides a new endpoint that includes all data needed to build RDF from a single source.
What is the Solution?
Updated code to no longer call legacy xml and look in legacy json for all fields when converting to RDF.
Also updated the scripts to use the new endpoint for creating test data, such as published and draft.
What areas of the application does this impact?
syncConceptData has changed to only download the json data and use that for creating the RDF.
The scripts have changed to no longer download individual concepts, but rather the entire json batch which can be used for processing and converting to rdf.
Testing
Test synch data.
Run syncData, i.e., startup offline mode with:
IS_OFFLINE=true SYNC_API_ENDPOINT=https://gcmd.sit.earthdata.nasa.gov SHOULD_SYNC=true RDF4J_SERVICE_URL=http://localhost:8080 serverless offline start
Then try calling the syncData handler.
curl -X POST http://localhost:4001/dev/sync-concept-data -H "Content-Type: application/json" -d '{"version": "published", "versionType": "published"}'
Test scripts that download and create RDF
(Note you'll need to be on VPN, as it is accessing SIT)
npm run download-data
(will download the json data for published and draft)npm run create-rdf-files
(will convert the files to RDF)Check data directory for created files.
Checklist