tomee-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Alex The Rocker <alex.m3...@gmail.com>
Subject Re: Can webapps/tomee directory be deleted for a production environment?
Date Sun, 16 Sep 2012 20:56:03 GMT
David:

Thank you very much for your answer. Is the ability to remove webapps/tomee
directory a durable one?
Won't there be future "mandatory" features requiring this web app?

Alex

On Sun, Sep 16, 2012 at 7:29 PM, David Blevins <david.blevins@gmail.com>wrote:

>
> On Sep 16, 2012, at 8:16 AM, Alex The Rocker wrote:
>
> > Hello,
> >
> > Can the webapps/tomee directory be deleted for deploying a web app to
> > production TomEE/TomEE+ server and exposed to Internet?
> > Indeed, when delivering our app with Tomcat, we delete all default web
> apps
> > as part of a list of Tomcat hardening task list.
> >
> > Is there any TomEE/TomE++ vital content in webapps/tomee directory ?
>
> The only loss of functionality would be the ability to remotely execute
> EJBs over HTTP.  However this can easily be added to a different webapp
> like so:
>
>     <servlet>
>       <servlet-name>ServerServlet</servlet-name>
>
> <servlet-class>org.apache.openejb.server.httpd.ServerServlet</servlet-class>
>     </servlet>
>
>     <servlet-mapping>
>       <servlet-name>ServerServlet</servlet-name>
>       <url-pattern>/myejbs/*</url-pattern>
>     </servlet-mapping>
>
>
> Then you can create an `InitialContext` that points to that webapp like so:
>
>     Properties p = new Properties();
>     p.put("java.naming.factory.initial",
> "org.apache.openejb.client.RemoteInitialContextFactory");
>     p.put("java.naming.provider.url", "
> http://127.0.0.1:8080/mywebapp/myejbs");
>     // user and pass optional
>     p.put("java.naming.security.principal", "myuser");
>     p.put("java.naming.security.credentials", "mypass");
>
>     InitialContext ctx = new InitialContext(p);
>
>     MyBean myBean = (MyBean) ctx.lookup("MyBeanRemote");
>
>
> -David
>
>
>

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