You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomee.apache.org by Bernard <bh...@gmail.com> on 2013/08/06 09:13:24 UTC
TomEE per Wep App only
Hi,
Can TomEE provide JavaEE functionality without the modification of the
server as described at
http://tomee.apache.org/installation-drop-in-war.html ?
The old OpenEJB document at
http://openejb.codehaus.org/tomcat.html
describes this as follows:
"OpenEJB per webapp - deployed EJBs are visible only to the web apps
that declared to load OpenEJB"
I would be useful for me because my production environment has high
resistance to any changes of the server environment which cannot be
justified for my EJB3 web application alone.
My EJBs don't need to be visible to other applications.
Otherwise, if this is not possible, where can I learn about the impact
and risks of the standard drop-in .war approach?
Many thanks
Bernard
Re: TomEE per Wep App only
Posted by Romain Manni-Bucau <rm...@gmail.com>.
Yes, open tomee war to see it
Le 7 août 2013 19:57, "Bernard" <bh...@gmail.com> a écrit :
> Thanks again.
>
> >side note you put tomee libs in <app>/lib and not <app>/WEB-INF/lib?
>
> Where do you expect them to be? My build script copies them all to
> <app>/WEB-INF/lib. I am on a different computer. I remember having
> copied 2 jars additionally from a diffferent directory because they
> were separate in the war file. Does TomEE expect files in <app>/lib?
>
> Regards,
>
> Bernard
>
>
> On Wed, 7 Aug 2013 12:53:43 +0200, you wrote:
>
> >it needs to find openejb-loader*.jar in <yourwebapp>/lib
> >
> >side note you put tomee libs in <app>/lib and not <app>/WEB-INF/lib?
> >
> >*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/8/7 Bernard <bh...@gmail.com>
> >
> >> Hi!
> >>
> >> Thanks for your help. I experimented with your suggestion, but I
> >> wasn't lucky. I tried to follow the spirit of your advice of a maven
> >> war overlay - by hand. I added the war file content as libs to my ant
> >> project. Then I added the servlet entry to the web.xml of the app and
> >> got:
> >>
> >> java.lang.NullPointerException
> >> at
> >> org.apache.tomee.loader.TomcatEmbedder.embed(TomcatEmbedder.java:88)
> >> at
> >> org.apache.tomee.loader.LoaderServlet.init(LoaderServlet.java:66)
> >>
> >> Did I miss anything?
> >>
> >> TomEE appears to insist on loading classes from "tomee.war". If I copy
> >> tomee.war to tomcat then tomcat extracts it and produces other errors.
> >>
> >> For me, this use case has been a wakeup call. I should have been
> >> prepared for it. My current assignment is in an organization that has
> >> not yet decided between Spring and standard EJB technology. I prefer
> >> EJB. Still I am losing the battle because I cannot DEPLOY EJB to a
> >> plain Tomcat installation.
> >>
> >> The irony is that deployment of the full EJB stack into a raw Tomcat
> >> is against TomEE's natural objective i.e. integration and small and
> >> fast application deployments. But it could make the switch away from
> >> Spring easier. Developers could deploy on TomEE while production may
> >> run on plain Tomcat.
> >>
> >> In other words, it would be nice to have a supported solution for this
> >> use case.
> >>
> >> Regards,
> >>
> >> Bernard
> >>
> >>
> >> On Tue, 6 Aug 2013 09:25:52 +0200, you wrote:
> >>
> >> >Hi,
> >> >
> >> >an easy way to test it is to include tomee in your war (i think the
> >> easiest
> >> >is to do an overlay of tomee war) and declare in your web.xml:
> >> >
> >> > <servlet>
> >> > <servlet-name>LoaderServlet</servlet-name>
> >> >
> <servlet-class>org.apache.tomee.loader.LoaderServlet</servlet-class>
> >> > </servlet>
> >> >
> >> >btw this was an old solution, i didn't check it recently
> >> >
> >> >the drop in war approach alone you'll hit startup order issues, if you
> can
> >> >add the OpenEJBListener in server.xml it is pretty much the same as a
> >> >default tomee.
> >> >
> >> >
> >> >*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/8/6 Bernard <bh...@gmail.com>
> >> >
> >> >> Hi,
> >> >>
> >> >> Can TomEE provide JavaEE functionality without the modification of
> the
> >> >> server as described at
> >> >>
> >> >> http://tomee.apache.org/installation-drop-in-war.html ?
> >> >>
> >> >> The old OpenEJB document at
> >> >>
> >> >> http://openejb.codehaus.org/tomcat.html
> >> >>
> >> >> describes this as follows:
> >> >>
> >> >> "OpenEJB per webapp - deployed EJBs are visible only to the web apps
> >> >> that declared to load OpenEJB"
> >> >>
> >> >> I would be useful for me because my production environment has high
> >> >> resistance to any changes of the server environment which cannot be
> >> >> justified for my EJB3 web application alone.
> >> >>
> >> >> My EJBs don't need to be visible to other applications.
> >> >>
> >> >> Otherwise, if this is not possible, where can I learn about the
> impact
> >> >> and risks of the standard drop-in .war approach?
> >> >>
> >> >> Many thanks
> >> >>
> >> >> Bernard
> >> >>
> >>
> >>
>
>
Re: TomEE per Wep App only
Posted by Bernard <bh...@gmail.com>.
Thanks again.
>side note you put tomee libs in <app>/lib and not <app>/WEB-INF/lib?
Where do you expect them to be? My build script copies them all to
<app>/WEB-INF/lib. I am on a different computer. I remember having
copied 2 jars additionally from a diffferent directory because they
were separate in the war file. Does TomEE expect files in <app>/lib?
Regards,
Bernard
On Wed, 7 Aug 2013 12:53:43 +0200, you wrote:
>it needs to find openejb-loader*.jar in <yourwebapp>/lib
>
>side note you put tomee libs in <app>/lib and not <app>/WEB-INF/lib?
>
>*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/8/7 Bernard <bh...@gmail.com>
>
>> Hi!
>>
>> Thanks for your help. I experimented with your suggestion, but I
>> wasn't lucky. I tried to follow the spirit of your advice of a maven
>> war overlay - by hand. I added the war file content as libs to my ant
>> project. Then I added the servlet entry to the web.xml of the app and
>> got:
>>
>> java.lang.NullPointerException
>> at
>> org.apache.tomee.loader.TomcatEmbedder.embed(TomcatEmbedder.java:88)
>> at
>> org.apache.tomee.loader.LoaderServlet.init(LoaderServlet.java:66)
>>
>> Did I miss anything?
>>
>> TomEE appears to insist on loading classes from "tomee.war". If I copy
>> tomee.war to tomcat then tomcat extracts it and produces other errors.
>>
>> For me, this use case has been a wakeup call. I should have been
>> prepared for it. My current assignment is in an organization that has
>> not yet decided between Spring and standard EJB technology. I prefer
>> EJB. Still I am losing the battle because I cannot DEPLOY EJB to a
>> plain Tomcat installation.
>>
>> The irony is that deployment of the full EJB stack into a raw Tomcat
>> is against TomEE's natural objective i.e. integration and small and
>> fast application deployments. But it could make the switch away from
>> Spring easier. Developers could deploy on TomEE while production may
>> run on plain Tomcat.
>>
>> In other words, it would be nice to have a supported solution for this
>> use case.
>>
>> Regards,
>>
>> Bernard
>>
>>
>> On Tue, 6 Aug 2013 09:25:52 +0200, you wrote:
>>
>> >Hi,
>> >
>> >an easy way to test it is to include tomee in your war (i think the
>> easiest
>> >is to do an overlay of tomee war) and declare in your web.xml:
>> >
>> > <servlet>
>> > <servlet-name>LoaderServlet</servlet-name>
>> > <servlet-class>org.apache.tomee.loader.LoaderServlet</servlet-class>
>> > </servlet>
>> >
>> >btw this was an old solution, i didn't check it recently
>> >
>> >the drop in war approach alone you'll hit startup order issues, if you can
>> >add the OpenEJBListener in server.xml it is pretty much the same as a
>> >default tomee.
>> >
>> >
>> >*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/8/6 Bernard <bh...@gmail.com>
>> >
>> >> Hi,
>> >>
>> >> Can TomEE provide JavaEE functionality without the modification of the
>> >> server as described at
>> >>
>> >> http://tomee.apache.org/installation-drop-in-war.html ?
>> >>
>> >> The old OpenEJB document at
>> >>
>> >> http://openejb.codehaus.org/tomcat.html
>> >>
>> >> describes this as follows:
>> >>
>> >> "OpenEJB per webapp - deployed EJBs are visible only to the web apps
>> >> that declared to load OpenEJB"
>> >>
>> >> I would be useful for me because my production environment has high
>> >> resistance to any changes of the server environment which cannot be
>> >> justified for my EJB3 web application alone.
>> >>
>> >> My EJBs don't need to be visible to other applications.
>> >>
>> >> Otherwise, if this is not possible, where can I learn about the impact
>> >> and risks of the standard drop-in .war approach?
>> >>
>> >> Many thanks
>> >>
>> >> Bernard
>> >>
>>
>>
Re: TomEE per Wep App only
Posted by Romain Manni-Bucau <rm...@gmail.com>.
it needs to find openejb-loader*.jar in <yourwebapp>/lib
side note you put tomee libs in <app>/lib and not <app>/WEB-INF/lib?
*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/8/7 Bernard <bh...@gmail.com>
> Hi!
>
> Thanks for your help. I experimented with your suggestion, but I
> wasn't lucky. I tried to follow the spirit of your advice of a maven
> war overlay - by hand. I added the war file content as libs to my ant
> project. Then I added the servlet entry to the web.xml of the app and
> got:
>
> java.lang.NullPointerException
> at
> org.apache.tomee.loader.TomcatEmbedder.embed(TomcatEmbedder.java:88)
> at
> org.apache.tomee.loader.LoaderServlet.init(LoaderServlet.java:66)
>
> Did I miss anything?
>
> TomEE appears to insist on loading classes from "tomee.war". If I copy
> tomee.war to tomcat then tomcat extracts it and produces other errors.
>
> For me, this use case has been a wakeup call. I should have been
> prepared for it. My current assignment is in an organization that has
> not yet decided between Spring and standard EJB technology. I prefer
> EJB. Still I am losing the battle because I cannot DEPLOY EJB to a
> plain Tomcat installation.
>
> The irony is that deployment of the full EJB stack into a raw Tomcat
> is against TomEE's natural objective i.e. integration and small and
> fast application deployments. But it could make the switch away from
> Spring easier. Developers could deploy on TomEE while production may
> run on plain Tomcat.
>
> In other words, it would be nice to have a supported solution for this
> use case.
>
> Regards,
>
> Bernard
>
>
> On Tue, 6 Aug 2013 09:25:52 +0200, you wrote:
>
> >Hi,
> >
> >an easy way to test it is to include tomee in your war (i think the
> easiest
> >is to do an overlay of tomee war) and declare in your web.xml:
> >
> > <servlet>
> > <servlet-name>LoaderServlet</servlet-name>
> > <servlet-class>org.apache.tomee.loader.LoaderServlet</servlet-class>
> > </servlet>
> >
> >btw this was an old solution, i didn't check it recently
> >
> >the drop in war approach alone you'll hit startup order issues, if you can
> >add the OpenEJBListener in server.xml it is pretty much the same as a
> >default tomee.
> >
> >
> >*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/8/6 Bernard <bh...@gmail.com>
> >
> >> Hi,
> >>
> >> Can TomEE provide JavaEE functionality without the modification of the
> >> server as described at
> >>
> >> http://tomee.apache.org/installation-drop-in-war.html ?
> >>
> >> The old OpenEJB document at
> >>
> >> http://openejb.codehaus.org/tomcat.html
> >>
> >> describes this as follows:
> >>
> >> "OpenEJB per webapp - deployed EJBs are visible only to the web apps
> >> that declared to load OpenEJB"
> >>
> >> I would be useful for me because my production environment has high
> >> resistance to any changes of the server environment which cannot be
> >> justified for my EJB3 web application alone.
> >>
> >> My EJBs don't need to be visible to other applications.
> >>
> >> Otherwise, if this is not possible, where can I learn about the impact
> >> and risks of the standard drop-in .war approach?
> >>
> >> Many thanks
> >>
> >> Bernard
> >>
>
>
Re: TomEE per Wep App only
Posted by Bernard <bh...@gmail.com>.
Hi!
Thanks for your help. I experimented with your suggestion, but I
wasn't lucky. I tried to follow the spirit of your advice of a maven
war overlay - by hand. I added the war file content as libs to my ant
project. Then I added the servlet entry to the web.xml of the app and
got:
java.lang.NullPointerException
at
org.apache.tomee.loader.TomcatEmbedder.embed(TomcatEmbedder.java:88)
at
org.apache.tomee.loader.LoaderServlet.init(LoaderServlet.java:66)
Did I miss anything?
TomEE appears to insist on loading classes from "tomee.war". If I copy
tomee.war to tomcat then tomcat extracts it and produces other errors.
For me, this use case has been a wakeup call. I should have been
prepared for it. My current assignment is in an organization that has
not yet decided between Spring and standard EJB technology. I prefer
EJB. Still I am losing the battle because I cannot DEPLOY EJB to a
plain Tomcat installation.
The irony is that deployment of the full EJB stack into a raw Tomcat
is against TomEE's natural objective i.e. integration and small and
fast application deployments. But it could make the switch away from
Spring easier. Developers could deploy on TomEE while production may
run on plain Tomcat.
In other words, it would be nice to have a supported solution for this
use case.
Regards,
Bernard
On Tue, 6 Aug 2013 09:25:52 +0200, you wrote:
>Hi,
>
>an easy way to test it is to include tomee in your war (i think the easiest
>is to do an overlay of tomee war) and declare in your web.xml:
>
> <servlet>
> <servlet-name>LoaderServlet</servlet-name>
> <servlet-class>org.apache.tomee.loader.LoaderServlet</servlet-class>
> </servlet>
>
>btw this was an old solution, i didn't check it recently
>
>the drop in war approach alone you'll hit startup order issues, if you can
>add the OpenEJBListener in server.xml it is pretty much the same as a
>default tomee.
>
>
>*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/8/6 Bernard <bh...@gmail.com>
>
>> Hi,
>>
>> Can TomEE provide JavaEE functionality without the modification of the
>> server as described at
>>
>> http://tomee.apache.org/installation-drop-in-war.html ?
>>
>> The old OpenEJB document at
>>
>> http://openejb.codehaus.org/tomcat.html
>>
>> describes this as follows:
>>
>> "OpenEJB per webapp - deployed EJBs are visible only to the web apps
>> that declared to load OpenEJB"
>>
>> I would be useful for me because my production environment has high
>> resistance to any changes of the server environment which cannot be
>> justified for my EJB3 web application alone.
>>
>> My EJBs don't need to be visible to other applications.
>>
>> Otherwise, if this is not possible, where can I learn about the impact
>> and risks of the standard drop-in .war approach?
>>
>> Many thanks
>>
>> Bernard
>>
Re: TomEE per Wep App only
Posted by Romain Manni-Bucau <rm...@gmail.com>.
Hi,
an easy way to test it is to include tomee in your war (i think the easiest
is to do an overlay of tomee war) and declare in your web.xml:
<servlet>
<servlet-name>LoaderServlet</servlet-name>
<servlet-class>org.apache.tomee.loader.LoaderServlet</servlet-class>
</servlet>
btw this was an old solution, i didn't check it recently
the drop in war approach alone you'll hit startup order issues, if you can
add the OpenEJBListener in server.xml it is pretty much the same as a
default tomee.
*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/8/6 Bernard <bh...@gmail.com>
> Hi,
>
> Can TomEE provide JavaEE functionality without the modification of the
> server as described at
>
> http://tomee.apache.org/installation-drop-in-war.html ?
>
> The old OpenEJB document at
>
> http://openejb.codehaus.org/tomcat.html
>
> describes this as follows:
>
> "OpenEJB per webapp - deployed EJBs are visible only to the web apps
> that declared to load OpenEJB"
>
> I would be useful for me because my production environment has high
> resistance to any changes of the server environment which cannot be
> justified for my EJB3 web application alone.
>
> My EJBs don't need to be visible to other applications.
>
> Otherwise, if this is not possible, where can I learn about the impact
> and risks of the standard drop-in .war approach?
>
> Many thanks
>
> Bernard
>