users@javaserverfaces-spec-public.java.net

[jsr344-experts mirror] [jsr344-experts] Re: [1089-PassThroughAttributes] JSON dependency: OK?

From: Neil Griffin <neil.griffin_at_portletfaces.org>
Date: Tue, 26 Jun 2012 15:39:35 -0400

I don't have a crystal ball, but I would assume that very few application developers will be leveraging the JSON feature.

Could the JSF Specification dictate that the JSON implementation be an <optional>true</optional> dependency?
http://maven.apache.org/guides/introduction/introduction-to-optional-and-excludes-dependencies.html

In my experience, application developers sometimes freak out when there are unexpected dependencies that find their way into WAR deployments.

On Jun 26, 2012, at 1:26 PM, Edward Burns wrote:

>>>>>> On Mon, 25 Jun 2012 20:34:02 -0700, Edward Burns <edward.burns_at_oracle.com> said:
>
> EB> * An EL function to adapt JSON to a Map<String, Object>, like this:
>
> EB> <p>
>
> EB> <h:outputText value="json from literal">
>
> EB> <f:passThroughAttributes value="#{p:jsonToMap('{ a : { b : { c : { d : e, f : g }, h : i, j : { k : { l : { m : n } } } } } }')}" />
>
> EB> </h:outputText>
>
> EB> </p>
>
> EB> <p>
>
> EB> <h:outputText value="json from EL">
>
> EB> <f:passThroughAttributes value="#{p:jsonToMap(bean.json)}" />
>
> EB> </h:outputText>
>
> EB> </p>
>
> EB> I'm open to adding additional EL functions if we want to support other
> EB> ways to slurp JSON around.
>
> I need those of you that feel strongly that we should have JSON support
> to voice their opinion here because requiring JSON means an additional
> library dependency. This means that deploying Mojarra to Tomcat now
> requires bundling a JSON impl. The same would be true with MyFaces,
> they'd need to bundle in a JSON impl.
>
> Please confirm that is ok.
>
> Ed
>
> --
> | edward.burns_at_oracle.com | office: +1 407 458 0017
> | homepage: | http://ridingthecrest.com/
> | 17 Business days til JSF 2.2 Public Review to EG