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

Clean up returns from LDP reads #159

Open
dlamoris opened this issue Oct 3, 2024 · 0 comments
Open

Clean up returns from LDP reads #159

dlamoris opened this issue Oct 3, 2024 · 0 comments

Comments

@dlamoris
Copy link
Contributor

dlamoris commented Oct 3, 2024

The GETs for orgs, repos, branches, locks (primarily repos) are returning too much info that are already available via child ldp endpoints. Also to more align with ldp-dc spec, the construct query should include the ldp predicates that indicates org contain repo, repo contain branches, locks, commits.
https://www.w3.org/TR/ldp/#ldpc
example:
desired result for org get (ldp:contains is from basic container, direct container gets more complicated...need more examples):

m-org:open-mbee rdf:type mms:Org ;
	dct:title "OpenMBEE"@en ;
	mms:etag "bea1d206-0fad-40bc-9a4b-6a7692a2141f" ;
	mms:id "open-mbee"  ;
        ldp:contains <http://layer1-service/orgs/open-mbee/repos/new-repo> .

orgs: https://github.com/Open-MBEE/flexo-mms-layer1-service/blob/feat/ldp/src/main/kotlin/org/openmbee/flexo/mms/routes/ldp/OrgRead.kt#L42
Orgs get is including all the orgs' repos' triples even though repos can be gotten via /orgs/{orgid}/repos

repos: https://github.com/Open-MBEE/flexo-mms-layer1-service/blob/feat/ldp/src/main/kotlin/org/openmbee/flexo/mms/routes/ldp/RepoRead.kt#L53
Same issue as orgs, plus it's returning the entire repo metadata graph, which /repos/{repoid}/branches, /repos/{repoid}/locks, /repos/{repoid}/commits should be used instead (commits endpoint is requested from #117 )

branches/locks: https://github.com/Open-MBEE/flexo-mms-layer1-service/blob/feat/ldp/src/main/kotlin/org/openmbee/flexo/mms/routes/ldp/BranchRead.kt#L36
I don't think there's actually anything that uses mms:branch and mms:lock as predicate

@dlamoris dlamoris added this to Flexo Oct 3, 2024
@github-project-automation github-project-automation bot moved this to New in Flexo Oct 3, 2024
@dlamoris dlamoris moved this from New to Backlog in Flexo Oct 3, 2024
@dlamoris dlamoris mentioned this issue Oct 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Backlog
Development

No branches or pull requests

1 participant