On Fri, 01 Mar 2013 22:34:49 -0400, Arved Sandstrom wrote:
> Apparently this catches out a lot of people, judging by googling. The
> Jackson solutions are many. The point being - leading to my epiphany -
> why the hell is this even a problem?
> I have probably wasted tens of weeks on the arcana of Jersey, Jackson,
> XStream to some extent, JAXB...I'm ditching most all of it. It is an
> obstacle.
> It occurred to me that for over 90 percent of my POJOs I can write
> reliable toJSON() methods that *will not break* and are fully under my
> control in a matter of minutes. For anything more I might give
> simple-json a whirl - it actually has appealing simplicity.
I must admit that if it weren't for the tight tie-in with RESTEasy, I would
likely dump Jackson as well. For something as simple as my use cases, I
find myself having to write a surprising amount of annotations and **** to
make it work right, and for everything there appear to be a myriad of
options that I honestly don't understand ever made it in the standard
release - which is gigantic!
That being said, I can't see myself going to write my own toJSON stuff.
Maybe my development style is too dynamic and fluid, but the mere extra
cost just from refactoring (and the bugs when I forget to properly
refactor) alone makes that an easy decision.
Code generating annotations, on the other hand, appear to be outright
trivial, and certainly much more flexible, and I could see myself writing
my own limit case JSON generating annotations.
But realistically, I won't, because that would just be easy grunt work, and
no part of that would be tricky to figure out, and in the end, I do live
for those tricky problems that are hard to figure out
Liebe Gruesse,
Joerg
--
Ich lese meine Emails nicht, replies to Email bleiben also leider
ungelesen.