facebook

Weblogic not working with Myeclipse

  1. MyEclipse Archived
  2.  > 
  3. Application Servers and Deployment
Viewing 11 posts - 1 through 11 (of 11 total)
  • Author
    Posts
  • #217946 Reply

    Hi
    I am not able to deploy Application on weblogic through Myeclipse.If i use the Weblogic outside myeclipse then i am able to deploy the same application , but with in Myeclipse i get following exception
    I have set all the Java build and Jre .still it is not able to find javac.Main.

    I am using Eclipse 3.0 M7 and Myeclipse 3.7

    Would be grateful if you can reply to this.

    Thanks
    Sandeep

    <Oct 19, 2004 2:39:46 PM GMT+05:30> <Info> <EJB> <BEA-010087> <The EJB deployment named: tessejb.jar is being recompiled within the WebLogic Server. Please consult the server logs if there are any errors. It is also possible to run weblogic.ejbc as a stand-alone tool to generate the required classes. The generated source files will be placed in E:\bea\user_projects\domains\mydomain\myserver\.wlnotdelete\EJBCompilerCache\4vx4h7u7mr64.>
    Compiler class: ‘com.sun.tools.javac.Main’, not found
    java.lang.ClassNotFoundException: com.sun.tools.javac.Main
    at java.net.URLClassLoader$1.run(URLClassLoader.java:198)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:186)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:299)
    at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:265)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:255)
    at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:315)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Class.java:140)
    at weblogic.utils.compiler.CompilerInvoker.compileMaybeExit(CompilerInvoker.java:406)
    at weblogic.utils.compiler.CompilerInvoker.compile(CompilerInvoker.java:328)
    at weblogic.utils.compiler.CompilerInvoker.compile(CompilerInvoker.java:336)
    at weblogic.ejb20.ejbc.EJBCompiler.doCompile(EJBCompiler.java:270)
    at weblogic.ejb20.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:476)
    at weblogic.ejb20.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:407)
    at weblogic.ejb20.deployer.EJBDeployer.runEJBC(EJBDeployer.java:493)
    at weblogic.ejb20.deployer.EJBDeployer.compileJar(EJBDeployer.java:762)
    at weblogic.ejb20.deployer.EJBDeployer.compileIfNecessary(EJBDeployer.java:700)
    at weblogic.ejb20.deployer.EJBDeployer.prepare(EJBDeployer.java:1317)
    at weblogic.ejb20.deployer.EJBModule.prepare(EJBModule.java:498)
    at weblogic.j2ee.J2EEApplicationContainer.prepareModule(J2EEApplicationContainer.java:3101)
    at weblogic.j2ee.J2EEApplicationContainer.prepareModules(J2EEApplicationContainer.java:1560)
    at weblogic.j2ee.J2EEApplicationContainer.prepare(J2EEApplicationContainer.java:1208)
    at weblogic.j2ee.J2EEApplicationContainer.prepare(J2EEApplicationContainer.java:1051)
    at weblogic.management.deploy.slave.SlaveDeployer$ComponentActivateTask.prepareContainer(SlaveDeployer.java:2444)
    at weblogic.management.deploy.slave.SlaveDeployer$ActivateTask.createContainer(SlaveDeployer.java:2394)
    at weblogic.management.deploy.slave.SlaveDeployer$ActivateTask.prepare(SlaveDeployer.java:2310)
    at weblogic.management.deploy.slave.SlaveDeployer.processPrepareTask(SlaveDeployer.java:866)
    at weblogic.management.deploy.slave.SlaveDeployer.prepareDelta(SlaveDeployer.java:594)
    at weblogic.management.deploy.slave.SlaveDeployer.prepareUpdate(SlaveDeployer.java:508)
    at weblogic.drs.internal.SlaveCallbackHandler$1.execute(SlaveCallbackHandler.java:25)
    at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:219)
    at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:178)

    #217960 Reply

    Riyad Kalla
    Member

    Sandeep,
    Make sure that under the Weblogic -> JDK settings you have selected a JDK, NOT a JRE. The class file that weblogic is looking for is in the tools.jar file that is distributed with your JDK.

    #218021 Reply

    @support-rkalla wrote:

    Sandeep,
    Make sure that under the Weblogic -> JDK settings you have selected a JDK, NOT a JRE. The class file that weblogic is looking for is in the tools.jar file that is distributed with your JDK.

    Thanks for reply Riyad.But i already did all that stuff , still it was giving problem.One thing i did after seeing your response is to add tools.jar in the path of the weblogic ,from myeclipse->j2ee->weblogic8->path only.
    Now it is working fine.
    But one other i am getting .I have one Driver to connect to SQL server,which my application invokes directly i.e not through Weblogic Datasource but directly using Class.forname(Driver) ; this statement is giving me exception of no suitable driver not found.Can you help me with this.As again i have added driver jar file to the classpath .

    Thanks
    Sandeep

    #218032 Reply

    Riyad Kalla
    Member

    Sandeep,
    You did the right thing by adding the driver to your classpath, you can also be sure to add the driver JAR to your WEB-INF/lib directory. However, if the driver also requires a DLL, you will need to add it to the last box in the Paths settings “Append to library path”, this is so the application can find the required supporting DLLs that the driver need. If there are no DLLs, then adding it to your classpath and WEB-INF/lib dir (Assuming ONLY your app uses the DB driver) should do the trick.

    #218033 Reply

    Scott Anderson
    Participant

    Sandeep,

    Many drivers not only have driver jars that need to go on the classpath, but also a native library. The directory containing the native library needs to be added to the Java library path on the “Paths” page in the connector configuration. Actually, now that I said that, this would make it available to the server, but if you’re trying to invoke it directly you might just need to package it with your application. For example, if you’re deploying a web project, place the jar in the WEB-INF/lib directory of the project.

    #218040 Reply

    Riyad Kalla
    Member

    I call Jinx!

    #218111 Reply

    Thanks Scott. This is why i put up my question.
    See when i load the weblogic from outside then application is connecting using thr Driver jar in Web-Inf/lib , but when i am starting my weblogic from myeclipse then it is not able to find the Driver 🙁 .
    Cos of this i am not able to use debugging feature.Any clue on this.

    Regards
    Sandeep

    #218129 Reply

    Scott Anderson
    Participant

    Sandeep,

    Can you check your deployment under the server and ensure that WEB-INF/lib contains your driver? If your application is deployed correctly, it would have to be something additional that the server startup needs. You’re not running WebLogic Portal are you? Or any other server “built on” WebLogic that isn’t WebLogic?

    #218159 Reply

    Yes Scott, Even i am finding it strange, my war file works fine when i deploy from outside.But when i deploy through myeclipse then it is not able to get me Drivermanager.getConnection(), I tried both in war and exploded form.

    I know it is tricky thing to resolve.Any suggestion will be very helpful.

    Thanks
    Sandeep

    #218248 Reply

    Hi
    Just to describe it more , weblogic is giving exception of “no suitable Driver ” exception in code and “Load error:java.lang.UnsatisfiedLinkError: no agmss_jni in java.library.path” on weblogic console in myeclipse.

    but all is working perfectly fine if i don’t use weblogic from myeclipse.

    thanks
    Sandeep

    #218261 Reply

    Riyad Kalla
    Member

    “Load error:java.lang.UnsatisfiedLinkError: no agmss_jni in java.library.path”

    This suggests to us that WebLogic’s JDBC driver is looking for a specific set of native resources in the library path that it cannot find. You need to figure out what these file(s) are and add them to the library path in the WebLogic connector > Paths > “Append to Library Path” settings. For example if its a DLL for the driver, make sure to add that here.

    You can likely open up the script used to start the app server to figure out what path preparation it does before launching the server and duplicate it in the connector.

Viewing 11 posts - 1 through 11 (of 11 total)
Reply To: Weblogic not working with Myeclipse

You must be logged in to post in the forum log in