Skip to content
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

Add batch composite sink #4105

Merged
merged 31 commits into from
Aug 4, 2023
Merged

Conversation

olivergrabinski
Copy link
Contributor

@olivergrabinski olivergrabinski commented Jul 25, 2023

Introduces a new batch composite sink. This sink allows to query the blazegraph common namespace for multiple resources at a time. From the resulting graph, we extract the information about each resource (in Delta), and push it to the target sink.

#3890

}
case None =>
elements.traverse {
case e: Elem.SuccessElem[GraphResource] => Task.pure(e.dropped)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It should be possible to make this less verbose

Copy link
Contributor Author

@olivergrabinski olivergrabinski Jul 31, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I added a drop function for Elem. In my mind dropping should only affect SuccessElems, and "dropping" Dropped or Failed Elems should not do anything. The functions that we currently have as dropped, failed, and success should perhaps be called asDropped, asFailed, asSuccess, to reflect that it's a deliberate action? But I didn't make this name change because I don't want to modify too many files that are unrelated to this PR

private def extractGraphResource(gr: GraphResource, fullGraph: Graph) = {
implicit val api: JsonLdApi = JsonLdJavaApi.lenient
fullGraph
.replaceRootNode(iri"${gr.id}/alias")
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We keep with this ?
We will need to document it properly

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not sure how to avoid it. The name can change but that makes only a minor difference. And yes it would have to be documented

@olivergrabinski olivergrabinski marked this pull request as ready for review August 3, 2023 13:14
@imsdu imsdu merged commit da0fc59 into BlueBrain:master Aug 4, 2023
4 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants