question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Generate code to support JSON serializing/deserializing as well?

See original GitHub issue

In my company, we want to use wire-generated java code to support json deserialization by adding extra jackson annotations (like @JsonCreator, @JsonProperty and so on) so we made some changes in the wire’s code. I want to check if this is something that wire wants to support because it’s such a common use case that protobuf is introduced later into an json-driven legacy system. If yes I can clean up the code a bit to perhaps add an extra flag like --support-json for that functionality and make a pull request. Thanks.

Issue Analytics

  • State:open
  • Created 8 years ago
  • Comments:17 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
vanvlackcommented, Jul 8, 2015

+1 to extensibility over including directly. Ideally, I could create a MessageWriter of my own, that generates pojo’s how I would like, including the proto bits (or not for that matter).

0reactions
JakeWhartoncommented, Feb 14, 2018

It is intended to be looked at, though, and we value code that looks like it was written by a person.

On Wed, Feb 14, 2018 at 5:11 PM Shadow Man notifications@github.com wrote:

While I agree that qualifying all class names is not something you want to do in manually generated classes, I would also argue that qualified names are not an issue in auto-generated code that isn’t intended to be modified. In fact, it may be seen as a benefit, because now you know right away where that class comes from and why you’re IDE is telling you that “List” is not a “List”.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/square/wire/issues/231#issuecomment-365761908, or mute the thread https://github.com/notifications/unsubscribe-auth/AAEEEc-keJqlvJ24szAAHc7X16A1O-lUks5tU1oIgaJpZM4FRyeH .

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to serialize and deserialize JSON using C# - .NET
How to read JSON as .NET objects (deserialize) · Copy the JSON that you need to deserialize. · Create a class file and...
Read more >
40% faster JSON serialization with Source Generators in .NET 6
Become a Patreon and get source code access: https://www.patreon.com/nickchapsasCheck out my courses: https://nickchapsas.
Read more >
Automatic, well-typed JSON serialization in Reason/OCaml ...
Milk 🥛 is a new tool I developed that generates serialization and deserialization code for your Reason/OCaml types, including types from ...
Read more >
JSON and serialization - Flutter documentation
JSON serialization with code generation means having an external library generate the encoding boilerplate for you. After some initial setup, you run a...
Read more >
Serialization and Deserialization in C# - Code Maze
Between client and server via REST APIs or GRPC · Over the network for messaging systems like Kafka or RabbitMQ · Through firewalls...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found