You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@tuscany.apache.org by Paulo Alvim <al...@powerlogic.com.br> on 2010/07/05 21:17:39 UTC

SCA/Tuscany x Portlet JSR 268

Hi Folks,

 

I`m starting with SCA/Tuscany and I have a few conceptual questions: I need
to build some kind of "Dashboard/Portal" application composed by a
"Dashboard View" (a dynamic layout) and various dynamic Dashboard Gadgets
that I'd like to develop in a component model like SCA. 

 

In fact, I could use "Portlet JSR 268" but I would need a traditional
"server centric" Portal product - and my impression is that the portlet
model is old fashioned (although I'm not completely sure). I'd like to have
only one SCA (Java) component that should be able to:

 

- FIRST: Serve "Web Static Content" (HTML5,  CSS3 and  Javascript files) to
be rendered in a dashboard panel/gadget area (this would probably be
persisted locally by using HTML5 Local Persistence) 

- SECOND: To keep RESTful Ajax interations with the client

 

My questions are:

 

1. I didn't find examples of SCA components serving client content (HTML)
directly. The HTML/CSS/JS files are normally deployed in the client
application. But it's a reasonable architecture? Is there any problems to do
that that I can't see (as a begginer)? 

 

2. If it's reasonable: Must I deliver this component as a regular JAR or is
there another more appropriate format in SCA/Tuscany? 

 

3. Does anyone have links (or arguments) about "portlet JSR268 x SCA"?

 

Thanks in advance! I intend to study Tuscany in depth but any tip at this
moment will help me a lot...

 

Paulo Alvim

Brazil

cid:FA3B93058F0F4CFE88ACE408F0D17E64@plcbhdom1.powerlogic.com.br

 


RES: SCA/Tuscany x Portlet JSR 268

Posted by Paulo Alvim <al...@powerlogic.com.br>.
Thanks Luciano!

I also found more useful informations in your blog... thanks a lot

-----Mensagem original-----
De: Luciano Resende [mailto:luckbr1975@gmail.com] 
Enviada em: terça-feira, 6 de julho de 2010 12:02
Para: user@tuscany.apache.org; alvim@powerlogic.com.br
Assunto: Re: SCA/Tuscany x Portlet JSR 268

Ola Paulo, comments inline

On Mon, Jul 5, 2010 at 12:17 PM, Paulo Alvim <al...@powerlogic.com.br> wrote:
>
> Hi Folks,
>
>
>
> I`m starting with SCA/Tuscany and I have a few conceptual questions: I need to build some kind of “Dashboard/Portal” application composed by a “Dashboard View” (a dynamic layout) and various dynamic Dashboard Gadgets that I’d like to develop in a component model like SCA.
>
>
>
> In fact, I could use “Portlet JSR 268” but I would need a traditional “server centric” Portal product – and my impression is that the portlet model is old fashioned (although I’m not completely sure). I’d like to have only one SCA (Java) component that should be able to:
>
>
>
> - FIRST: Serve “Web Static Content” (HTML5,  CSS3 and  Javascript files) to be rendered in a dashboard panel/gadget area (this would probably be persisted locally by using HTML5 Local Persistence)
>
> - SECOND: To keep RESTful Ajax interations with the client
>
> My questions are:
>
> 1. I didn't find examples of SCA components serving client content (HTML) directly. The HTML/CSS/JS files are normally deployed in the client application. But it’s a reasonable architecture? Is there any problems to do that that I can't see (as a begginer)?
>
Here is an example of a service returning images, should be same
scenario as the one you are describing, where you want to basically
send resources back to client.

http://svn.apache.org/repos/asf/incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRImageCollectionImpl.java

  <!-- Component responsible for providing REST access to images -->
    <component name="ImageServiceComponent">
		<implementation.java
class="org.apache.photark.jcr.services.JCRImageCollectionImpl"/>
		<service name="ImageCollection">

			<tuscany:binding.http uri="/gallery"/>
		</service>
		<reference name="repositoryManager" target="RepositoryManager"/>
	</component>
	
You also mentioned you want to have a AJAX iterations between the
client and the services, and you could also see an example of a
"in-progress" REST API at

http://svn.apache.org/repos/asf/incubator/photark/branches/photark-rest/

Some other examples are available in the binding-rest-runtime test scenarios

https://svn.apache.org/repos/asf/tuscany/sca-java-2.x/trunk/modules/binding-rest-runtime/

>
> 2. If it's reasonable: Must I deliver this component as a regular JAR or is there another more appropriate format in SCA/Tuscany?
>

In SCA, you are "delivering" things as contributions, depending on how
you are packing your application you can have jars, zips or even
folder structures as contributions.

>
> 3. Does anyone have links (or arguments) about “portlet JSR268 x SCA”?
>

I don't think these two technologies compete with themselves. SCA
would be used for assembling you services, where you would use JSR268
more towards providing portlets (ui pieces/widgets)  that consume your
SCA services. Having said that, I'm not sure if you are asking more
towards replacing JSR268 with SCA, and if that is your question, let
me put this way, you should be able to build your "ui" that integrates
with your SCA Services as Portlets, JSPs following Java EE standards,
Web 2.0 client applications (you might get some help of SCA Widgets),
etc

>
> Thanks in advance! I intend to study Tuscany in depth but any tip at this moment will help me a lot...
>
> Paulo Alvim
> Brazil
>


--
Luciano Resende
http://people.apache.org/~lresende
http://twitter.com/lresende1975
http://lresende.blogspot.com/


Re: SCA/Tuscany x Portlet JSR 268

Posted by Luciano Resende <lu...@gmail.com>.
Ola Paulo, comments inline

On Mon, Jul 5, 2010 at 12:17 PM, Paulo Alvim <al...@powerlogic.com.br> wrote:
>
> Hi Folks,
>
>
>
> I`m starting with SCA/Tuscany and I have a few conceptual questions: I need to build some kind of “Dashboard/Portal” application composed by a “Dashboard View” (a dynamic layout) and various dynamic Dashboard Gadgets that I’d like to develop in a component model like SCA.
>
>
>
> In fact, I could use “Portlet JSR 268” but I would need a traditional “server centric” Portal product – and my impression is that the portlet model is old fashioned (although I’m not completely sure). I’d like to have only one SCA (Java) component that should be able to:
>
>
>
> - FIRST: Serve “Web Static Content” (HTML5,  CSS3 and  Javascript files) to be rendered in a dashboard panel/gadget area (this would probably be persisted locally by using HTML5 Local Persistence)
>
> - SECOND: To keep RESTful Ajax interations with the client
>
> My questions are:
>
> 1. I didn't find examples of SCA components serving client content (HTML) directly. The HTML/CSS/JS files are normally deployed in the client application. But it’s a reasonable architecture? Is there any problems to do that that I can't see (as a begginer)?
>
Here is an example of a service returning images, should be same
scenario as the one you are describing, where you want to basically
send resources back to client.

http://svn.apache.org/repos/asf/incubator/photark/trunk/photark-jcr/src/main/java/org/apache/photark/jcr/services/JCRImageCollectionImpl.java

  <!-- Component responsible for providing REST access to images -->
    <component name="ImageServiceComponent">
		<implementation.java
class="org.apache.photark.jcr.services.JCRImageCollectionImpl"/>
		<service name="ImageCollection">

			<tuscany:binding.http uri="/gallery"/>
		</service>
		<reference name="repositoryManager" target="RepositoryManager"/>
	</component>
	
You also mentioned you want to have a AJAX iterations between the
client and the services, and you could also see an example of a
"in-progress" REST API at

http://svn.apache.org/repos/asf/incubator/photark/branches/photark-rest/

Some other examples are available in the binding-rest-runtime test scenarios

https://svn.apache.org/repos/asf/tuscany/sca-java-2.x/trunk/modules/binding-rest-runtime/

>
> 2. If it's reasonable: Must I deliver this component as a regular JAR or is there another more appropriate format in SCA/Tuscany?
>

In SCA, you are "delivering" things as contributions, depending on how
you are packing your application you can have jars, zips or even
folder structures as contributions.

>
> 3. Does anyone have links (or arguments) about “portlet JSR268 x SCA”?
>

I don't think these two technologies compete with themselves. SCA
would be used for assembling you services, where you would use JSR268
more towards providing portlets (ui pieces/widgets)  that consume your
SCA services. Having said that, I'm not sure if you are asking more
towards replacing JSR268 with SCA, and if that is your question, let
me put this way, you should be able to build your "ui" that integrates
with your SCA Services as Portlets, JSPs following Java EE standards,
Web 2.0 client applications (you might get some help of SCA Widgets),
etc

>
> Thanks in advance! I intend to study Tuscany in depth but any tip at this moment will help me a lot...
>
> Paulo Alvim
> Brazil
>


--
Luciano Resende
http://people.apache.org/~lresende
http://twitter.com/lresende1975
http://lresende.blogspot.com/