[jdf-dev] Quickstart for how to inject Spring into Java EE
Jason Porter
jporter at redhat.com
Thu Jul 12 03:23:35 EDT 2012
----- Original Message -----
> From: "Pete Muir" <pmuir at redhat.com>
> To: "StevenBoscarine" <stevenboscarine at gmail.com>
> Cc: jdf-dev at lists.jboss.org
> Sent: Wednesday, July 11, 2012 9:15:09 AM
> Subject: Re: [jdf-dev] Quickstart for how to inject Spring into Java EE
>
> Hi Steven
>
> On 11 Jul 2012, at 15:29, StevenBoscarine wrote:
>
> > Hello All,
> > I was wondering if this the appropriate forum to discuss a
> > quickstart I'd like to contribute.
>
> It certainly is.
>
> >
> > https://github.com/StevenBoscarine/spring-seam-helloworld
> >
> > As mentioned in the thread below, I think that the best way to get
> > people to adopt CDI and Java EE, in general, is to help them
> > integrate their existing investments into their new applications.
> > In my experience, few applications are truly greenfield and
> > therefore are likely to need to integrate with legacy Spring code.
> >
> > seam-spring hello world is the most basic example I can think of
> > that shows:
> > • How to inject CDI into Spring
> > • How to inject Spring into Java EE through CDI, JAX-RS, and a
> > Servlet.
> > I also did my best to beef up the comments. I tried to make it as
> > friendly as possible to junior and "undermotivated" developers.
> >
> > I did review http://www.jboss.org/jdf/about/contributing/ but am
> > sure there are "opportunities for improvement" this audience can
> > point out.
>
> This should go in the DeltaSpike quickstarts, not the JBoss AS
> quickstarts, as that is where we will draw the integration library
> from.
>
> Jason, do we have a repo for that set up?
Currently https://github.com/LightGuard/deltaspike_on_as7 I don't have any other repo or org setup for this yet. So much time and so little to do -- if only that were the case.
>
> In general, the best way to review the quickstart is via a github
> pull request, as that comes with built in code review tools.
>
> > Within some of the config, I had some FIXME tags as there are some
> > questions I was going to ask Marius as to some of the details of
> > how seam-spring works.
> >
> > Finally, Where's the appropriate forum to ask questions about the
> > technology we're demonstrating? For example, in Marius' original
> > example, he had:
> > //FIXME: Why is this needed? Is this boilerplate?
> > @Produces
> > @Web
> > @SpringContext
> > private ApplicationContext context;
> >
> > Is it appropriate to ask technical questions about the underlying
> > in this forum/mailing-list? I could probably get all the info I
> > needed by e-mailing Marius directly, but wasn't sure if it is more
> > beneficial to have these conversations in an open forum.
>
> You can ask here, for sure.
>
> >
> > Thanks,
> > Steven
> >
> >
> > On 7/2/2012 10:48 AM, Pete Muir wrote:
> >> Yep, gotcha :-)
> >>
> >> But Steven could start to contribute the quickstart based on Seam,
> >> to jdf, as it's still in alpha stage any (the DS quickstarts).
> >>
> >> On 2 Jul 2012, at 15:47, Marius Bogoevici wrote:
> >>
> >>
> >>> This is generally fine, however this cannot be a DS QS yet as we
> >>> don't have the feature in DS. Will bootstrap the process this
> >>> weekend, post Canada Day.
> >>>
> >>> Sent from my iPhone
> >>>
> >>> On 2012-07-02, at 7:39 AM, Pete Muir
> >>> <pmuir at redhat.com>
> >>> wrote:
> >>>
> >>>
> >>>> The idea Jason and I had was to develop some DeltaSpike
> >>>> orientated quickstarts, targeted at DeltaSpike on JBoss AS with
> >>>> JBoss Tools etc. Obvious place to keep this is jdf IMO.
> >>>>
> >>>> On 29 Jun 2012, at 00:40, Marius Bogoevici wrote:
> >>>>
> >>>>
> >>>>> I think we'll want to move this into DeltaSpike when the Spring
> >>>>> module is available in DS. Ill kick start that process next
> >>>>> week. Until then a standlone tutorial based on what's in Seam
> >>>>> 3 should do.
> >>>>>
> >>>>> Sent from my iPhone
> >>>>>
> >>>>> On 2012-06-28, at 3:55 PM, Pete Muir
> >>>>> <pmuir at redhat.com>
> >>>>> wrote:
> >>>>>
> >>>>>
> >>>>>> Add Jason P. I think he was going to try to head up the
> >>>>>> quickstarts for DeltaSpike, that we deliver in jboss
> >>>>>> developer framework, which is where I think it would be the
> >>>>>> right place to put it.
> >>>>>>
> >>>>>> We haven't sorted out the organisation of the quickstarts
> >>>>>> properly yet, I'm looking at this over the next week or two.
> >>>>>>
> >>>>>> So I think get it on github, get on with the review, and we
> >>>>>> can merge it into the correct repo later. I would just
> >>>>>> suggest putting it in a subdir, not the root of the git
> >>>>>> repo..
> >>>>>>
> >>>>>> All make sense?
> >>>>>>
> >>>>>> pete
> >>>>>>
> >>>>>> On 28 Jun 2012, at 12:40, Steven Boscarine wrote:
> >>>>>>
> >>>>>>
> >>>>>>> Hi Marius,
> >>>>>>> I got everything working. Thanks for the good example.
> >>>>>>>
> >>>>>>> Is there any chance of this becoming an official quickstart?
> >>>>>>> Last I heard 3 months ago, they were waiting for
> >>>>>>> DeltaSpike.
> >>>>>>>
> >>>>>>> As you're aware, I think this would be one of the most
> >>>>>>> valuable topics covered since getting legacy Spring
> >>>>>>> investments to work in new Java EE features is a "gateway to
> >>>>>>> EE"
> >>>>>>>
> >>>>>>> If so, I had some ideas to make it more beginner-friendly,
> >>>>>>> perhaps as another quickstart that is a subset of this
> >>>>>>> example and distilling it down to its essence and bare
> >>>>>>> elements. Here is what I was thinking:
> >>>>>>> • Show 2 Spring beans:
> >>>>>>> • 1 registered with XML
> >>>>>>> • 1 registered with 2.x annotations.
> >>>>>>> • Show a simple JAX-RS service and Servlet 3.0 example
> >>>>>>> • Inject the Spring beans into the servlet and JAX-RS service
> >>>>>>> • Inject an EntityManager into the Spring bean (showing how
> >>>>>>> to inject JEE into Spring and inject Spring into JEE).
> >>>>>>> • Remove Spring MVC. If people aren't invested in the Spring
> >>>>>>> view technologies, they may find this intimidating
> >>>>>>> • Beef up the comments....really go nuts documenting every
> >>>>>>> detail
> >>>>>>> What do you think? It would be incredibly similar to your
> >>>>>>> example, but I would be adding a lot of comments to the
> >>>>>>> Producer class, POM, and configs.
> >>>>>>> If you think this has the potential to be useful for
> >>>>>>> quickstarts, I'd be happy to get something in github for
> >>>>>>> review. If you (and Dan and Pete) like it, I'll reply to
> >>>>>>> one of the old e-mail lists.
> >>>>>>> I just wanted to message out first to ensure such a
> >>>>>>> quickstart wouldn't be Dead On Arrival before starting work.
> >>>>>>> Thanks,
> >>>>>>> Steven
> >>>>>>>
> >>>>>>> On 6/27/2012 10:22 AM, Marius Bogoevici wrote:
> >>>>>>>
> >>>>>>>> Hi Steven,
> >>>>>>>>
> >>>>>>>> Thanks for attending and your appreciation! I am sorry that
> >>>>>>>> we didn't meet at the JUDcon. Are you attending the JBoss
> >>>>>>>> World, by any chance - I am here for the rest of the week
> >>>>>>>> (leaving Friday afternoon). In any case, if you are around,
> >>>>>>>> I'd love to sit down and discuss.
> >>>>>>>>
> >>>>>>>> Indeed, the Spring archetype is meant to be a full-Spring
> >>>>>>>> solution, which is why we use Spring MVC RESTful services.
> >>>>>>>>
> >>>>>>>> To the issue of JAX-RS/Spring integration, there are two
> >>>>>>>> possible solutions to your problem:
> >>>>>>>>
> >>>>>>>> a) one using RESTEasy's support for Spring integration
> >>>>>>>>
> >>>>>>>>
> >>>>>>>> http://docs.jboss.org/resteasy/docs/2.3.4.Final/userguide/html_single/#RESTEasy_Spring_Integration
> >>>>>>>>
> >>>>>>>>
> >>>>>>>> b) using the Spring/CDI bridge to expose Spring beans as CDI
> >>>>>>>> beans
> >>>>>>>>
> >>>>>>>>
> >>>>>>>> http://docs.jboss.org/seam/3/spring/latest/reference/en-US/html_single/
> >>>>>>>>
> >>>>>>>>
> >>>>>>>> An example of using Spring with a Java EE 6 *Servlet* (but I
> >>>>>>>> believe it should be identical for a JAX-RS endpoint):
> >>>>>>>>
> >>>>>>>>
> >>>>>>>> https://github.com/mbogoevici/Seam-Spring-Basic-Example
> >>>>>>>>
> >>>>>>>>
> >>>>>>>> This is intended to be moved in DeltaSpike as soon as
> >>>>>>>> possible, but it may some time until it gets there. Paul
> >>>>>>>> Bakker's migration talk builds on lot of that too.
> >>>>>>>>
> >>>>>>>> I would recommend using b) as it requires less dealing with
> >>>>>>>> RESTEasy internals (ideally it should work in any
> >>>>>>>> container). In fact, this was one of the topics I wanted to
> >>>>>>>> talk about yesterday, but in the end had to choose between
> >>>>>>>> that and Forge :|. Apparently, rehearsal timing and
> >>>>>>>> conference timing seem to differ ;).
> >>>>>>>>
> >>>>>>>> Thanks a lot for your insight. Yes, I feel the same, and I
> >>>>>>>> may or may not have gotten that point across (I tried), but
> >>>>>>>> this has a lot of weight coming from you and the reality of
> >>>>>>>> the industry. I think that migration should be an enabler
> >>>>>>>> for exploring new themes and technologies and not a venue
> >>>>>>>> for fighting technology wars for the sake of it.
> >>>>>>>>
> >>>>>>>> That being said, thanks again for your e-mail and I hope
> >>>>>>>> that all this will be helpful to you. Please let me know
> >>>>>>>> how it worked.
> >>>>>>>>
> >>>>>>>> Cheers,
> >>>>>>>> Marius
> >>>>>>>>
> >>>>>>>> On 2012-06-26, at 5:28 PM, Steven Boscarine wrote:
> >>>>>>>>
> >>>>>>>>
> >>>>>>>>> Hello Marius,
> >>>>>>>>> I managed to attend a few of your sessions at JUDCon and
> >>>>>>>>> you did an excellent job presenting.
> >>>>>>>>>
> >>>>>>>>> I looked at your Spring archetype and it appears that
> >>>>>>>>> you're using Spring's Webservices instead of JBoss'
> >>>>>>>>>
> >>>>>>>>> Could you help point me to where I should research for this
> >>>>>>>>> question to help my company migrate to EAP6?
> >>>>>>>>>
> >>>>>>>>> If I wanted to inject a Spring resource into a JAX-RS
> >>>>>>>>> service, say:
> >>>>>>>>>
> >>>>>>>>> import javax.enterprise.context.RequestScoped;
> >>>>>>>>> import javax.ws.rs.GET;
> >>>>>>>>> import javax.ws.rs.Path;
> >>>>>>>>>
> >>>>>>>>> @Path("/spring")
> >>>>>>>>> @RequestScoped
> >>>>>>>>> public class DiagnosticsService {
> >>>>>>>>>
> >>>>>>>>> @GET
> >>>>>>>>> @Path("/hw")
> >>>>>>>>> public String simpleDiagnostics() {
> >>>>>>>>> return "Hello World";
> >>>>>>>>> }
> >>>>>>>>>
> >>>>>>>>> }
> >>>>>>>>>
> >>>>>>>>> How could I inject the following bean:
> >>>>>>>>> package com.axeda.poc.spring;
> >>>>>>>>>
> >>>>>>>>>
> >>>>>>>>> import
> >>>>>>>>> org.springframework.beans.factory.annotation.Autowired;
> >>>>>>>>> import
> >>>>>>>>> org.springframework.beans.factory.annotation.Qualifier;
> >>>>>>>>> import org.springframework.stereotype.Service;
> >>>>>>>>>
> >>>>>>>>> @Service
> >>>>>>>>> public class LoudMouth {
> >>>>>>>>> private String source;
> >>>>>>>>>
> >>>>>>>>> @Autowired
> >>>>>>>>> public LoudMouth(@Qualifier("source") String source) {
> >>>>>>>>> super();
> >>>>>>>>> System.out.println("\n\n\n" + this.getClass() + " was
> >>>>>>>>> constructed by " + source + "!\n\n\n");
> >>>>>>>>> this.source = source;
> >>>>>>>>> }
> >>>>>>>>>
> >>>>>>>>> public LoudMouth() {
> >>>>>>>>> System.out.println("\n\n\n" + this.getClass() + " was
> >>>>>>>>> constructed by the default constructor, something is
> >>>>>>>>> wrong. :(!\n\n\n");
> >>>>>>>>> }
> >>>>>>>>> }
> >>>>>>>>>
> >>>>>>>>>
> >>>>>>>>> I've set the following web.xml:
> >>>>>>>>> <web-app xmlns=
> >>>>>>>>> "http://java.sun.com/xml/ns/javaee"
> >>>>>>>>> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
> >>>>>>>>>
> >>>>>>>>> xsi:schemaLocation=
> >>>>>>>>> "http://java.sun.com/xml/ns/javaee
> >>>>>>>>> http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd"
> >>>>>>>>> version="3.0">
> >>>>>>>>> <context-param>
> >>>>>>>>> <param-name>contextConfigLocation</param-name>
> >>>>>>>>> <param-value>classpath:/canaryapplicationContext.xml</param-value>
> >>>>>>>>> </context-param>
> >>>>>>>>> <listener>
> >>>>>>>>> <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
> >>>>>>>>> </listener>
> >>>>>>>>> <listener>
> >>>>>>>>> <listener-class>org.springframework.web.context.request.RequestContextListener</listener-class>
> >>>>>>>>> </listener>
> >>>>>>>>> </web-app>
> >>>>>>>>>
> >>>>>>>>>
> >>>>>>>>> and can see my bean constructed on container startup. I
> >>>>>>>>> just need to figure out how to inject it into the JAX-RS
> >>>>>>>>> service above.
> >>>>>>>>>
> >>>>>>>>>
> >>>>>>>>> Another thought (really commentary) is that you got some
> >>>>>>>>> friendly jeers talking about Spring at the "why does my
> >>>>>>>>> project matter" session. I view Spring integration work
> >>>>>>>>> as the "gateway drug" into Java EE. Shops like ours, have
> >>>>>>>>> a huge investment in legacy Spring. If we can
> >>>>>>>>> incrementally move our code from Spring to Java EE, it
> >>>>>>>>> dramatically increases the probability of us adopting Java
> >>>>>>>>> EE. My shop wants to move off legacy hibernate and Spring
> >>>>>>>>> to all the cool stuff Java EE in the quickstart
> >>>>>>>>> applications, but we're large and profitable. They say
> >>>>>>>>> there's the "Curse of Oil" in developing nations. We have
> >>>>>>>>> the "curse of paying customers." We have a product we're
> >>>>>>>>> making money off of. It makes our leaders risk adverse.
> >>>>>>>>> From my personal experience, companies like ours are the
> >>>>>>>>> norm. The market for updating working applications is
> >>>>>>>>> much larger than greenfield development. Giving us a nice
> >>>>>>>>> bridge to write new code in CDI and the full Java EE stack
> >>>>>>>>> while being able to inject our !
> >>>>>>>>> legacy S
> >>>>>>>>> pring-wired beans is very critical in moving to Java EE.
> >>>>>>>>>
> >>>>>>>>> I would have made this argument to the guy who asked you
> >>>>>>>>> questioned why you wish to integrate instead of migrate
> >>>>>>>>> since he was sitting next to me, but he was on his 6th
> >>>>>>>>> beer :)
> >>>>>>>>>
> >>>>>>>>> Thanks,
> >>>>>>>>> Steven
> >>>>>>>>>
> >>>>>>>>>
> >>>>>>>>> On 4/27/2012 2:16 PM, Marius Bogoevici wrote:
> >>>>>>>>>
> >>>>>>>>>> On 2012-04-27, at 2:01 PM, Pete Muir wrote:
> >>>>>>>>>>
> >>>>>>>>>>
> >>>>>>>>>>> Said library in Deltaspike.
> >>>>>>>>>>>
> >>>>>>>>>> Yes, we don't want to use Seam-Spring for the main quick
> >>>>>>>>>> starts.
> >>>>>>>>>>
> >>>>>>>>>>
> >>>>>>>>>>> On 27 Apr 2012, at 19:01, Pete Muir wrote:
> >>>>>>>>>>>
> >>>>>>>>>>>
> >>>>>>>>>>>> Yeah, so that adds some library from Deltaspike or Seam.
> >>>>>>>>>>>> This should be a target for next quarter or two,
> >>>>>>>>>>>> especially once we have said library!
> >>>>>>>>>>>>
> >>>>>>>>>>>> On 27 Apr 2012, at 17:34, Steven Boscarine wrote:
> >>>>>>>>>>>>
> >>>>>>>>>>>>
> >>>>>>>>>>>>> I'm not sure I understand the question.
> >>>>>>>>>>>>>
> >>>>>>>>>>>>> My guess is someone in my shoes would want to see the
> >>>>>>>>>>>>> quickstart app with the following additions:
> >>>>>>>>>>>>> • Spring 3.1 in the classpath
> >>>>>>>>>>>>> • 1 annotation-driven @Service. For now, let's call it
> >>>>>>>>>>>>> HelloWorldService. It could be a simple service that
> >>>>>>>>>>>>> returns "Hello World"
> >>>>>>>>>>>>> • 1 Spring config XML to scan for the @Service.
> >>>>>>>>>>>>> • The code needed to initialize Spring
> >>>>>>>>>>>>> • HelloWorldService injected into
> >>>>>>>>>>>>> MemberResourceRESTService
> >>>>>>>>>>>>>
> >>>>>>>>>>>>>
> >>>>>>>>>>>>>
> >>>>>>>>>>>>> On 4/27/2012 12:26 PM, Pete Muir wrote:
> >>>>>>>>>>>>>
> >>>>>>>>>>>>>> Would you use a library or does it run on pure Java
> >>>>>>>>>>>>>> EE?
> >>>>>>>>>>>>>>
> >>>>>>>>>>>>>> On 27 Apr 2012, at 17:21, Steven Boscarine wrote:
> >>>>>>>>>>>>>>
> >>>>>>>>>>>>>>
> >>>>>>>>>>>>>>
> >>>>>>>>>>>>>>> Correct.
> >>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>> The desire is to have a quickstart for injecting a
> >>>>>>>>>>>>>>> Spring bean into a JBoss managed resource like a
> >>>>>>>>>>>>>>> JAX-RS service or a servlet. I was thinking along
> >>>>>>>>>>>>>>> the lines of taking the quickstart project and
> >>>>>>>>>>>>>>> injecting a Spring Bean into
> >>>>>>>>>>>>>>> MemberResourceRESTService.
> >>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>> Thanks,
> >>>>>>>>>>>>>>> Steven
> >>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>> On 4/27/2012 10:13 AM, Marius Bogoevici wrote:
> >>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>> No :).
> >>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>> Steven specifically asked for "seam-spring-core",
> >>>>>>>>>>>>>>>> and he was quite clear that it's about using legacy
> >>>>>>>>>>>>>>>> Spring beans.
> >>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>> On 2012-04-27, at 8:13 AM, Pete Muir wrote:
> >>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>> I thought Steven was meaning a pure Spring
> >>>>>>>>>>>>>>>>> quickstart for JBoss AS, with no extra libraries
> >>>>>>>>>>>>>>>>> like Seam-Spring or DeltaSpike. In which case,
> >>>>>>>>>>>>>>>>> yes, definitely.
> >>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>> On 24 Apr 2012, at 17:02, Marius Bogoevici wrote:
> >>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>> Steven,
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>> You can find something like that here:
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>> https://github.com/mbogoevici/Seam-Spring-Basic-Example
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>> It mutates the example produced by the Spring MVC
> >>>>>>>>>>>>>>>>>> archetype (
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>> http://search.maven.org/#artifactdetails%7Corg.jboss.spring.archetypes%7Cspring-mvc-webapp%7C1.0.0.CR3%7Cmaven-archetype
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>> ) used in JBDS.
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>> Eventually, this ought to be in a more visible
> >>>>>>>>>>>>>>>>>> place, but I frequently get swamped with other
> >>>>>>>>>>>>>>>>>> things. [1] Also, this may change post-DeltaSpike
> >>>>>>>>>>>>>>>>>> migration. All in all, I think you have a simple
> >>>>>>>>>>>>>>>>>> example that illustrates the interoperability
> >>>>>>>>>>>>>>>>>> both ways.
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>> There's also Paul Pakker's Petclinic migration
> >>>>>>>>>>>>>>>>>> guide which uses the Seam Spring plugin, here
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>> https://github.com/paulbakker/petclinic.git
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>> , but Paul is also dealing with Spring code
> >>>>>>>>>>>>>>>>>> migration, so that may take you a bit too far.
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>> Cheers,
> >>>>>>>>>>>>>>>>>> Marius
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>> [1] A blog post about this has just gotten high
> >>>>>>>>>>>>>>>>>> priority as of *now* :)
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>> On 2012-04-24, at 11:52 AM, Steven Boscarine
> >>>>>>>>>>>>>>>>>> wrote:
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>> Any plans on a quickstart for seam-spring-core
> >>>>>>>>>>>>>>>>>>> (would that be in the scope of the quickstart
> >>>>>>>>>>>>>>>>>>> mission)?
> >>>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>> I am currently attempting to get my employer's
> >>>>>>>>>>>>>>>>>>> offering off 4.3 EAP and working in JBoss
> >>>>>>>>>>>>>>>>>>> AS7.1.1 (eventually EAP 6 when it's released).
> >>>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>> I imagine I won't be the only one who'll want to
> >>>>>>>>>>>>>>>>>>> use new features like JAX-RS or Servlet 3.0, but
> >>>>>>>>>>>>>>>>>>> inject in legacy Spring beans until we have time
> >>>>>>>>>>>>>>>>>>> to port the beans to CDI or EJB.
> >>>>>>>>>>>>>>>>>>> One of the first barriers is getting the legacy
> >>>>>>>>>>>>>>>>>>> Spring code working. Most shops I've seen have
> >>>>>>>>>>>>>>>>>>> 100s of beans (we have 1000s): far too many to
> >>>>>>>>>>>>>>>>>>> port to another technology right away.
> >>>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>> I'm happy to help. I just haven't found any
> >>>>>>>>>>>>>>>>>>> example app yet and couldn't figure out from
> >>>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>> http://docs.jboss.org/seam/3/spring/latest/reference/en-US/html/spring-usage.html#d0e76
> >>>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>> how to call a Spring Bean from a
> >>>>>>>>>>>>>>>>>>> container-managed resource like a @Servlet or
> >>>>>>>>>>>>>>>>>>> JAX-RS service.
> >>>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>> Thanks,
> >>>>>>>>>>>>>>>>>>> Steven
> >>>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>>
> >>>>>>>>>>>>>>>>>>>
> >>>>>>>>>
> >>>>>>>
> >
> >
> > _______________________________________________
> > jdf-dev mailing list
> > jdf-dev at lists.jboss.org
> > https://lists.jboss.org/mailman/listinfo/jdf-dev
>
>
> _______________________________________________
> jdf-dev mailing list
> jdf-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/jdf-dev
>
More information about the jdf-dev
mailing list