You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@struts.apache.org by Lukasz Lenart <lu...@apache.org> on 2017/11/10 08:08:07 UTC
JSON & XML serialisation
Hi,
I wonder what would be a better solution to replace existing content
handlers in the REST plugin, there are basically two options:
- Java API for JSON Processing - a standard lib
http://www.oracle.com/technetwork/articles/java/json-1973242.html
- The Apache Juneau project
http://juneau.apache.org/#marshall.html
Any comments?
Regards
--
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org
Re: JSON & XML serialisation
Posted by Lukasz Lenart <lu...@apache.org>.
2017-11-10 9:49 GMT+01:00 Greg Huber <gr...@gmail.com>:
> Would use Jackson for serialization etc. OK, not an apache project though.
Support for Jackson is already there but it isn't a default choice,
maybe we should just switch :)
Regards
--
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org
Re: JSON & XML serialisation
Posted by Greg Huber <gr...@gmail.com>.
Would use Jackson for serialization etc. OK, not an apache project though.
On 10 November 2017 at 08:08, Lukasz Lenart <lu...@apache.org> wrote:
> Hi,
>
> I wonder what would be a better solution to replace existing content
> handlers in the REST plugin, there are basically two options:
>
> - Java API for JSON Processing - a standard lib
> http://www.oracle.com/technetwork/articles/java/json-1973242.html
>
> - The Apache Juneau project
> http://juneau.apache.org/#marshall.html
>
> Any comments?
>
>
> Regards
> --
> Łukasz
> + 48 606 323 122 http://www.lenart.org.pl/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
>
>
Re: JSON & XML serialisation
Posted by Lukasz Lenart <lu...@apache.org>.
2017-11-10 9:08 GMT+01:00 Lukasz Lenart <lu...@apache.org>:
> Hi,
>
> I wonder what would be a better solution to replace existing content
> handlers in the REST plugin, there are basically two options:
>
> - Java API for JSON Processing - a standard lib
> http://www.oracle.com/technetwork/articles/java/json-1973242.html
>
> - The Apache Juneau project
> http://juneau.apache.org/#marshall.html
I think the best option will be switching to Jackson in Struts 2.6
with option to switch back to json-lib. And we can think about adding
other options if needed (maybe via plugins developed in struts-extras)
Regards
--
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org
Re: AW: JSON & XML serialisation
Posted by Yasser Zamani <ya...@live.com>.
On 11/10/2017 1:07 PM, Christoph.Nenning@bmw.de wrote:
> Hi,
>
> I would prefer standardized "Java API for JSON Processing" just to avoid another dependency forced on applications.
>
Doesn't this force user to use a specific jdk version? I also worry for
any issue, we have to wait for long time for the next jdk; even after
the jdk release, usually people cannot upgrade easily ;) I wonder why
java want to ship json into jdk, at all!
> It seems to me selection of json library is like selection of logging lib. There are some options and everyone wants to use something different. It is hard for a framework to choose one as that is forced on applications.
+1 I already enabled custom json writer and think it should not be so
hard to bring the json implementation to user choice completely. just
should break some current specific options and let user choice options
as wish via his/her provided library ;)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org
Re: JSON & XML serialisation
Posted by Lukasz Lenart <lu...@apache.org>.
2017-11-10 10:37 GMT+01:00 <Ch...@bmw.de>:
> I would prefer standardized "Java API for JSON Processing" just to avoid another dependency forced on applications.
Json API is available since JavaEE 7 which means we have to switch to
Java 8 first, right? BTW. I am really lost in all those JSRs and which
lib I should use :P
> It seems to me selection of json library is like selection of logging lib. There are some options and everyone wants to use something different. It is hard for a framework to choose one as that is forced on applications.
I'm looking for alternatives mostly because of security
vulnerabilities or a given lib is outdated (like json-lib we are using
right now in the REST plugin)
Regards
--
Łukasz
+ 48 606 323 122 http://www.lenart.org.pl/
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org
AW: JSON & XML serialisation
Posted by Ch...@bmw.de.
Hi,
I would prefer standardized "Java API for JSON Processing" just to avoid another dependency forced on applications.
It seems to me selection of json library is like selection of logging lib. There are some options and everyone wants to use something different. It is hard for a framework to choose one as that is forced on applications.
Regards,
Christoph
>
> Hi,
>
> I wonder what would be a better solution to replace existing content
> handlers in the REST plugin, there are basically two options:
>
> - Java API for JSON Processing - a standard lib
> http://www.oracle.com/technetwork/articles/java/json-1973242.html
>
> - The Apache Juneau project
> http://juneau.apache.org/#marshall.html
>
> Any comments?
>
>
> Regards
> --
> Łukasz
> + 48 606 323 122 http://www.lenart.org.pl/
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org