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

Better URI resolution and comparison #33

Open
justincy opened this issue Apr 24, 2017 · 1 comment
Open

Better URI resolution and comparison #33

justincy opened this issue Apr 24, 2017 · 1 comment

Comments

@justincy
Copy link
Member

justincy commented Apr 24, 2017

In ResourceReference.matches() and some other places, we assume that ResourceReferences are fragment identifiers. However they can also be absolute or relatives URIs. In those latter cases we fail to properly compare them.

Can we provide generic utilities that can solve these problems? I'm worried that we won't always be able to compare.


The current case I'm struggling with is a response for Person Matches from the FamilySearch API. The response is essentially a list of GEDCOM X documents with some metadata in the Atom format. Relationship resource references have absolute URIs even though the persons being pointed to are in the document (yet relationships from other endpoints use fragments identifiers). I can create an FS custom solution for comparing absolute person URIs to person IDs or just use the resourceId property but neither of those will necessarily work for GEDCOM X data from other sources.

@justincy
Copy link
Member Author

If we can't fix our current usage to work in more general situations then we ought to remove the functionality, but that's a breaking change.

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

No branches or pull requests

1 participant