-
Notifications
You must be signed in to change notification settings - Fork 0
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
Feature/use remote schemas #123
Merged
Merged
Changes from all commits
Commits
Show all changes
3 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
4 changes: 2 additions & 2 deletions
4
src/main/java/eu/dissco/backend/domain/annotation/batch/AnnotationEventRequest.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,9 @@ | ||
package eu.dissco.backend.domain.annotation.batch; | ||
|
||
import eu.dissco.backend.schema.AnnotationRequest; | ||
import eu.dissco.backend.schema.AnnotationProcessingRequest; | ||
import java.util.List; | ||
|
||
public record AnnotationEventRequest(List<AnnotationRequest> annotationRequests, | ||
public record AnnotationEventRequest(List<AnnotationProcessingRequest> annotationRequests, | ||
List<BatchMetadata> batchMetadata) { | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
85 changes: 85 additions & 0 deletions
85
src/main/resources/json-schema/annotation-processing-request.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
{ | ||
"$id": "https://schemas.dissco.tech/schemas/fdo-type/annotation/0.3.0/annotation-processing-request.json", | ||
"$schema": "https://json-schema.org/draft/2020-12/schema", | ||
"$comment": "Annotation Version 0.3.0", | ||
"title": "Annotation", | ||
"description": "Annotation sent to the processing service from DiSSCover or a MAS", | ||
"type": "object", | ||
"properties": { | ||
"@id": { | ||
"type": "string", | ||
"description": "The unique identifier (handle) of the Annotation object", | ||
"pattern": "^https:\/\/hdl\\.handle\\.net\/[\\w.]+\/(.){3}-(.){3}-(.){3}", | ||
"examples": [ | ||
"https://hdl.handle.net/20.5000.1025/XXX-XXX-XXX" | ||
] | ||
}, | ||
"@type": { | ||
"type": "string", | ||
"description": "The type of the object, in this case ods:Annotation", | ||
"const": "ods:Annotation" | ||
}, | ||
"ods:ID": { | ||
"type": "string", | ||
"description": "The handle of the annotation. It is a unique identifier for the annotation. It is composed of the handle of the document followed by a slash and a unique identifier for the annotation.", | ||
"pattern": "^https:\/\/hdl\\.handle\\.net\/[\\w.]+\/(.){3}-(.){3}-(.){3}", | ||
"examples": [ | ||
"https://hdl.handle.net/20.5000.1025/XXX-XXX-XXX" | ||
] | ||
}, | ||
"oa:motivation": { | ||
"description": "The motivation for the annotation. Based on a selection of https://www.w3.org/TR/annotation-model/#motivation-and-purpose. The motivation ods:adding is added for DiSSCo's purposes.", | ||
"enum": [ | ||
"ods:adding", | ||
"ods:deleting", | ||
"oa:assessing", | ||
"oa:editing", | ||
"oa:commenting" | ||
] | ||
}, | ||
"oa:motivatedBy": { | ||
"type": "string", | ||
"description": "Describes the reason for the annotation. https://www.w3.org/TR/annotation-vocab/#motivatedby", | ||
"examples": [ | ||
"The country is incorrect" | ||
] | ||
}, | ||
"oa:hasTarget": { | ||
"type": "object", | ||
"description": "Indicates the particular object and part of the object on which the annotation has been made.", | ||
"$ref": "https://schemas.dissco.tech/schemas/fdo-type/annotation/0.3.0/annotation-target.json" | ||
}, | ||
"oa:hasBody": { | ||
"type": "object", | ||
"description": "The body of the annotation contains the specific value of the annotation", | ||
"$ref": "https://schemas.dissco.tech/schemas/fdo-type/annotation/0.3.0/annotation-body.json" | ||
}, | ||
"dcterms:creator": { | ||
"type": "object", | ||
"description": "Contains an ods:Agent object", | ||
"$ref": "https://schemas.dissco.tech/schemas/fdo-type/shared-model/0.3.0/agent.json" | ||
}, | ||
"dcterms:created": { | ||
"type": "string", | ||
"format": "date-time", | ||
"description": "The date and time when the annotation was created. https://purl.org/dc/terms/created" | ||
}, | ||
"ods:placeInBatch": { | ||
"type": "integer", | ||
"description": "The place of the annotation in the batch" | ||
}, | ||
"ods:batchID": { | ||
"type": "string", | ||
"format": "uuid", | ||
"description": "Internally generated PID to identify the batch the annotation was generated by" | ||
} | ||
}, | ||
"required": [ | ||
"oa:motivation", | ||
"oa:hasTarget", | ||
"oa:hasBody", | ||
"dcterms:creator", | ||
"dcterms:created" | ||
], | ||
"additionalProperties": false | ||
} |
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
This needs to be tombstoning no?
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.
this is automatically pulled from schemas.dissco,tech, it's ods:deleted there