camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Romain Manni-Bucau <rmannibu...@gmail.com>
Subject Re: Can (S)JMS be safely used on Java EE?
Date Fri, 08 Feb 2013 17:01:00 GMT
jWorkManager or WorkManager?

the last one is part of JavaEE but does not have contraints on injections
AFAIK so it doesn't really helps IMO

the best is to get resources from where you need (lookup, BeanProvider from
deltaspike...) with a correct scope (not requestscoped for instance which
has no real sense in such a thread)

Note: deltaspike has a kind of cdicontroller to allow to get scoped cdi
beans in batches, maybe something to have a look on

*Romain Manni-Bucau*
*Twitter: @rmannibucau <https://twitter.com/rmannibucau>*
*Blog: **http://rmannibucau.wordpress.com/*<http://rmannibucau.wordpress.com/>
*LinkedIn: **http://fr.linkedin.com/in/rmannibucau*
*Github: https://github.com/rmannibucau*



2013/2/8 Claus Ibsen <claus.ibsen@gmail.com>

> On Fri, Feb 8, 2013 at 2:03 PM, Harald Wellmann <hwellmann.de@gmail.com>
> wrote:
> > It it safe to use SJMS or JMS in a Java EE 6 application?
> >
>
> Yes, a lot of users is using Spring JMS / Camel / And a zillion other
> frameworks in JEE servers such as WebLogic, WebSphere etc.
> And has no trouble at all.
>
> Though there is an API called jWorkManager which you can implement and
> plugin to a JEE container (if it supports that)
> Then you can let the JEE server manage the threads.
>
> Camel allows you to plugin a custom thread pool manager so you can use
> that jWorkManager.
>
> We had some people in the community working on that for their WebLogic
> server. But they kinda just dropped that
> as it works flawless without doing that.
>
>
>
> > You are not supposed to start threads in Java EE, but (S)JMS uses
> > thread pools for consumers. Is it guaranteed that features like
> > resource or CDI injection, CDI scopes, JNDI lookup will work in these
> > these threads just the same as in a container-managed thread?
> >
> > Isn't it true that MDBs are the only official way to asynchronously
> > consume JMS messages in a Java EE application? Does SJMS have any
> > adapters for MDBs?
> >
> > (I'm mainly interested in SJMS, but I believe the same issues apply to
> > the Spring-based JMS component.)
> >
> > Best regards,
> > Harald
>
>
>
> --
> Claus Ibsen
> -----------------
> Red Hat, Inc.
> FuseSource is now part of Red Hat
> Email: cibsen@redhat.com
> Web: http://fusesource.com
> Twitter: davsclaus
> Blog: http://davsclaus.com
> Author of Camel in Action: http://www.manning.com/ibsen
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message