This discussion is archived
0 Replies Latest reply: Dec 27, 2012 6:27 PM by 689442 RSS

org.apache.tools.ant.launch.AntMain

689442 Newbie
Currently Being Moderated
After deploying a web application to weblogic 12c, I get following errors:

Error is: "java.lang.ClassNotFoundException: org.apache.tools.ant.launch.AntMai
n"
java.lang.ClassNotFoundException: org.apache.tools.ant.launch.AntMain
at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(Generic
ClassLoader.java:297)
at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClass
Loader.java:270)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClass
Loader.java:179)
Truncated. see log file for complete stacktrace
Caused By: java.lang.ClassNotFoundException: org.apache.tools.ant.launch.AntMain

at weblogic.utils.classloaders.GenericClassLoader.findLocalClass(Generic
ClassLoader.java:297)
at weblogic.utils.classloaders.GenericClassLoader.findClass(GenericClass
Loader.java:270)
at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
at java.lang.ClassLoader.loadClass(ClassLoader.java:247)
at weblogic.utils.classloaders.GenericClassLoader.loadClass(GenericClass
Loader.java:179)
Truncated. see log file for complete stacktrace
>

My weblogic-application.xml is as follows:

<?xml version="1.0" encoding="UTF-8"?>

<weblogic-application xmlns="http://www.bea.com/ns/weblogic/90">
     <application-param>
          <param-name>webapp.encoding.default</param-name>
          <param-value>UTF-8</param-value>
     </application-param>
     <prefer-application-packages>
          <package-name>javax.jws.*</package-name>
                    <package-name>antlr.*</package-name>
          <package-name>org.apache.*</package-name>
          <package-name>org.joda.time.*</package-name>
          <package-name>org.hibernate.*</package-name>
          <package-name>org.hibernate.ejb.*</package-name>
          
     
<package-name>freemarker.cache.*</package-name>
<package-name>freemarker.core.*</package-name>
<package-name>freemarker.debug.*</package-name>
<package-name>freemarker.debug.impl.*</package-name>
<package-name>freemarker.ext.ant.*</package-name>
<package-name>freemarker.ext.beans.*</package-name>
<package-name>freemarker.ext.dom.*</package-name>
<package-name>freemarker.ext.jdom.*</package-name>
<package-name>freemarker.ext.jsp.*</package-name>
<package-name>freemarker.ext.jython.*</package-name>
<package-name>freemarker.ext.rhino.*</package-name>
<package-name>freemarker.ext.servlet.*</package-name>
<package-name>freemarker.ext.util.*</package-name>
<package-name>freemarker.ext.xml.*</package-name>
<package-name>freemarker.log.*</package-name>
<package-name>freemarker.template.*</package-name>
<package-name>freemarker.template.utility.*</package-name>

<package-name>org.hibernate.*</package-name>
<package-name>org.hibernate.action.*</package-name>
<package-name>org.hibernate.bytecode.*</package-name>
<package-name>org.hibernate.cache.*</package-name>
<package-name>org.hibernate.cfg.*</package-name>
<package-name>org.hibernate.classic.*</package-name>
<package-name>org.hibernate.collection.*</package-name>
<package-name>org.hibernate.connection.*</package-name>
<package-name>org.hibernate.context.*</package-name>
<package-name>org.hibernate.criterion.*</package-name>
<package-name>org.hibernate.dialect.*</package-name>
<package-name>org.hibernate.engine.*</package-name>
<package-name>org.hibernate.event.*</package-name>
<package-name>org.hibernate.exception.*</package-name>
<package-name>org.hibernate.hql.*</package-name>
<package-name>org.hibernate.id.*</package-name>
<package-name>org.hibernate.impl.*</package-name>
<package-name>org.hibernate.intercept.*</package-name>
<package-name>org.hibernate.jdbc.*</package-name>
<package-name>org.hibernate.loader.*</package-name>
<package-name>org.hibernate.lob.*</package-name>
<package-name>org.hibernate.mapping.*</package-name>
<package-name>org.hibernate.metadata.*</package-name>
<package-name>org.hibernate.param.*</package-name>
<package-name>org.hibernate.persister.*</package-name>
<package-name>org.hibernate.pretty.*</package-name>
<package-name>org.hibernate.property.*</package-name>
<package-name>org.hibernate.proxy.*</package-name>
<package-name>org.hibernate.secure.*</package-name>
<package-name>org.hibernate.sql.*</package-name>
<package-name>org.hibernate.stat.*</package-name>
<package-name>org.hibernate.tool.*</package-name>
<package-name>org.hibernate.transaction.*</package-name>
<package-name>org.hibernate.transform.*</package-name>
<package-name>org.hibernate.tuple.*</package-name>
<package-name>org.hibernate.type.*</package-name>
<package-name>org.hibernate.usertype.*</package-name>
<package-name>org.hibernate.util.*</package-name>
     </prefer-application-packages>
</weblogic-application>



<!--<weblogic-application xmlns="http://xmlns.oracle.com/weblogic/weblogic-application"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.oracle.com/weblogic/weblogic-application http://xmlns.oracle.com/weblogic/weblogic-application/1.4/weblogic-application.xsd">
     <application-param>
          <param-name>webapp.encoding.default</param-name>
          <param-value>UTF-8</param-value>
     </application-param>
     <prefer-application-packages>
          <package-name>javax.jws.*</package-name>
          <package-name>antlr.*</package-name>
          <package-name>org.apache.*</package-name>
          <package-name>org.joda.time.*</package-name>
          <package-name>org.hibernate.*</package-name>
          <package-name>org.hibernate.ejb.*</package-name>
          
     
<package-name>freemarker.cache.*</package-name>
<package-name>freemarker.core.*</package-name>
<package-name>freemarker.debug.*</package-name>
<package-name>freemarker.debug.impl.*</package-name>
<package-name>freemarker.ext.ant.*</package-name>
<package-name>freemarker.ext.beans.*</package-name>
<package-name>freemarker.ext.dom.*</package-name>
<package-name>freemarker.ext.jdom.*</package-name>
<package-name>freemarker.ext.jsp.*</package-name>
<package-name>freemarker.ext.jython.*</package-name>
<package-name>freemarker.ext.rhino.*</package-name>
<package-name>freemarker.ext.servlet.*</package-name>
<package-name>freemarker.ext.util.*</package-name>
<package-name>freemarker.ext.xml.*</package-name>
<package-name>freemarker.log.*</package-name>
<package-name>freemarker.template.*</package-name>
<package-name>freemarker.template.utility.*</package-name>

<package-name>org.hibernate.*</package-name>
<package-name>org.hibernate.action.*</package-name>
<package-name>org.hibernate.bytecode.*</package-name>
<package-name>org.hibernate.cache.*</package-name>
<package-name>org.hibernate.cfg.*</package-name>
<package-name>org.hibernate.classic.*</package-name>
<package-name>org.hibernate.collection.*</package-name>
<package-name>org.hibernate.connection.*</package-name>
<package-name>org.hibernate.context.*</package-name>
<package-name>org.hibernate.criterion.*</package-name>
<package-name>org.hibernate.dialect.*</package-name>
<package-name>org.hibernate.engine.*</package-name>
<package-name>org.hibernate.event.*</package-name>
<package-name>org.hibernate.exception.*</package-name>
<package-name>org.hibernate.hql.*</package-name>
<package-name>org.hibernate.id.*</package-name>
<package-name>org.hibernate.impl.*</package-name>
<package-name>org.hibernate.intercept.*</package-name>
<package-name>org.hibernate.jdbc.*</package-name>
<package-name>org.hibernate.loader.*</package-name>
<package-name>org.hibernate.lob.*</package-name>
<package-name>org.hibernate.mapping.*</package-name>
<package-name>org.hibernate.metadata.*</package-name>
<package-name>org.hibernate.param.*</package-name>
<package-name>org.hibernate.persister.*</package-name>
<package-name>org.hibernate.pretty.*</package-name>
<package-name>org.hibernate.property.*</package-name>
<package-name>org.hibernate.proxy.*</package-name>
<package-name>org.hibernate.secure.*</package-name>
<package-name>org.hibernate.sql.*</package-name>
<package-name>org.hibernate.stat.*</package-name>
<package-name>org.hibernate.tool.*</package-name>
<package-name>org.hibernate.transaction.*</package-name>
<package-name>org.hibernate.transform.*</package-name>
<package-name>org.hibernate.tuple.*</package-name>
<package-name>org.hibernate.type.*</package-name>
<package-name>org.hibernate.usertype.*</package-name>
<package-name>org.hibernate.util.*</package-name>

          
     </prefer-application-packages>
</weblogic-application>-->

How to solve this problem?

Thanks

Legend

  • Correct Answers - 10 points
  • Helpful Answers - 5 points