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] Migrate away from Utf8Json to System.Text.Json for serialization #388

Open
Scrambles56 opened this issue Oct 9, 2023 · 6 comments
Labels
enhancement New feature or request

Comments

@Scrambles56
Copy link
Contributor

Scrambles56 commented Oct 9, 2023

Is your feature request related to a problem?

We currently use a copied and internalized version of Utf8Json, which the upstream is no longer maintained. This not only may leave us open potential unpatched security issues or bugs within Utf8Json, it has also caused or contributed to a handful of other issues #424, #370, #318.

What solution would you like?

Migrate the client's JSON serialization implementation to instead use System.Text.Json.

What alternatives have you considered?

Leaving the Utf8Json implementation as is.

Do you have any additional context?

elasticsearch-net migrated to System.Text.Json in v8


The scope of this issue was expanded by @Xtansia, see below for original issue.

Original Issue Text

Is your feature request related to a problem?

As a developer, I'm trying to reduce the amount of dependencies I'm taking on in my projects, and choose to use Microsofts default JSON serializer, System.Text.Json.

What solution would you like?

An implementation of the IOpenSearchSerializer that uses System.Text.Json, that provides equivalent behaviour to the existing Newtonsoft implementation.

What alternatives have you considered?

At the moment, the fallback is very isolated usage of the Newtonsoft package.

Do you have any additional context?

N/A

@Scrambles56 Scrambles56 added enhancement New feature or request untriaged labels Oct 9, 2023
@Xtansia Xtansia removed the untriaged label Oct 9, 2023
@Xtansia Xtansia changed the title [FEATURE] Add support for System.Text.Json serialization [FEATURE] Migrate away from Utf8Json to System.Text.Json for serialization Nov 13, 2023
@Xtansia
Copy link
Collaborator

Xtansia commented Nov 13, 2023

I've expanded the scope of this issue to instead be migrating away from Utf8Json to System.Text.Json as the primary serialization library of the clients.

@Djcarrillo6
Copy link
Contributor

Hi @Xtansia, I'd like to request assignment on this issue.

@Xtansia
Copy link
Collaborator

Xtansia commented Nov 19, 2023

@Djcarrillo6 You're more than welcome to have a go at this issue

@goldenc
Copy link

goldenc commented Jan 15, 2024

any update on this? we would like to move away from Newtonsoft.Json but its a bit tricky without a proper System.Text.Json open search implementation

@Xtansia
Copy link
Collaborator

Xtansia commented Jan 15, 2024

any update on this? we would like to move away from Newtonsoft.Json but its a bit tricky without a proper System.Text.Json open search implementation

@goldenc There's been no updates yet to the best of my knowledge, I'm unsure if @Djcarrillo6 made any progress. So would be great if anyone was willing to make contributions towards this goal.

@Djcarrillo6
Copy link
Contributor

Yeah @Xtansia I've been running into road block after road block. If anyone else would like to also work on this, please feel free.

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

4 participants