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
Updating DefaultIdentifierTranslator to make it usable by audit service #782
Conversation
With what kind of namespaces do you expect people to use this stateful class? |
@ajs6f I started out doing just that -- and then realized that I only needed to change the hard-coded REPOSITORY_NAMESPACE variable to the baseURL, and I could use the DefaultIdentifierConverter. |
I'd rather see this diverge into an |
What is the default value for the namespace at play? |
In the context of Audit, the "default" value is dynamic: |
It is in no way remotely clear to me how that line of code documents the use of the class under comment. At the very least, please let's include some verbal explanation of the new constructor and its parameters. "Default namespace to use for node URIs" and "Construct the graph with the provided resource namespace." doesn't begin to explain the matter. I'm confident that the thought behind this change is valuable, but I really don't understand yet why this is presented as a change to this class and not the basis of a new class. |
I will be available tomorrow morning via IRC or Hangout or what-have-ye. I don't want to hold up the functionality that @escowles is moving forward. But I do have the unpleasant feeling that we aren't all on the same page with respect to the construction of identifiers, and that's such a crucial element of repository work that I'm willing to be annoying about this. |
@ajs6f My initial approach was to create a new implementation in the audit package called Though I'm willing to be convince that I should be using https://github.com/fcrepo4-labs/fcrepo-audit/pull/3/files#diff-3ff409abe3384fddfe4bc7d36c6ce055R261 The task is to update the properties on a newly-created audit event node. Creating the triples is the easy part, but I wasn't able to get an Where the URI matched the template, but there wasn't a |
That all makes good sense, @escowles. I believe @ajs6f is wanting some javadoc-umentation describing something about the use and assumptions of the identifiers that would be created by the new constructor on |
@awoods, I've updated the Javadoc comments to better explain the purpose of the class, differentiate the constructors from each other, and link to HttpResourceConverter. |
In fact, now that I understand what the desire is I don't agree that this is a good change to the class (instead of a new class) but I don't think the difference is worth troubling about. |
@ajs6f, would your suggestion be to create a new class that extends |
The other way around-- to create a class for what @escowles very reasonably wants to do, something like |
…erTranslator extend from that
Thanks. As a TODO to myself, much of what happens with chains of translators inside these converters should be factored out into some abstract class, or post Java 8, default implementation. |
Resolved with: 2c3eb0f |
Addresses https://jira.duraspace.org/browse/FCREPO-1489