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

create legacyIdPrefix parameter for maps and UUIDs #765

Open
banerjek opened this issue May 16, 2024 · 7 comments
Open

create legacyIdPrefix parameter for maps and UUIDs #765

banerjek opened this issue May 16, 2024 · 7 comments
Assignees

Comments

@banerjek
Copy link
Member

Merging multiple systems can involve overlapping identifier values and issues combining map files requiring preprocessing and awkward procedures

Propose legacyIdPrefix parameter for main config (ideally overwritable at the file level) that would be prepended to legacyId before generating UUID and hrid. The prefix should affect only the map, UUID, and hrid so remapping the value itself is unnecessary. This functionality is needed most for instance and holdings maps but may have other applications such as orders or anything that creates deterministic uuids.

Example:

legacyIdPrefix = myprefix
legacyBibId = b1234567

instance map = ["myprefixb1234567", "40785bac-f500-49f0-8aba-2bb19c04eeed", "inmyprefix0000000001"]

@bltravis
Copy link
Collaborator

@banerjek Why would the prefix be in the hrid value?

@banerjek
Copy link
Member Author

That was a goof. It wouldn't be involved in hrid at all, only for creating deterministic uuid

@banerjek
Copy link
Member Author

I just remembered why -- I keep getting libraries that want to set hrid because of external integrations

@bltravis
Copy link
Collaborator

bltravis commented Jul 9, 2024

@banerjek Does this solve that need, though? Wouldn't the prefix break them, as well?

@banerjek
Copy link
Member Author

There are two separate but connected issues here. One is if you're migrating from multiple systems with overlapping identifiers -- you have to prefix them to avoid collisions.

For the external integrations, they have to point to a new endpoint anyway -- but they have the numbers from the previous system stored (sometimes these are scattered across many systems). The prefix can be thought of as part of the endpoint

@bltravis
Copy link
Collaborator

@banerjek Ok. That was what I thought. I guess I just wasn't clear on how they were going to subsequently use the HRID values if a prefix was applied. Are they able to distinguish the initial relationship by integration?

@bltravis
Copy link
Collaborator

@banerjek Maybe we should have a call to discuss.

@bltravis bltravis self-assigned this Jul 11, 2024
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

When branches are created from issues, their pull requests are automatically linked.

2 participants