You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by ant elder <an...@gmail.com> on 2008/04/07 10:22:49 UTC

Re: New SCA JEE spec draft and Tuscany JSP taglib available

On Mon, Mar 31, 2008 at 4:43 PM, ant elder <an...@gmail.com> wrote:

<snip>

One bit I liked was section 5.4.4 about using JSPs with SCA, what we
> currently have in Tuscany is a bit clunky so i've committed some code to
> support the taglib as described in that section.  So now in a JSP you  don't
> need any code for the SCADomain you just declare the taglib:
>
> <%@ taglib uri="http://www.osog.org/sca/sca.tld" prefix="sca" %>
>
> and then define SCA references with:
>
> <sca:reference name="CalculatorServiceComponent"
> type="calculator.CalculatorService" />
>
> I've updated the calclulator webapp sample to demonstrate this -
> https://svn.apache.org/repos/asf/incubator/tuscany/java/sca/samples/calculator-webapp/src/main/webapp/calc.jsp
>
> This seems so much better than our old approach I'd like to change all our
> JSP samples to work like this, what do you guys think?
>
>    ...ant
>

Any comments on this, when no one answers I always worry its because you
think i'm doing something daft ;)

I've been thinking about extending this further so that the taglib is
extensible and other Tuscany extensions can hook in to add their own
processing. That would enable things like the jsonrpc, dwr, etc bindings to
get javascript inserted into the web page without needing any extension
specific script tags in the page so for example we'd be able to get rid of
the scadomain.js script tag stuff.

   ...ant

Re: New SCA JEE spec draft and Tuscany JSP taglib available

Posted by ant elder <an...@gmail.com>.
On Mon, Apr 7, 2008 at 9:22 AM, ant elder <an...@gmail.com> wrote:

>
>
> On Mon, Mar 31, 2008 at 4:43 PM, ant elder <an...@gmail.com> wrote:
>
> <snip>
>
> One bit I liked was section 5.4.4 about using JSPs with SCA, what we
> > currently have in Tuscany is a bit clunky so i've committed some code to
> > support the taglib as described in that section.  So now in a JSP you  don't
> > need any code for the SCADomain you just declare the taglib:
> >
> > <%@ taglib uri="http://www.osog.org/sca/sca.tld" prefix="sca" %>
> >
> > and then define SCA references with:
> >
> > <sca:reference name="CalculatorServiceComponent"
> > type="calculator.CalculatorService" />
> >
> > I've updated the calclulator webapp sample to demonstrate this -
> > https://svn.apache.org/repos/asf/incubator/tuscany/java/sca/samples/calculator-webapp/src/main/webapp/calc.jsp
> >
> > This seems so much better than our old approach I'd like to change all
> > our JSP samples to work like this, what do you guys think?
> >
> >    ...ant
> >
>
> Any comments on this, when no one answers I always worry its because you
> think i'm doing something daft ;)
>
> I've been thinking about extending this further so that the taglib is
> extensible and other Tuscany extensions can hook in to add their own
> processing. That would enable things like the jsonrpc, dwr, etc bindings to
> get javascript inserted into the web page without needing any extension
> specific script tags in the page so for example we'd be able to get rid of
> the scadomain.js script tag stuff.
>
>    ...ant
>

Beavering on with this despite the silence... :)

So one thing I'd like to do related to this JEE spec is to try to get a
sample working that uses callbacks to a web2.0 style client, so like the
chat-sample but using a asynchronous callbacks to send responses to the
browser clients. To demonstrate what i mean i've just committed a new
chat2-sample that does this, its not in the build and doesn't work yet as
most of the runtime code isn't implemented but it shows the idea to get
feedback on the approach. It uses a new <implementation.web> to define the
browser client component and the DWR binding for the async support for the
callbacks. I plan to work on implementing this now, but welcome any
feedback.

   ...ant