I think we want to target 2.0. Spring 1.0 also supports request-
scoped components - I think you need to look at the TargetSource
implementations for that.
Jim
On May 22, 2006, at 2:27 PM, Raymond Feng wrote:
Here's an addtional point about the Spring scoping:
In Spring 1.x, it only supports singleton or prototype.
Moving in to 2.0 (not released yet), there're new scopes as quoted
below.
========================================================
3.2.3. New bean scopes
Previous versions of Spring had IoC container level support for
exactly two distinct bean scopes (singleton and prototype). Spring
2.0 improves on this by not only providing a number of additional
scopes depending on the environment in which Spring is being
deployed (for example, request and session scoped beans in a web
environment), but also by providing 'hooks' (for want of a better
word) so that Spring users can integrate their own scopes with
(hopefully) a minimum of effort.
It should be noted that although the underlying (and internal)
implementation for singleton- and prototype-scoped beans has been
changed, said change is totally transparent to the end user... no
existing configuration needs to change, and no existing
configuration will break.
========================================================
Thanks,
Raymond
----- Original Message ----- From: "Jim Marino"
<[EMAIL PROTECTED]>
To: <tuscany-dev@ws.apache.org>
Sent: Monday, May 22, 2006 2:01 PM
Subject: Re: [jira] Updated: (TUSCANY-415) Add a Spring container
to Tuscany so that Spring beans can be used as an implementation
for SCA components
Hi Raymond,
I took a look at the implementation and have a few observations:
- It appears that a Spring application context is created for
each method on a bean. Was this intentional, since I would have
thought that a Spring application context would be created per
composite? In other words, for a module, there would be one
Spring application context with many Spring beans in it. This
approach would allow an application developer to use Spring to
wire their beans together. The per method approach won't allow
for this type of wiring.
- The above also leads to operations being dispatched to
different bean instances, which complicates Spring semantics
since it also has the concept of singleton, request and session
scopes where operations are routed to particular instances.
- I'm not sure we need a component type file (or at least it
shouldn't be required). I believe most assembly information can
be introspected from the Spring ApplicationContext, BeanContext,
and BeanWrapper.
In the spec group we have started to discuss Spring integration
and have taken the approach of having a Spring application
context modeled as a composite. Perhaps we could align around
that? I'm happy to help out so if you want to commit it to the
sandbox we can look at together.
Jim
On May 22, 2006, at 1:08 PM, Raymond Feng (JIRA) wrote:
[ http://issues.apache.org/jira/browse/TUSCANY-415?page=all ]
Raymond Feng updated TUSCANY-415:
---------------------------------
Attachment: tuscany-container-spring.zip
Here's a prototype which allows Tuscany consumes components
implemented as a Spring bean.
Add a Spring container to Tuscany so that Spring beans can be
used as an implementation for SCA components
-------------------------------------------------------------------
-- -------------------------------------
Key: TUSCANY-415
URL: http://issues.apache.org/jira/browse/TUSCANY-415
Project: Tuscany
Type: New Feature
Versions: Java-Mx
Reporter: Raymond Feng
Assignee: Raymond Feng
Fix For: Java-Mx
Attachments: tuscany-container-spring.zip
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the
administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
--------------------------------------------------------------------
-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]