5 Replies Latest reply on Oct 14, 2006 7:36 AM by 666705

    Tutorial 11 - Encountering problem on JNDI

    666705
      When I first run ant prepare build.split.dir I go the message,

      BUILD FAILED
      file:C:/medrec_tutorial/src/medrecEar/build.xml:62: Warning: Could not find file C:\medrec_tutorial\build\value.jar to copy.

      So I just copied these from sample\server\medrec\build. Then it seems ok.

      But there were some messages about JNDI dotted throughout the system log.

      Example
      --------
      [java] C:\medrec_tutorial\build\medrecEar\entityEjbs\com\bea\medrec\entities\AddressEJB.java:54: Warning: No JNDI name
      was found.
      [java] C:\medrec_tutorial\build\medrecEar\entityEjbs\com\bea\medrec\entities\GroupEJB.java:38: Warning: No JNDI name was
      found.

      --------

      I then continues to deployed, and I go the following message:

      C:\medrec_tutorial\src\medrecEar>ant -f my_webserv.xml deploy
      Buildfile: my_webserv.xml

      deploy:
      [wldeploy] weblogic.Deployer -noexit -name medrec_deployment -source C:\medrec_tutorial\build\medrecEar -adminurl t3://127.0.0.1:7101 -user weblogic -password
      ******** -deploy
      [wldeploy] Initiated Task: [3] [Deployer:149026]Deploy application medrec_deployment on MedRecServer.
      [wldeploy] Task 3 failed: [Deployer:149026]Deploy application medrec_deployment on MedRecServer.
      [wldeploy] Deployment failed on Server MedRecServer
      [wldeploy] weblogic.management.DeploymentException:
      [wldeploy] Exception:weblogic.management.ApplicationException: activate failed for entityEjbs
      [wldeploy] Module: entityEjbs Error: Exception activating module: EJBModule(entityEjbs,status=PREPARED)


      [wldeploy] Unable to deploy EJB: RecordEJB from entityEjbs:

      [wldeploy] [EJB:011028]The DataSource with the JNDI name: MedRecTxDataSource could not be located. Please ensure that the DataSource has been deployed successf
      ully and that the JNDI name in your EJB Deployment descriptor is correct.




      [wldeploy] weblogic.Deployer$DeployerException: Deployment exit status=1


      BUILD FAILED
      file:C:/medrec_tutorial/src/medrecEar/my_webserv.xml:28: weblogic.Deployer$DeployerException: Deployment exit status=1

      Can anyone help?

      Joe
        • 1. Re: Tutorial 11 - Encountering problem on JNDI
          666705
          Hey Joe.

          The build output shows JNDI warnings because the Entity EJBs are not configured with JNDI names. This is because the EJBs are Local rather than Remote; thus, JNDI names are unnecessary.

          The real problem as to why the EJB was not deployed is:

          "[wldeploy] [EJB:011028]The DataSource with the JNDI name: MedRecTxDataSource could not be located. Please ensure that the DataSource has been deployed successf
          ully and that the JNDI name in your EJB Deployment descriptor is correct."

          In "Step 3: Create a JDBC DataSource" of Tutorial 3, the instructions walk you through creating a datasouce named "MedRecTxDataSource" that maps to a connection pool created in an earlier step. Complete this tutorial prior to deploying MedRecEar.

          Hope that helps.

          -Chris

          Message was edited by cwall at Dec 13, 2004 5:54 PM
          • 2. Re: Tutorial 11 - Encountering problem on JNDI
            666705
            Hi,


            I am also facing same problem while deploying my EntityBeans(CMP) in Wls8.1 SP3.

            Whenever i try to deploy my entitybeans in Console its giving error as

            "Unable to deploy EJB: AccessLog from AccessLogEjb.jar: [EJB:011028]The DataSource with the JNDI name: emaster_tng could not be located. Please ensure that the DataSource has been deployed successfully and that the JNDI name in your EJB Deployment descriptor is correct. "


            As per your sugestion i sucessfully created datasouce emaster_tng.

            what should i give to JNDI Name while creating datasource.Currently i given that also as emaster_tng my datasource name.

            Please help in solving this issue by replying to
            • 3. Re: Tutorial 11 - Encountering problem on JNDI
              666705
              Prior to deploying your Entity EJBs, all resources must be configured and deployed. In your case it looks as if the DataSource that the EJBs are targeted to is not available. Based on the deployment exception, it appears the JNDI referenced by your Entity EJBs is "emaster_tng". This DataSource must be configured and deployed prior to deploying your Entity EJBs.

              This is the key part of the exception:
              "the JNDI name: emaster_tng"
              • 4. Re: Tutorial 11 - Encountering problem on JNDI
                666705
                Thanks for your reply

                Actually i first deployed my datasource and only deployed my entitybeans

                My datasource name was emaster_tng which was sucessfully deployed by console.

                I created my datasource as follows in console.

                Name: emaster_tng

                JNDI Name: emaster_tng (I think here is problem becuase in console itself its specifed as The JNDI path to where this JDBC data source is bound)
                But i don't know what value i need give in this field.We gave samething in our 6.1

                Pool name: Our connection pool name

                After that i fixed targets and deployed it its getting fine.

                Please help me in deplyiong datsource if thats problem.
                • 5. Re: Tutorial 11 - Encountering problem on JNDI
                  666705
                  In order for this to work you need to do the following. It looks as though Tutorial 3 is incorrect.

                  In the admin console under {MedRecDomain> JDBC Data Sources> MedRecTxDataSource} change "Pool Name" from "MedRecPool-PointBase-XA" to "MedRecPool-PointBase".

                  Don't forget to restart the Weblogic Server Instance afterwards.

                  Regards,

                  RG