Examples of StatelessSessionHome


Examples of org.jboss.as.test.integration.web.sso.interfaces.StatelessSessionHome

    protected void processRequest(HttpServletRequest request, HttpServletResponse response) throws ServletException,
            IOException {
        try {
            InitialContext ctx = new InitialContext();
            Context enc = (Context) ctx.lookup("java:comp/env");
            StatelessSessionHome home = (StatelessSessionHome) enc.lookup("ejb/OptimizedEJB");
            StatelessSession bean = home.create();
            bean.noop();

            Object homeRef = enc.lookup("ejb/OptimizedEJB");
            home = (StatelessSessionHome) PortableRemoteObject.narrow(homeRef, StatelessSessionHome.class);
            bean = home.create();
            bean.noop();
            bean.getData();

            StatelessSessionLocalHome localHome = (StatelessSessionLocalHome) enc.lookup("ejb/local/OptimizedEJB");
            StatelessSessionLocal localBean = localHome.create();
View Full Code Here

Examples of org.jboss.test.classloader.leak.ejb.interfaces.StatelessSessionHome

   }
  
   protected void makeEjbRequests() throws Exception
   {
      InitialContext ctx = new InitialContext();
      StatelessSessionHome slsbhome = (StatelessSessionHome) ctx.lookup("ClassloaderLeakStatelessSession");
      StatelessSession slsbbean = slsbhome.create();
      slsbbean.log("EJB");
      StatefulSessionHome sfsbhome = (StatefulSessionHome) ctx.lookup("ClassloaderLeakStatefulSession");
      StatefulSession sfsbbean = sfsbhome.create();
      sfsbbean.log("EJB");
   }
View Full Code Here

Examples of org.jboss.test.classloader.leak.ejb.interfaces.StatelessSessionHome

   protected void doGet(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException
   {
      try
      {
          InitialContext ctx = new InitialContext();
          StatelessSessionHome slsbhome = (StatelessSessionHome) ctx.lookup("java:comp/env/ejb/ClassloaderLeakEJB2SLSB");
          StatelessSession slsbbean = slsbhome.create();
          slsbbean.log("EJB");
          StatefulSessionHome sfsbhome = (StatefulSessionHome) ctx.lookup("java:comp/env/ejb/ClassloaderLeakEJB2SFSB");
          StatefulSession sfsbbean = sfsbhome.create();
          sfsbbean.log("EJB");
      }
View Full Code Here

Examples of org.jboss.test.classloader.leak.ejb.interfaces.StatelessSessionHome

   }
  
   protected void makeEjbRequests() throws Exception
   {
      InitialContext ctx = new InitialContext();
      StatelessSessionHome slsbhome = (StatelessSessionHome) ctx.lookup("ClassloaderLeakStatelessSession");
      StatelessSession slsbbean = slsbhome.create();
      slsbbean.log("EJB");
      StatefulSessionHome sfsbhome = (StatefulSessionHome) ctx.lookup("ClassloaderLeakStatefulSession");
      StatefulSession sfsbbean = sfsbhome.create();
      sfsbbean.log("EJB");
   }
View Full Code Here

Examples of org.jboss.test.classloader.scoping.override.ejb.log4j113.StatelessSessionHome

      getLog().debug("+++ testEjbOverrides");
      try
      {
         deploy("log4j113-ejb.jar");
         InitialContext ctx = new InitialContext();
         StatelessSessionHome home = (StatelessSessionHome) ctx.lookup("Log4j113StatelessBean");
         StatelessSession bean = home.create();
         Throwable error = bean.checkVersion();
         getLog().debug("StatelessSession.checkVersion returned:", error);
         assertTrue("checkVersion returned null", error == null);
      }
      catch(Exception e)
View Full Code Here

Examples of org.jboss.test.classloader.scoping.override.ejb.log4j113.StatelessSessionHome

      getLog().debug("+++ testEjbOverrides");
      try
      {
         deploy("log4j113-ejb.jar");
         InitialContext ctx = new InitialContext();
         StatelessSessionHome home = (StatelessSessionHome) ctx.lookup("Log4j113StatelessBean");
         StatelessSession bean = home.create();
         Throwable error = bean.checkVersion();
         getLog().debug("StatelessSession.checkVersion returned:", error);
         assertTrue("checkVersion returned null", error == null);
      }
      catch(Exception e)
View Full Code Here

Examples of org.jboss.test.cluster.ejb2.basic.interfaces.StatelessSessionHome

      InitialContext ctx = new InitialContext(env1);
     
      getLog().debug("Test Stateless Bean load-balancing");
      getLog().debug("==================================");
      getLog().debug(++test+"- "+"Looking up the home nextgen.StatelessSession...");
      StatelessSessionHome  statelessSessionHome =
      (StatelessSessionHome) ctx.lookup("nextgen_StatelessSession");
      if (statelessSessionHome!= null ) getLog().debug("ok");
         getLog().debug(++test+"- "+"Calling create on StatelessSessionHome...");
      StatelessSession statelessSession =
      (StatelessSession)statelessSessionHome.create();
      assertTrue("statelessSessionHome.create() != null", statelessSession != null);
      getLog().debug("ok");
     
      getLog().debug(++test+"- "+"Calling getEJBHome() on StatelessSession...");
      assertTrue("statelessSession.getEJBHome() != null", statelessSession.getEJBHome() != null);
View Full Code Here

Examples of org.jboss.test.cts.interfaces.StatelessSessionHome

      assertTrue("Float0 == 3.14", flt0.equals(new Float("3.14")));

      Long long0 = (Long) enc.lookup("Long0");
      assertTrue("Long0 == 123456789", long0.equals(new Long(123456789)));

      StatelessSessionHome home = (StatelessSessionHome) enc.lookup("ejb/StatelessSessionBean");
      assertTrue("ejb/StatelessSessionBean isa StatelessSessionHome", home != null);

      URL jbossHome = (URL) enc.lookup("url/JBossHome");
      assertTrue("url/JBossHome == http://www.jboss.org",
         jbossHome.toString().equals("http://www.jboss.org"));
View Full Code Here

Examples of org.jboss.test.cts.interfaces.StatelessSessionHome

    */
   static void testEjbs() throws Exception
   {
      log.info("+++ testEjbs");
      Context enc = getENC();     
      StatelessSessionHome home = (StatelessSessionHome) enc.lookup("ejb/StatelessSessionBean");
      StatelessSession session = home.create();
      session.method1("testEjbs");
      session.remove();
   }
View Full Code Here

Examples of org.jboss.test.cts.interfaces.StatelessSessionHome

   public void testCreateExceptionFromRemoteInterface() throws Exception
   {
      getLog().debug("+++ testCreateExceptionFromInterface()");
      InitialContext ctx = new InitialContext();
      Object ref = ctx.lookup("ejbcts/StatelessSessionHome");
      StatelessSessionHome home = (StatelessSessionHome) PortableRemoteObject.narrow(ref, StatelessSessionHome.class);
      StatelessSession sessionBean = home.create();
      sessionBean.breakCreate();
      ObjectName pool = new ObjectName("jboss.j2ee:jndiName=ejbcts/StatelessSessionHome,plugin=pool,service=EJB");
      getServer().invoke(pool, "clear", null, null);
      try
      {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.