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

[FEATURE] Being able to globally override behaviour(s) of automatic mappings #691

Open
nalka0 opened this issue Jul 4, 2024 · 2 comments
Labels
enhancement New feature or request

Comments

@nalka0
Copy link

nalka0 commented Jul 4, 2024

Is your feature request related to a problem?

For example if I want my properties with type string to be mapped as keyword, I need to manually apply the [Keyword] attribute to all of these properties.

What solution would you like?

Keeping the above example, instead of having to apply the [Keyword] attribute to all properties of type GUID. I'd like to be able to override the automatic mapping behaviour to make it map string properties as 'keyword'.

What alternatives have you considered?

Well as I said above, one could apply the [Keyword] attribute to all of these properties but it doesn't seem sustainable maintenance-wise

Do you have any additional context?

From my understanding, the automatic mapping currently happens in PropertyWalker.InferProperty(PropertyInfo)

@nalka0 nalka0 added enhancement New feature or request untriaged labels Jul 4, 2024
@Xtansia Xtansia removed the untriaged label Jul 4, 2024
@Xtansia
Copy link
Collaborator

Xtansia commented Jul 4, 2024

@nalka0 Do you have any ideas for what you'd like the user experience of this to be? Is this something you might be interested in contributing yourself?

@nalka0
Copy link
Author

nalka0 commented Jul 10, 2024

I'd say at some point (don't know when exactly though) the user could provide a dictionary or something similar that says map this CLR type to this Opensearch type ? If I ever feel familiar enough with the package to do so I guess I could try sending a pull request for this yes

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants