Custom opensearch mappings fix #1019
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Changes proposed ✍️
What
🤖 Generated by Copilot at c0647c5
This pull request improves the translation between Crowd and Opensearch by introducing a new
customTranslation
property for fields that need special handling. It also refactors theMemberTranslator
class to avoid field collisions and improve code quality. The changes affect theopensearch.ts
,members.ts
,memberTranslator.ts
, andfieldTranslator.ts
files.
🤖 Generated by Copilot at c0647c5
Why
How
🤖 Generated by Copilot at c0647c5
customTranslation
property toOpensearchField
interface to allow for custom field mappings between Crowd and Opensearch (link)MemberTranslator
class to inherit fromFieldTranslator
class and move static field translations to parent class (link)id
anduuid_id
field collision inMemberTranslator
class by setting reverse translation foruuid_id
toid
(link)MembersOpensearch
model to usecustomTranslation
property forid
,reach
,identities
, andtags
fields (link, link, link, link)setTranslationMaps
method inFieldTranslator
class to check for custom translations in model and use them instead of default translations (link)Checklist ✅
Feature
,Improvement
, orBug
.