Creating EJB 3.0 Session Bean under JDeveloper 10g.

Hello im using JDeveloper 10 g all up 2 date.
when i create EJB 2.x EJB everythink is ok .. there is a Wizzard(Designer) from which i can add methods variables and etc.
all methods are become added to the session bean / remote interefeis etc.
My Problem is when i create EJB 3.0
when i do it the Bean class is created and the Remote interfeis with @remote is created too its ok BUT I CANT see Remote interfeis in my Application Naviagation its fine under 2.1 i cannot see remote interfeis and home interfeis too but inder 2.1 there is a wizzard(Designer) under 3.0 there is nothink.
what am i wrong ? how can i make designer to work under 3.0 or how can i make Jdeveloper to show me all content of the EJBs

another strange problem.
i have an APplication server added ( JBOSS ).
when i create deployment profile (EAR ) application server is showed in the ComboBox .
But when i create Java Test Client for some EJB and when i check " Connect Remote Application server" there is 2 comboboxes
J2EE Application
App Server Connection.
first combo is ok there is EJB applicaiton
Secound is empty .. but i Have App Server.
Another think is that when i create EJB 3.0 its BAD to see J2EE app it must be J EE 5 app or just Java EE app

Similar Messages

  • Problem creating EJB 3.0 Entity bean in JDeveloper

    Hello all,
    I trying to create my first entity bean in JDeveloper.
    JDevelper create the entity bean with the code below:
    package model;
    import java.io.Serializable;
    import javax.persistence.Entity;
    @Entity
    public class BatchSettlementT implements Serializable {
    public BatchSettlementT() {
    The problem is that JDeveloper don't find the import command import javax.persistence.Entity;
    What am I doing wrong?
    I'm using JDeveloper Studio Edition Version 10.1.3.1.0.3914.
    My libraries are:
    - TopLink
    - Oracle XML Parser 2
    - EJB 3.0
    - Toplink Essentials JPA
    - J2EE
    Thanks in advance.

    It's very strange, when I type import.javax. in my class there is no persistence package available, do you have any idea what's wrong.
    I did set the technology scope to EJB either.
    Thanks!

  • How to develop EJB 3.0  Session Beans under WL Workshop 10.3?

    Hi there,
    I know the theory about EJB, no problem there, but I've been trying to develop some EJB's on WLW, and I'd like to ask you two things:
    1. Is there any guide to follow? I found this web page, but I feel it's not quite enough.
    2. How do you do to make code-completion working for the EJB (or any other) annotations? I write @javax. CTRL-Space and it starts completing, but it does not add the founded class to the class' imports.
    Thanks in advance for any tip!
    Andrés

    Hi,
    You may have better luck posting this question to the Workshop forum: Workshop
    - Matt

  • How create  EJB 2.1 Stateful Session Bean in a EJB 3.0 Session Bean

    Hi All,
    We have been developing on EJB 2.1. We are now adding a module on EJB 3.0.
    How can we "create" a stateful session bean with create method signature similar to create(String id)?
    We have tried
    // this is the remote interface
    @EJB AddressBean abean;
    But not working
    Any help will be appreciated.

    There is no explicit create() call for EJB 3.0 session beans. It doesn't really matter though
    since you can accomplish the same thing by defining your own business method to act
    as an initializer for whatever state you'd like. E.g.
    @Remote
    public interface FooInterface {
    public void initialize(String id);
    // ... other business methods
    @EJB FooInterface fooRef;
    fooRef.initialize("foo");
    --ken                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • How to lookup a EJB 3.0 session bean which is deployed in WebLogic 10.3

    Now Jdeveloper 11.1.1, is giving WebLogic server 10.3.
    With internal WebLogic server, when I created a Sample client, it generated code as:
    private static Context getInitialContext() throws NamingException {
        Hashtable env = new Hashtable();
        // WebLogic Server 10.x connection details
        env.put( Context.INITIAL_CONTEXT_FACTORY, "weblogic.jndi.WLInitialContextFactory" );
        env.put(Context.PROVIDER_URL, "t3://127.0.0.1:7101");
        return new InitialContext( env );
    public static void main(String [] args) {
        try {
            final Context context = getInitialContext();
            DefaultSession defaultSession = (DefaultSession)context.lookup("property-DefaultSession#com.vs.property.model.session.DefaultSession");
        } catch (Exception ex) {
    }How to update the above code to lookup the EJB 3.0 session beans with an external WebLogic server 10.3?
    Is there any documentation available on how to install weblogic, troubleshoot, debug, WebLogic server 10.3?
    regds
    -raju

    Raju,
    Hi, to start, here is a tutorial on a quickstart web application using an EJB 3.0 stateless session bean that fronts a container managed EclipseLink JPA entity manager on WebLogic 10.3, you will find references there to other general WebLogic documentation.
    [http://wiki.eclipse.org/EclipseLink/Examples/JPA/WebLogic_Web_Tutorial]
    using @EJB injection on the client instead of a JNDI lookup as below
    [http://edocs.bea.com/wls/docs103/ejb30/annotations.html#wp1417411]
    1) in your second env.put I noticed that your t3 port is 7101, I usually use the default 7001 - but It looks like this port is valid for the JDeveloper embedded version of WebLogic server runs - just verify that it matches the port of your server.
    2) your name#qualified-name lookup looks ok. Verify that the jndi-name element is set in your weblogic-ejb-jar.xml for non injection clients like the following
    <weblogic-ejb-jar>
    <weblogic-enterprise-bean>
    <ejb-name>ApplicationService</ejb-name>
    <jndi-name>ApplicationService</jndi-name>
    3) as a test outside of your application - launch the WebLogic admin console and goto the testing tab of your bean in [Home > Summary of Deployments > "application" > "session bean name"
    thank you
    /michael : http://www.eclipselink.org                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Cannot deploy a EJB 3.0 Session bean to the OAS 10.1.3.4

    Hi All,
    I am unable to deploy a EJB 3.0 Session bean with no deployment descriptors to OAS 10.1.3.4 App server.This Session bean is also exposed as a web service using annotations. I am able to deploy this bean to a standalone oc4j 10.1.3.x containers and test it successfully.
    i have written a simple stateless session bean ( exposed as webservice) and every bean is having issues with deployment having the same exception stated below
    Can some one please help as i need to deploy this urgently.
    below is the session bean code:
    import javax.ejb.Stateless;
    @Stateless(name="SiebelQuoteEJB")
    public class SiebelQuoteEJBBean implements SiebelQuoteEJBLocal,
    SiebelQuoteEJBWebService {
    public SiebelQuoteEJBBean() {
    public String publishMessage(String message,String type) throws java.rmi.RemoteException {
    client.publishMessage(message,type);
    return "SUCCESS";
    Below is the error while deploying:
    11/01/06 15:03:49 WARNING: Application.setConfig Application: javasso is in failed state as initialization failed.
    java.lang.NullPointerException
    11/01/06 15:03:50 WARNING: Application.setConfig Application: SiebelQuoteEJB is in failed state as initialization failed.
    java.lang.InstantiationException: Error initializing ejb-modules: null Error parsing application-server config file: null
    11/01/06 15:03:50 java.lang.NullPointerException
    at com.evermind.server.ObjectReferenceCleaner.cleanupApplicationLogLevels(ObjectReferenceCleaner.java:166)
    at com.evermind.server.ObjectReferenceCleaner.loaderDestroyed(ObjectReferenceCleaner.java:88)
    at oracle.classloader.EventDispatcher.loaderDestroyed(EventDispatcher.java:248)
    at oracle.classloader.PolicyClassLoader.close(PolicyClassLoader.java:1113)
    at oracle.classloader.PolicyClassLoader.close(PolicyClassLoader.java:1041)
    at com.evermind.server.ApplicationStateRunning.destroyClassLoaders(ApplicationStateRunning.java:1171)
    at com.evermind.server.Application.stateCleanUp(Application.java:3635)
    at com.evermind.server.Application.setConfig(Application.java:506)
    at com.evermind.server.Application.setConfig(Application.java:355)
    at com.evermind.server.ApplicationServer.addApplication(ApplicationServer.java:1895)
    at com.evermind.server.ApplicationServer.initializeDeployedApplications(ApplicationServer.java:1651)
    at com.evermind.server.ApplicationServer.setConfig(ApplicationServer.java:1034)
    at com.evermind.server.ApplicationServerLauncher.run(ApplicationServerLauncher.java:131)
    at java.lang.Thread.run(Thread.java:736)

    which jdk version? Had this with 1.6 and had to install an up-to-date jdbc.

  • EJB 2.1 session bean calling EJB 3 session bean?

    I have a WL 10 (JDK 1.5/EE 5) server that has several EJB 3 stateless session beans deployed and working well. But now I need to allow a JBoss 3.2.3 (JDK 1.4) EJB 2.1 session bean make remote calls into these EJB 3 EJBs. Can this even work?
    It seems to me that EJB 3 calling EJB 2 would be fine, but not in the reverse?

    I have a WL 10 (JDK 1.5/EE 5) server that has several EJB 3 stateless session beans deployed and working well. But now I need to allow a JBoss 3.2.3 (JDK 1.4) EJB 2.1 session bean make remote calls into these EJB 3 EJBs. Can this even work?
    It seems to me that EJB 3 calling EJB 2 would be fine, but not in the reverse?

  • Failed to create "ejb/collaxa/system/FinderBean" bean; exception reported i

    I am unable to invoke BPEL service from an OA framework page. I am getting following error when I am trying to Invoke.
    oracle.apps.fnd.framework.OAException: java.lang.Exception: Failed to create "ejb/collaxa/system/DeliveryBean" bean; exception reported is: "java.lang.NullPointerException: domain was null
         at com.evermind.server.rmi.RMIServer.addNode(RMIServer.java:779)
         at com.evermind.server.rmi.RMIServer.getConnection(RMIServer.java:848)
         at com.evermind.server.rmi.RMIInitialContextFactory.getInitialContext(RMIInitialContextFactory.java:206)
         at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:662)
         at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243)
         at javax.naming.InitialContext.init(InitialContext.java:219)
         at javax.naming.InitialContext.<init>(InitialContext.java:195)
         at com.oracle.bpel.client.util.BeanRegistry.lookupDeliveryBean(BeanRegistry.java:277)
         at com.oracle.bpel.client.delivery.DeliveryService.getDeliveryBean(DeliveryService.java:250)
         at com.oracle.bpel.client.delivery.DeliveryService.request(DeliveryService.java:83)
         at com.oracle.bpel.client.delivery.DeliveryService.request(DeliveryService.java:53)
         at emr2.oracle.apps.inv.kanban.webui.KanPOCTestCO.getMsg(KanPOCTestCO.java:93)
         at emr2.oracle.apps.inv.kanban.webui.KanPOCTestCO.processRequest(KanPOCTestCO.java:45)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processRequest(OAWebBeanHelper.java:518)
         at oracle.apps.fnd.framework.webui.OAWebBeanContainerHelper.processRequest(OAWebBeanContainerHelper.java:244)
         at oracle.apps.fnd.framework.webui.OAPageLayoutHelper.processRequest(OAPageLayoutHelper.java:920)
         at oracle.apps.fnd.framework.webui.beans.layout.OAPageLayoutBean.processRequest(OAPageLayoutBean.java:1536)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processRequestChildren(OAWebBeanHelper.java:866)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processRequestChildren(OAWebBeanHelper.java:833)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processRequest(OAWebBeanHelper.java:575)
         at oracle.apps.fnd.framework.webui.OAWebBeanContainerHelper.processRequest(OAWebBeanContainerHelper.java:244)
         at oracle.apps.fnd.framework.webui.beans.form.OAFormBean.processRequest(OAFormBean.java:363)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processRequestChildren(OAWebBeanHelper.java:866)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processRequestChildren(OAWebBeanHelper.java:833)
         at oracle.apps.fnd.framework.webui.OAWebBeanHelper.processRequest(OAWebBeanHelper.java:575)
         at oracle.apps.fnd.framework.webui.OAWebBeanContainerHelper.processRequest(OAWebBeanContainerHelper.java:244)
         at oracle.apps.fnd.framework.webui.beans.OABodyBean.processRequest(OABodyBean.java:330)
         at oracle.apps.fnd.framework.webui.OAPageBean.processRequest(OAPageBean.java:2121)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:1562)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:463)
         at oracle.apps.fnd.framework.webui.OAPageBean.preparePage(OAPageBean.java:384)
         at _OA._jspService(OA.jsp:40)
         at com.orionserver.http.OrionHttpJspPage.service(OrionHttpJspPage.java:56)
         at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:317)
         at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:465)
         at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:379)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:727)
         at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:306)
         at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:767)
         at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:259)
         at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:106)
         at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:803)
         at java.lang.Thread.run(Thread.java:534)
    Code I am using to invoke is:
              Hashtable jndi = null;
              jndi = new Hashtable();
              jndi.put(Context.PROVIDER_URL, "ormi://142.176.225.111:23791/orabpel");
              jndi.put(Context.INITIAL_CONTEXT_FACTORY, "com.evermind.server.rmi.RMIInitialContextFactory");
              jndi.put(Context.SECURITY_PRINCIPAL, "oc4jadmin");
              jndi.put(Context.SECURITY_CREDENTIALS, "welcome1");
              Locator locator = new Locator("default", "welcome1", jndi);
              IDeliveryService deliveryService = (IDeliveryService)locator.lookupService(IDeliveryService.SERVICE_NAME );
              //System.out.println("4444");
              String xml ="<FirstTestBPELProcessProcessRequest xmlns=\"http://xmlns.oracle.com/FirstTestBPELProcess\"><input>123456789</input></FirstTestBPELProcessProcessRequest>";
              NormalizedMessage nm = new NormalizedMessage( );
              nm.addPart("payload", xml );
              NormalizedMessage res = deliveryService.request("FirstTestBPELProcess", "process", nm);
              Map payload = res.getPayload();
              Element elem = (Element)payload.get("payload");
    This code works excellent when called from a stand alone java class but it is not working when it is called from an OA Page.
    Can some one provide any pointer to the error.

    I think that your problem is that the Context.PROVIDER_URL is wrong.
    Here is a sample of url that we use here:
    opmn:ormi://servername:6005:home/orabpel
    where:
    "servername" is (duh) the servername
    "home" is the container that bpel is running
    "6005" is the opmn port.

  • Creating and deploying ejb 3.0 session bean with annotated pojo

    I try to create and deploy a EJB 3.0 stateless session bean (and associated webservice) with the following steps:
    1) Create Interface "Repository"
    package de.xxx.config;
    import java.rmi.Remote;
    import java.rmi.RemoteException;
    import javax.jws.WebMethod;
    import javax.jws.WebService;
    @WebService
    public interface Repository extends Remote {
         @WebMethod(operationName = "findCampaignByChannel")
         public String findCampaignByChannel(String channelName) throws RemoteException;
    2) create dummy "RepositoryImpl"
    package de.xxx.config;
    import java.rmi.RemoteException;
    import javax.ejb.Stateless;
    import javax.jws.WebService;
    @WebService(endpointInterface="de.xxx.config.Repository")
    @Stateless
    public class RepositoryImpl implements Repository {
         public String findCampaignByChannel(String channelName) throws RemoteException {
              return null;
    3) The two class files are packaged into a jar without any further descriptors
    4) The jar is deployed with admin_client into the oc4j instance using the commands:
    -deploy -file <jarfile> -deploymentName <name>
    Result:
    An ear was constructed and started but no session bean or webservice is found (using the console). But according to to the docs a jar file without a ejb-jar.xml should be recognized as a EJB 3.0 ejb-jar file and the necessary steps to create session bean and expose webservice should be done automatically.
    My question:
    Which step do i miss here ?
    Tools used:
    Eclipse 3.2 for the jar file
    SoaSuite 10.1.3.1 for oc4j

    another strange problem.
    i have an APplication server added ( JBOSS ).
    when i create deployment profile (EAR ) application server is showed in the ComboBox .
    But when i create Java Test Client for some EJB and when i check " Connect Remote Application server" there is 2 comboboxes
    J2EE Application
    App Server Connection.
    first combo is ok there is EJB applicaiton
    Secound is empty .. but i Have App Server.
    Another think is that when i create EJB 3.0 its BAD to see J2EE app it must be J EE 5 app or just Java EE app

  • Error when Create Session Bean in JDeveloper

    Hi All,
    I followed the steps in the SRDemo tutorial to create Session bean SRPublicFacade. I used Create Session Bean wizard. Step 1 was ok. Step 2 when it's supposed to show all the POJOs and all methods (from Queries) it hang there, and skipped to Step 3 and so on... As a result I had an empty Session Bean with only class name and no methods in it. I do have correct database connection, and I have another project with similar Session Bean sucessfully. I just don't know what happened to this project or the way I created session bean this time. Any conflict when create Session Bean to the same database or something(?) Anyone has any idea please let me know.
    Thank you very much,
    John

    Frank,
    Yes, I compiled the project before building the session facade. I used JDeveloper 10.1.3.3.0
    The thing is I once created successfully the session facade in another project, like SRdemo. Now I would like to repeat that in another project say SRdemo2, then it went wrong. It skipped step 2 in the wizard and look like it cannot detect the tables and named queries.
    Thanks,
    John

  • Possible to create a JAX-WS, session-bean-based webservice for WebLogic 10?

    All,
    sorry - but I'm going a bit crazy here. I have been unable to figure out the secret hand-shakes for developing a session-bean-based web service that will run properly under Weblogic 10.0. There are examples out there on how to create webservices that exists within a war file - but none that I can find that reside within a session bean (an ear file).
    I can't even figure out how to do with this Bea Workshop for WebLogic Platform 10.0! Is this possible? I can't find any examples anywhere on how to do this. I must be missing something...
    Does WebLogic 10.0 support web services within session beans? I've figured out how to do this with JBoss, Sun App Server, and Glassfish - but no luck so far with WebLogic.
    If anyone can please point me in the proper direction it would be very appreciated. My company likes WebLogic, but we have to be able to do this in order to continue using it.
    Thanks,
    -john

    Yeah - I've tried that. Everything builds fine - but when I deploy to WebLogic 10, I get the stack below. It looks like it is looking for the class examples.webservices.jaxws.jaxws.SayHello - but there isn't such a class in the example...
    Any thoughts? I'm completely stuck!
    <Apr 16, 2007 4:15:45 PM PDT> <Error> <HTTP> <BEA-101216> <Servlet: "WSEE_SERVLET" failed to preload on startup in Web application: "/SimpleEjbImpl".
    class: examples.webservices.jaxws.jaxws.SayHello could not be found
    at com.sun.xml.ws.model.RuntimeModeler.getClass(RuntimeModeler.java:272)
    at com.sun.xml.ws.model.RuntimeModeler.processDocWrappedMethod(RuntimeModeler.java:566)
    at com.sun.xml.ws.model.RuntimeModeler.processMethod(RuntimeModeler.java:513)
    at com.sun.xml.ws.model.RuntimeModeler.processClass(RuntimeModeler.java:358)
    at com.sun.xml.ws.model.RuntimeModeler.buildRuntimeModel(RuntimeModeler.java:245)
    Truncated. see log file for complete stacktrace
    >
    <Apr 16, 2007 4:15:45 PM PDT> <Error> <Deployer> <BEA-149265> <Failure occurred in the execution of deployment request with ID '1176765341457' for task '0'. Error is: 'weblogic.application.ModuleException: Exception activating module: EJBModule(WL6-ejb.jar)
    Unable to deploy EJB: SimpleEjbImpl from WL6-ejb.jar:
    Unable to deploy EJB: WL6-ejb.jar from WL6-ejb.jar:
    [HTTP:101216]Servlet: "WSEE_SERVLET" failed to preload on startup in Web application: "/SimpleEjbImpl".
    class: examples.webservices.jaxws.jaxws.SayHello could not be found
    at com.sun.xml.ws.model.RuntimeModeler.getClass(RuntimeModeler.java:272)
    at com.sun.xml.ws.model.RuntimeModeler.processDocWrappedMethod(RuntimeModeler.java:566)
    at com.sun.xml.ws.model.RuntimeModeler.processMethod(RuntimeModeler.java:513)
    at com.sun.xml.ws.model.RuntimeModeler.processClass(RuntimeModeler.java:358)
    at com.sun.xml.ws.model.RuntimeModeler.buildRuntimeModel(RuntimeModeler.java:245)
    at com.sun.xml.ws.server.EndpointFactory.createSEIModel(EndpointFactory.java:229)
    at com.sun.xml.ws.server.EndpointFactory.createEndpoint(EndpointFactory.java:161)
    at com.sun.xml.ws.api.server.WSEndpoint.create(WSEndpoint.java:291)
    at com.sun.xml.ws.api.server.WSEndpoint.create(WSEndpoint.java:315)
    at weblogic.wsee.jaxws.JAXWSServlet.registerEndpoint(JAXWSServlet.java:125)
    at weblogic.wsee.jaxws.JAXWSServlet.init(JAXWSServlet.java:64)
    at javax.servlet.GenericServlet.init(GenericServlet.java:241)
    at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.java:282)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
    at weblogic.security.service.SecurityManager.runAs(Unknown Source)
    at weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:63)
    at weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java:58)
    at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHelper.java:48)
    at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:504)
    at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:1830)
    at weblogic.servlet.internal.WebAppServletContext.loadServletsOnStartup(WebAppServletContext.java:1807)
    at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1727)
    at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:2890)
    at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:948)
    at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:353)
    at weblogic.wsee.deploy.WseeWebappModule.activate(WseeWebappModule.java:139)
    at weblogic.wsee.deploy.WSEEEjbModule.activate(WSEEEjbModule.java:371)
    at weblogic.wsee.deploy.WsEJBDeployListener.activate(WsEJBDeployListener.java:52)
    at weblogic.ejb.container.deployer.EJBDeployer.activate(EJBDeployer.java:1414)
    at weblogic.ejb.container.deployer.EJBModule.activate(EJBModule.java:423)
    at weblogic.application.internal.flow.ModuleListenerInvoker.activate(ModuleListenerInvoker.java:107)
    at weblogic.application.internal.flow.DeploymentCallbackFlow$2.next(DeploymentCallbackFlow.java:381)
    at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
    at weblogic.application.internal.flow.DeploymentCallbackFlow.activate(DeploymentCallbackFlow.java:71)
    at weblogic.application.internal.flow.DeploymentCallbackFlow.activate(DeploymentCallbackFlow.java:63)
    at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:635)
    at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
    at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:212)
    at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:154)
    at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80)
    at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:566)
    at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:136)
    at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:104)
    at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:320)
    at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:816)
    at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1223)
    at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:434)
    at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:161)
    at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:181)
    at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:12)
    at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:67)
    at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:464)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:200)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:172)
    weblogic.application.ModuleException: Exception activating module: EJBModule(WL6-ejb.jar)
    Unable to deploy EJB: SimpleEjbImpl from WL6-ejb.jar:
    Unable to deploy EJB: WL6-ejb.jar from WL6-ejb.jar:
    [HTTP:101216]Servlet: "WSEE_SERVLET" failed to preload on startup in Web application: "/SimpleEjbImpl".
    class: examples.webservices.jaxws.jaxws.SayHello could not be found
    at com.sun.xml.ws.model.RuntimeModeler.getClass(RuntimeModeler.java:272)
    at com.sun.xml.ws.model.RuntimeModeler.processDocWrappedMethod(RuntimeModeler.java:566)
    at com.sun.xml.ws.model.RuntimeModeler.processMethod(RuntimeModeler.java:513)
    at com.sun.xml.ws.model.RuntimeModeler.processClass(RuntimeModeler.java:358)
    at com.sun.xml.ws.model.RuntimeModeler.buildRuntimeModel(RuntimeModeler.java:245)
    at com.sun.xml.ws.server.EndpointFactory.createSEIModel(EndpointFactory.java:229)
    at com.sun.xml.ws.server.EndpointFactory.createEndpoint(EndpointFactory.java:161)
    at com.sun.xml.ws.api.server.WSEndpoint.create(WSEndpoint.java:291)
    at com.sun.xml.ws.api.server.WSEndpoint.create(WSEndpoint.java:315)
    at weblogic.wsee.jaxws.JAXWSServlet.registerEndpoint(JAXWSServlet.java:125)
    at weblogic.wsee.jaxws.JAXWSServlet.init(JAXWSServlet.java:64)
    at javax.servlet.GenericServlet.init(GenericServlet.java:241)
    at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.java:282)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
    at weblogic.security.service.SecurityManager.runAs(Unknown Source)
    at weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:63)
    at weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java:58)
    at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHelper.java:48)
    at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:504)
    at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:1830)
    at weblogic.servlet.internal.WebAppServletContext.loadServletsOnStartup(WebAppServletContext.java:1807)
    at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1727)
    at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:2890)
    at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:948)
    at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:353)
    at weblogic.wsee.deploy.WseeWebappModule.activate(WseeWebappModule.java:139)
    at weblogic.wsee.deploy.WSEEEjbModule.activate(WSEEEjbModule.java:371)
    at weblogic.wsee.deploy.WsEJBDeployListener.activate(WsEJBDeployListener.java:52)
    at weblogic.ejb.container.deployer.EJBDeployer.activate(EJBDeployer.java:1414)
    at weblogic.ejb.container.deployer.EJBModule.activate(EJBModule.java:423)
    at weblogic.application.internal.flow.ModuleListenerInvoker.activate(ModuleListenerInvoker.java:107)
    at weblogic.application.internal.flow.DeploymentCallbackFlow$2.next(DeploymentCallbackFlow.java:381)
    at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
    at weblogic.application.internal.flow.DeploymentCallbackFlow.activate(DeploymentCallbackFlow.java:71)
    at weblogic.application.internal.flow.DeploymentCallbackFlow.activate(DeploymentCallbackFlow.java:63)
    at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:635)
    at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
    at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:212)
    at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:154)
    at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80)
    at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:566)
    at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:136)
    at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:104)
    at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:320)
    at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:816)
    at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1223)
    at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:434)
    at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:161)
    at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:181)
    at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:12)
    at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:67)
    at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:464)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:200)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:172)
    at weblogic.ejb.container.deployer.EJBModule.activate(EJBModule.java:440)
    at weblogic.application.internal.flow.ModuleListenerInvoker.activate(ModuleListenerInvoker.java:107)
    at weblogic.application.internal.flow.DeploymentCallbackFlow$2.next(DeploymentCallbackFlow.java:381)
    at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
    at weblogic.application.internal.flow.DeploymentCallbackFlow.activate(DeploymentCallbackFlow.java:71)
    Truncated. see log file for complete stacktrace
    class: examples.webservices.jaxws.jaxws.SayHello could not be found
    at com.sun.xml.ws.model.RuntimeModeler.getClass(RuntimeModeler.java:272)
    at com.sun.xml.ws.model.RuntimeModeler.processDocWrappedMethod(RuntimeModeler.java:566)
    at com.sun.xml.ws.model.RuntimeModeler.processMethod(RuntimeModeler.java:513)
    at com.sun.xml.ws.model.RuntimeModeler.processClass(RuntimeModeler.java:358)
    at com.sun.xml.ws.model.RuntimeModeler.buildRuntimeModel(RuntimeModeler.java:245)
    Truncated. see log file for complete stacktrace
    >
    <Apr 16, 2007 4:15:46 PM PDT> <Error> <Deployer> <BEA-149202> <Encountered an exception while attempting to commit the 1 task for the application '_appsdir_WL6_ear'.>
    <Apr 16, 2007 4:15:46 PM PDT> <Warning> <Deployer> <BEA-149004> <Failures were detected while initiating deploy task for application '_appsdir_WL6_ear'.>
    <Apr 16, 2007 4:15:46 PM PDT> <Warning> <Deployer> <BEA-149078> <Stack trace for message 149004
    weblogic.application.ModuleException: Exception activating module: EJBModule(WL6-ejb.jar)
    Unable to deploy EJB: SimpleEjbImpl from WL6-ejb.jar:
    Unable to deploy EJB: WL6-ejb.jar from WL6-ejb.jar:
    [HTTP:101216]Servlet: "WSEE_SERVLET" failed to preload on startup in Web application: "/SimpleEjbImpl".
    class: examples.webservices.jaxws.jaxws.SayHello could not be found
    at com.sun.xml.ws.model.RuntimeModeler.getClass(RuntimeModeler.java:272)
    at com.sun.xml.ws.model.RuntimeModeler.processDocWrappedMethod(RuntimeModeler.java:566)
    at com.sun.xml.ws.model.RuntimeModeler.processMethod(RuntimeModeler.java:513)
    at com.sun.xml.ws.model.RuntimeModeler.processClass(RuntimeModeler.java:358)
    at com.sun.xml.ws.model.RuntimeModeler.buildRuntimeModel(RuntimeModeler.java:245)
    at com.sun.xml.ws.server.EndpointFactory.createSEIModel(EndpointFactory.java:229)
    at com.sun.xml.ws.server.EndpointFactory.createEndpoint(EndpointFactory.java:161)
    at com.sun.xml.ws.api.server.WSEndpoint.create(WSEndpoint.java:291)
    at com.sun.xml.ws.api.server.WSEndpoint.create(WSEndpoint.java:315)
    at weblogic.wsee.jaxws.JAXWSServlet.registerEndpoint(JAXWSServlet.java:125)
    at weblogic.wsee.jaxws.JAXWSServlet.init(JAXWSServlet.java:64)
    at javax.servlet.GenericServlet.init(GenericServlet.java:241)
    at weblogic.servlet.internal.StubSecurityHelper$ServletInitAction.run(StubSecurityHelper.java:282)
    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
    at weblogic.security.service.SecurityManager.runAs(Unknown Source)
    at weblogic.servlet.internal.StubSecurityHelper.createServlet(StubSecurityHelper.java:63)
    at weblogic.servlet.internal.StubLifecycleHelper.createOneInstance(StubLifecycleHelper.java:58)
    at weblogic.servlet.internal.StubLifecycleHelper.<init>(StubLifecycleHelper.java:48)
    at weblogic.servlet.internal.ServletStubImpl.prepareServlet(ServletStubImpl.java:504)
    at weblogic.servlet.internal.WebAppServletContext.preloadServlet(WebAppServletContext.java:1830)
    at weblogic.servlet.internal.WebAppServletContext.loadServletsOnStartup(WebAppServletContext.java:1807)
    at weblogic.servlet.internal.WebAppServletContext.preloadResources(WebAppServletContext.java:1727)
    at weblogic.servlet.internal.WebAppServletContext.start(WebAppServletContext.java:2890)
    at weblogic.servlet.internal.WebAppModule.startContexts(WebAppModule.java:948)
    at weblogic.servlet.internal.WebAppModule.start(WebAppModule.java:353)
    at weblogic.wsee.deploy.WseeWebappModule.activate(WseeWebappModule.java:139)
    at weblogic.wsee.deploy.WSEEEjbModule.activate(WSEEEjbModule.java:371)
    at weblogic.wsee.deploy.WsEJBDeployListener.activate(WsEJBDeployListener.java:52)
    at weblogic.ejb.container.deployer.EJBDeployer.activate(EJBDeployer.java:1414)
    at weblogic.ejb.container.deployer.EJBModule.activate(EJBModule.java:423)
    at weblogic.application.internal.flow.ModuleListenerInvoker.activate(ModuleListenerInvoker.java:107)
    at weblogic.application.internal.flow.DeploymentCallbackFlow$2.next(DeploymentCallbackFlow.java:381)
    at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
    at weblogic.application.internal.flow.DeploymentCallbackFlow.activate(DeploymentCallbackFlow.java:71)
    at weblogic.application.internal.flow.DeploymentCallbackFlow.activate(DeploymentCallbackFlow.java:63)
    at weblogic.application.internal.BaseDeployment$2.next(BaseDeployment.java:635)
    at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
    at weblogic.application.internal.BaseDeployment.activate(BaseDeployment.java:212)
    at weblogic.application.internal.DeploymentStateChecker.activate(DeploymentStateChecker.java:154)
    at weblogic.deploy.internal.targetserver.AppContainerInvoker.activate(AppContainerInvoker.java:80)
    at weblogic.deploy.internal.targetserver.operations.AbstractOperation.activate(AbstractOperation.java:566)
    at weblogic.deploy.internal.targetserver.operations.ActivateOperation.activateDeployment(ActivateOperation.java:136)
    at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doCommit(ActivateOperation.java:104)
    at weblogic.deploy.internal.targetserver.operations.AbstractOperation.commit(AbstractOperation.java:320)
    at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentCommit(DeploymentManager.java:816)
    at weblogic.deploy.internal.targetserver.DeploymentManager.activateDeploymentList(DeploymentManager.java:1223)
    at weblogic.deploy.internal.targetserver.DeploymentManager.handleCommit(DeploymentManager.java:434)
    at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.commit(DeploymentServiceDispatcher.java:161)
    at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doCommitCallback(DeploymentReceiverCallbackDeliverer.java:181)
    at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$100(DeploymentReceiverCallbackDeliverer.java:12)
    at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$2.run(DeploymentReceiverCallbackDeliverer.java:67)
    at weblogic.work.SelfTuningWorkManagerImpl$WorkAdapterImpl.run(SelfTuningWorkManagerImpl.java:464)
    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:200)
    at weblogic.work.ExecuteThread.run(ExecuteThread.java:172)
    at weblogic.ejb.container.deployer.EJBModule.activate(EJBModule.java:440)
    at weblogic.application.internal.flow.ModuleListenerInvoker.activate(ModuleListenerInvoker.java:107)
    at weblogic.application.internal.flow.DeploymentCallbackFlow$2.next(DeploymentCallbackFlow.java:381)
    at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
    at weblogic.application.internal.flow.DeploymentCallbackFlow.activate(DeploymentCallbackFlow.java:71)
    Truncated. see log file for complete stacktrace
    class: examples.webservices.jaxws.jaxws.SayHello could not be found
    at com.sun.xml.ws.model.RuntimeModeler.getClass(RuntimeModeler.java:272)
    at com.sun.xml.ws.model.RuntimeModeler.processDocWrappedMethod(RuntimeModeler.java:566)
    at com.sun.xml.ws.model.RuntimeModeler.processMethod(RuntimeModeler.java:513)
    at com.sun.xml.ws.model.RuntimeModeler.processClass(RuntimeModeler.java:358)
    at com.sun.xml.ws.model.RuntimeModeler.buildRuntimeModel(RuntimeModeler.java:245)
    Truncated. see log file for complete stacktrace
    >

  • How to send message to MessageDrivenBean from Session bean in JDeveloper

    HI I am trying to write a sample program using JDeveloper.
    I am trying to do these steps
    1) client class which gets Session bean and calls its method.
    2) write Stateless Session bean with a method which gets MDB and sends message.
    3) write Message Driven Bean ( which prints message recieved from Session bean )
    Set up
    =======
    jms.xml
    {JDevHome}\jdev\system9.0.5.2.1618\oc4j-config\jms.xml : changed jms.xml file and included
         <topic name="Demo Topic" location="jms/theTopic">
              <description>A dummy topic</description>
         </topic>
         <topic-connection-factory name="Demo Topic Connection Factory" location="jms/theTopicConnectionFactory">
              <description>A dummy topic connection factory</description>
         </topic-connection-factory>
    orion-ejb-jar.xml:
    edited MDB entry to
    <message-driven-deployment name="MessageLogger"
    destination-location="jms/theTopic" connection-factory-location="jms/theTopicConnectionFactory">
    </message-driven-deployment>
    Implementation
    ===============
    In client class:
    I am getting session bean like
    Properties props = System.getProperties();
    props.put( javax.naming.Context.INITIAL_CONTEXT_FACTORY , "com.evermind.server.rmi.RMIInitialContextFactory");
    props.put( javax.naming.Context.SECURITY_PRINCIPAL , "admin" );
    props.put( javax.naming.Context.SECURITY_CREDENTIALS,"welcome");
    props.put( javax.naming.Context.PROVIDER_URL ,"ormi://localhost:23891/current-workspace-app");
    Context ctx = new InitialContext(props);
    MySessionHome home = (MySessionHome)
              javax.rmi.PortableRemoteObject.narrow(obj, MySessionHome.class);
    This part works fine, and I am calling method on session bean created out of home.
    In Session bean:
    I want to get TopicConnectionFactory and tried these two ways:
    a)
    getting the context by setting new environemnt values like
    Properties props = System.getProperties();
    props.put( javax.naming.Context.INITIAL_CONTEXT_FACTORY , "com.evermind.server.jms.EvermindConnectionFactory");
    props.put( javax.naming.Context.SECURITY_PRINCIPAL , "admin" );
    props.put( javax.naming.Context.SECURITY_CREDENTIALS,"welcome");
    props.put( javax.naming.Context.PROVIDER_URL ,"ormi://localhost:9227/current-workspace-app");
    Context ctx = new InitialContext( props);
    When I try this,it is complaining that it cannot instantiate EvermindConnectionFactory.
    I am not sure which factory class we have to use here.i tried all the Factory class in that package.but didn't worked.
    next I used,
    b)
    tried to use default context in session bean to get MDB factory
    String TOPIC_NAME="jms/theTopic";
    String TOPIC_CONNECTION_FACTORY="jms/theTopicConnectionFactory";
    TopicConnectionFactory connectionFactory = (TopicConnectionFactory)new InitialContext().lookup("java:comp/env/" + TOPIC_CONNECTION_FACTORY);
    this gives
    04/06/13 23:46:09 javax.naming.NameNotFoundException: jms/theTopicConnectionFactory not found in MySession
    04/06/13 23:46:09      at com.oracle.naming.J2EEContext.getSubContext(J2EEContext.java:93)
    this may be because JMS server runs on different port than other EJBs and have different namespaces.
    Can any body give info,how we can make use of Message Driven bean from a Session Bean or from a JSP page or from a simple class inside JDeveloper.
    Thanks in advance.
    gopal

    Hi,
    There are some hints in this forum for how to do this.
    I put together and make it working.
    This example creates an MD Bean and have a simple message and a client class send messages to that bean.
    Steps
    =====
    1)
    a)in {JDev Home}\jdev\system9.0.5.2.1618\oc4j-config\jms.xml
         <topic name="Demo Topic" location="jms/demoTopic">
              <description>A dummy topic</description>
         </topic>
         <topic-connection-factory name="Demo Topic Connection Factory" location="jms/theTopicConnectionFactory">
              <description>A dummy topic connection factory</description>
         </topic-connection-factory>
    b) in current project in orion-ejb-jar.xml
    go to orion-ejb-jar properties and add these values there to MDB node
    destination-location=jms/demoTopic
    connection-factory-location=jms/theTopicConnectionFactory
    2) create a dummy session bean and a dummy client for that session bean
    This sets default configuration for the client application we write
    doing so we do not need to set properties to get Initial context.It makes use of
    {JDev Home}\jdev\system9.0.5.2.1618\oc4j-config\.client\jndi.properties
    We can directly get Contexxt ctx = new InitialContext();
    3) Create MDB and put this sample code in method
    onMessage()
    TextMessage tm = (TextMessage) msg;
    try {
    String text = tm.getText();
    System.err.println("Received new message : " + text);
    catch(JMSException e) {
    e.printStackTrace();
    4) go to properties for the MDB and set Destination to Topic
    5) write Client code
    Context ctx =new InitialContext();
    // 1: Lookup ConnectionFactory via JNDI
    TopicConnectionFactory factory =     
    (TopicConnectionFactory) ctx.lookup("jms/theTopicConnectionFactory");
    // 2: Use ConnectionFactory to create JMS connection
    TopicConnection connection = factory.createTopicConnection();
    // 3: Use Connection to create session
    TopicSession session = connection.createTopicSession( false, Session.AUTO_ACKNOWLEDGE);
    // 4: Lookup Desintation (topic) via JNDI
    Topic topic = (Topic) ctx.lookup("jms/demoTopic");
    // 5: Create a Message Producer
    TopicPublisher publisher = session.createPublisher(topic);
    // 6: Create a text message, and publish it
    TextMessage msg = session.createTextMessage();
    msg.setText("This is a test message from My Test Client!!! .");
    publisher.publish(msg);
    6) Run the server and run the client

  • How to call a EJB method from Session bean method

    Hi all,
    I'm new to J2EE programming. I have a simple doubt .
    I have already created a lookup method for EJB bean in Session bean .
    My question is how to call a method of an ENTITY bean (say insertRow) from SESSION bean method(Say invoke_insertRow) .
    Please provide me an example code .
    Thanks in advance.

    InitialContext ctx = new InitialContext();
         GeneralEditor editor = (GeneralEditor) ctx
                        .lookup("GeneralEditorBean/remote");
              GeneralService service = (GeneralService) ctx
                        .lookup("GeneralServiceBean/remote");
              LanMu lm = new LanMu();
              lm.setName("shdfkhsad");
              editor.add(lm);

  • JDEV 10.1.3 How to manipulate/Debug IndirectList from ejb 3.0 session bean

    I was debugging my session bean a seen that element data for the employeesCollection was empty.
    I didn't understood why my java client was throwing an error when i accessed manually the Departments collection and get the employeeCollection from the first entry in the collection. What was confusing me was that my master/detail jfs application was displaying these data. From where ? how was it possible ? it was the same session bean !
    This is the reason i debugged the session bean return object and seen that the collection was also empty as the from executing from my java client application. I have seen the type of the object that was not a collection but IndirectList.
    So my question ! how is it possible to load the collection of this type ? Which method the data control is executing to load it ? Where may i found a description of this very interesting process ?

    Hi Frank.
    plain English - on plan :).
    I create managed bean with function which do access to LDAP and this function 'return List<Users>'.
    In JDeveloper :) on managed bean(java class) i create "Create Data Control"... after, from Data Controls i drop on page this data(create ADF Table with selectOne)...
    First Page Ready!
    Second page... i need to know which option selected on first page. This option(row) contains, UserName and etc... On second page i again fetch data, from LDAP, associated with this concrete UserName... Because i fetch data using managed bean :) i need to know this username in my managed bean...
    May be :) im wrong...
    sessionAttribute - like this? ->
    * Convenience method for setting Session variables
    * @param ctx FacesContext
    * @param key object key
    * @param object value to store
    public static void storeOnSession(FacesContext ctx, String key, Object object) {
    Map sessionState = ctx.getExternalContext().getSessionMap();
    sessionState.put(key, object);
    * Convenience method for getting Session variables
    * @param ctx FacesContext
    * @param key object key
    public static Object getFromSession(FacesContext ctx, String key) {
    Map sessionState = ctx.getExternalContext().getSessionMap();
    return sessionState.get(key);
    }

  • How do I lookup an EJB 3.0 Session bean from servlet or JSP?

    Does anyone knows how can I invoke an EJB from a servlet or JSP ?
    I deployed a simple EJB on a Oracle Application Server 10g release 10.1.3 and I'm working with JDeveloper 10.1.3. I deployed the files via JDeveloper, and I didn´t specify any orion-ejb-jar.xml or ejb-jar.xml file
    After deployment, the orion-ejb-jar.xml look like this in the server:
    <?xml version="1.0" encoding="utf-8"?>
    <orion-ejb-jar xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://xmlns.oracle.com/oracleas/schema/orion-ejb-jar-10_0.xsd" deployment-version="10.1.3.0.0" deployment-time="10b49516c8f" schema-major-version="10" schema-minor-version="0" >
    <enterprise-beans>
    <session-deployment name="HolaMundoEJB" location="HolaMundoEJB" local-location="HolaMundoEJB_HolaMundoEJBLocal" local-wrapper-name="HolaMundoEJBLocal_StatelessSessionBeanWrapper6" remote-wrapper-name="HolaMundoEJB_StatelessSessionBeanWrapper7" persistence-filename="HolaMundoEJB.home_default_group_1">
    </session-deployment>
    </enterprise-beans>
    <assembly-descriptor>
    <default-method-access>
    <security-role-mapping name="<default-ejb-caller-role>" impliesAll="true" />
    </default-method-access>
    </assembly-descriptor>
    </orion-ejb-jar>
    I'm trying to invoke the ejb in a servlet by doing the following:
    public void doGet(HttpServletRequest request, ....
    Context context = new InitialContext();
    HolaMundoEJB helloWorld =
    (HolaMundoEJB)context.lookup("java:com/env/ejb/HolaMundoEJB");
    String respuesta = helloWorld.sayHello("David");
    When i invoke the servlet I catch a NamingException whose message says something
    like this ....java:com/env/ejb/HolaMundoEJB not found in webLlamaEJB
    I tried different paths for the lookup but nothing....
    Can anyone help me with this topic? Thank you.

    Please try the following code:
    HelloEJBBean.java:
    @Stateless(name="Hello")
    @Remote(value={Hello.class})
    public class HelloEJBBean implements Hello {  ... }
    hello.jsp:
    Context ctx = new InitialContext();
    Hello h = (Hello)ctx.lookup("ejb/Hello");
    web.xml:
    <ejb-ref>
    <ejb-ref-name>ejb/Hello</ejb-ref-name>
    <ejb-ref-type>Session</ejb-ref-type>
    <remote>fi.kronodoc.test.model.Hello</remote>
    </ejb-ref>
    i think you should also define jndi mappings for the references in orion-ejb-jar.xml and orion-web.xml but for some reason it seems to be working also without these.

Maybe you are looking for

  • Installation oracle database 10.2 on mac snow leopard server

    Hi., I am trying to install oracle database 10.2 on mac server snow leopard but getting following error: rsgsoftware:Disk1 oracle$ ./runInstaller Starting Oracle Universal Installer... No pre-requisite checks found in oraparam.ini, no system pre-requ

  • How can you Copyright your photos in iWeb

    Does anyone know how to copyright your photos in iWeb so that others can download your images and claim them as their own?? thanks

  • Installation of SAP Netweaver 7.0 with SAP R/3 Enterprise 4.70 backend

    Hello everybody, I need to install an SAP Netweaver 7.0 environment for a client who is currently using SAP R/3 Enterprise 4.70. However, I couldn't find any document about the compatibility of the two. Does anybody know if it is possible to connect

  • Apple TV still not working?

    My apple TV doesn't respond to remote. I've changed the batteries and tried the menu back button and still get nothing

  • Form problem - invalid input

    iv been using the same code to make input forms ever since i started but im having this recurring problem with one form. when people fill in the form when they hit send, sometimes it sends and other times it goes to a blank screen which says "invalid