Weblogic.jspc and @include

It looks like JSP compiler weblogic.jspc is not taking care of the
          @include directive. For example compiler complains about methods in
          common_jsp.jsp while compiling say other_jsp.jsp . But when the server
          compiles it there is no problem!!.
          Am I missing somthing? Please let me know.
          TIA
          -Harit
          

          I had the same problem until I specified the -docroot parameter...
          Harit Nanavati <[email protected]> wrote:
          >It looks like JSP compiler weblogic.jspc is not taking care of the
          >@include directive. For example compiler complains about methods in
          >common_jsp.jsp while compiling say other_jsp.jsp . But when the server
          >compiles it there is no problem!!.
          >
          >Am I missing somthing? Please let me know.
          >TIA
          >-Harit
          >
          

Similar Messages

  • Invocation of weblogic.jspc within a java process

              We have created a Java program to support our build process to pre-compile all of
              our JSPs. Things work fine as long as we exec a process each time we inovke weblogic.jspc
              (java weblogic.jspc -d...etc). Is it possible to invoke the main method of weblogic.jspc
              and pass it an option that will keep it from exiting when it completes its work?
              The problem we have is that we want to recursively call the main method but it exits
              the external java process each time it is called.
              TIA
              Brian
              

    Oh, Marc and I had a little offline conversation. We decided that the 5.1
              jspc does NOT honor the -noexit option. 6.0 should be fine.
              You might be able to accomplish the same task in a script, simply calling
              jspc multiple times.
              Gary
              "Matt Shelley" <[email protected]> wrote in message
              news:[email protected]...
              >
              > Gary, could you be a bit more specific? I have the exact same problem.
              > It executes the first JSP and exits immediately after invoking
              > the compiler, compiling the JSP OK.
              >
              > Here's a snip:
              > for (int i=0; i < documentJSPTree.size(); i++) {
              > //Execute JSP compile command
              > try {
              > //Set arguments for jspc
              > String [] compilerArgs = {"-noexit","-verbose",
              > "-d",destination,
              > (String)documentJSPTree.get(i)}
              > //Call compiler with args
              > weblogic.jspc.main(compilerArgs);
              > } catch (Exception ex) {
              > ex.printStackTrace();
              > System.out.println("Compiler Error: " + ex.toString());
              > }
              > }
              >
              > Cheers
              >
              > Matt
              >
              >
              > "Gary Keim" <[email protected]> wrote:
              > >A look at how you're calling it might help.
              > >--
              > >Gary
              > >
              > >"marc grzeskowiak" <[email protected]> wrote
              > >in message
              > >news:[email protected]...
              > >> I attempted this, but to no avail. I was able to get
              > >it to work on the
              > >first
              > >> jsp, but java exits before the next jsp is processed.
              > > I do pass in
              > >the -noexit
              > >> option, but this does not appear to be read in weblogic.jspc.
              > >>
              > >> My code is a simple for loop that changes the last element
              > >of the
              > >arguments
              > >> array(args), which represents the file to compile, and
              > >then calls
              > >> weblogic.jspc.main(args);
              > >>
              > >> Any thoughts?
              > >> marc
              > >>
              > >> Gary Keim wrote:
              > >>
              > >> > Pass weblogic.jspc.main the -noexit option. Actually,
              > >any of our tools
              > >> > accept that option.
              > >> > --
              > >> > Gary
              > >> >
              > >> > "Brian Smith" <brian.smith@nospam_mezzia.com> wrote
              > >in message
              > >> > news:[email protected]...
              > >> > >
              > >> > > We have created a Java program to support our build
              > >process to
              > >pre-compile
              > >> > all of
              > >> > > our JSPs. Things work fine as long as we exec a
              > >process each time we
              > >> > inovke weblogic.jspc
              > >> > > (java weblogic.jspc -d...etc). Is it possible to
              > >invoke the main
              > >method
              > >> > of weblogic.jspc
              > >> > > and pass it an option that will keep it from exiting
              > >when it completes
              > >its
              > >> > work?
              > >> > > The problem we have is that we want to recursively
              > >call the main
              > >method
              > >> > but it exits
              > >> > > the external java process each time it is called.
              > >> > >
              > >> > > TIA
              > >> > >
              > >> > > Brian
              > >>
              > >
              > >
              >
              

  • Weblogic.jspc outofmemory error while compiling jsps using ant in eclipse

    Hi all,
    I am trying to execute this target in my ant build:
         <target name="jspc">
              <java classname="weblogic.jspc" fork="yes">
                   <arg line="-verbose -verboseJavac -compileAll -webapp ${project.jsp.dir} -d ${project.jsp.class.dir}" />
                   <classpath>
                        <pathelement path="${classpath}" />
                   </classpath>
         </java>
         </target>
    I am getting the following error:
    [java] Error: [jspc]: 0 file(s) failed:
    [java] [Compilation errors : ]
    [java] The system is out of resources.
    [java] Consult the following stack trace for details.
    [java] java.lang.OutOfMemoryError
    [java] at weblogic.jspc.doCompile(jspc.java:861)
    [java] at weblogic.jspc.runJspc(jspc.java:654)
    [java] at weblogic.jspc.runBodyInternal(jspc.java:412)
    [java] at weblogic.jspc.runBody(jspc.java:319)
    [java] at weblogic.utils.compiler.Tool.run(Tool.java:192)
    I am using weblogic 8.1, eclipse3.1, java1.4.1.
    Can some one please help me with this issue?
    thanks in advance.

    --> some error on posting please refer to the next post...
    From the error logs we can trace it out to the web project's Build.xml file ....I was getting a similar error and by commenting out the following lines in the web project's Build.xml I am able to run the build script correctly and get a EAR file. The lines are
    <!--
    <assemble
    moduleDir="${generated.module.root}"
    moduleName="${project.name}"
    srcOutputDir="${assembly.src}"
    appRootDir="${ear.root}">
    <assemblyContext factory="org.apache.beehive.controls.runtime.assembly.WebAppAssemblyContext$Factory" />
    <assemblyContext factory="org.apache.beehive.controls.runtime.assembly.AppAssemblyContext$Factory" />
    <classpath refid="assembly.classpath" />
    <fileset dir="${project.dir}">
    <include name="**/*.controls.properties" />
    </fileset>
    </assemble>
         -->
    Please check it now, also if any one can let us know the function or role played by the above lines it would be great. Also if there would be any future or unseen problems by commenting out these lines please do let us know...
    Thanks
    -MiM
    Edited by prodigymonish83 at 10/22/2007 5:56 AM

  • Problem when using weblogic.jspc from an IDE

    I am trying to call JSPC from an IDE (as part of an Eclipse Builder). To optimize performance I want to avoid to spwan a new process. So I am trying to call weblogic.jspc's main method directly from the IDE. Everything works fine for simple simple pages.
              But when the page refers to a tag library with a tag providing a TagExtraInfo class, weblogic.jspc complains about the class not extending the TagExtraInfo base class although it does:
              Errors encountered while compiling 'D:\vrp-localdeploy\applications\wot\WOT' :
              Translation of /rentalcar/tiles/i18n/CarCapacityView.jsp failed: (line 17): Error in using tag library uri='/tags/i18n' prefix='i18n': For tag 'bundle', extra info class 'org.apache.taglibs.i18n.BundleTEI' does not extend javax.servlet.jsp.tagext.TagExtraInfo
              I could not figure out what exactly causes the problem. Using exactly the same settings workes just fine.
              Any suggestions?

    The full stack trace reads as follows:
              <p>
              Errors encountered while compiling 'D:\vrp-localdeploy\applications\wot\WOT' :
              <p>
              Translation of /common/include/i18n/definitions.inc failed: (line 17): Error in using tag library uri='/tags/i18n' prefix='i18n': For tag 'bundle', extra info class 'org.apache.taglibs.i18n.BundleTEI' does not extend javax.servlet.jsp.tagext.TagExtraInfo
              <br>
                   at weblogic.jspc.runJspc(jspc.java:559)
                   at weblogic.jspc.runBodyInternal(jspc.java:410)
                   at weblogic.jspc.runBody(jspc.java:319)
                   at weblogic.utils.compiler.Tool.run(Tool.java:146)
                   at weblogic.utils.compiler.Tool.run(Tool.java:103)
                   at weblogic.jspc.main(jspc.java:708)
                   at tui.vrp.tools.presentation.builder.PresentationBuilder.compileJSP(PresentationBuilder.java:1173)
                   at tui.vrp.tools.presentation.builder.PresentationBuilder.checkResource(PresentationBuilder.java:718)
                   at tui.vrp.tools.presentation.builder.PresentationBuilder$PresentationDeltaVisitor.visit(PresentationBuilder.java:102)
                   at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:68)
                   at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:77)
                   at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:77)
                   at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:77)
                   at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:77)
                   at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:77)
                   at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:77)
                   at org.eclipse.core.internal.events.ResourceDelta.accept(ResourceDelta.java:49)
                   at tui.vrp.tools.presentation.builder.PresentationBuilder.incrementalBuild(PresentationBuilder.java:1268)
                   at tui.vrp.tools.presentation.builder.PresentationBuilder.build(PresentationBuilder.java:677)
                   at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:593)
                   at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:1044)
                   at org.eclipse.core.runtime.Platform.run(Platform.java:783)
                   at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:168)
                   at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:202)
                   at org.eclipse.core.internal.events.BuildManager$1.run(BuildManager.java:231)
                   at org.eclipse.core.internal.runtime.InternalPlatform.run(InternalPlatform.java:1044)
                   at org.eclipse.core.runtime.Platform.run(Platform.java:783)
                   at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:234)
                   at org.eclipse.core.internal.events.BuildManager.basicBuildLoop(BuildManager.java:253)
                   at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:282)
                   at org.eclipse.core.internal.events.AutoBuildJob.doBuild(AutoBuildJob.java:139)
                   at org.eclipse.core.internal.events.AutoBuildJob.run(AutoBuildJob.java:200)
                   at org.eclipse.core.internal.jobs.Worker.run(Worker.java:76)
              <p>
              Unfortunately it doesn't really give any real reason - it is a general piece of code in jspc to report problems.
              <p>
              But I dug a lot bit deeper into the code and realized that the original problem is a ClassCastException in line 1290 of class StandardTagLib, which reads as follows:
              <p>
                   tagextrainfo = (TagExtraInfo)Beans.instantiate(classloader, s3);
              <p>
              This looks quite obvious that the class named by s3 simply is no extension of TagExtraInfo, but unfortunately the only class with that name being referenced by the class path does extend this class. I wondered what the problem might be and came up with the following answer:
              <p>
              The class of the bean instantiated by Beans.instantiate extends a class with the name "javax.servlet.jsp.tagext.TagExtraInfo" which is cast to another class with exactly <b>the same name, but a different class loader</b>. Since neither of the class loaders is parent of the other one, both classes are not considered being the same class although they have the same name. Sounds weird, but exactly this is the problem!
              <p>
              Where does it come from and why it works fine when the tool is executed in a separate thread or on the console?
              <p>
              From my understanding the problem is caused in line 395 of the class weblogic.jspc:
              <p>
                   GenericClassLoader genericclassloader = new GenericClassLoader(classpathclassfinder);
              <p>
              This line of code creates a class loader not knowing a parent class loader by which the class weblogic.jspc was loaded. All classes weblogic.jspc is using or calling will be loader by either the same or a parent class loader - this is important to understand. Since TagExtraInfo is directly referenced by StandardTagLib one instance of the class object (the object of type class) will be generated and linked when the class StandardTagLib is instantiated for the first time by the class loader which loaded weblogic.jspc (or by its parent). This is consequence which can not be avoided.
              <p>
              But now look at line 1290 of class StandardTagLib: It explicitly requests the class to be loaded by the GenericClassLoader instantiated in line 395 of the class weblogic.jspc. This class loader, off course, is not aware of the same class just being loaded by another class loader since it has no knowledge of it. It simply creates a fresh copy of the class object, which only differs in the reference to the class loader which created this class object.
              <p>
              Actually, I figured that the following line of code replacing the upper one, would resolve the problem:
              <p>
              GenericClassLoader genericclassloader = new GenericClassLoader(classpathclassfinder, this.getClass().getClassLoader());
              <p>
              Doing this, the GenericClassLoader would know its logical parent by reference and would implicitly - thanks to the implementation of java.lang.ClassLoader - try to find the class using its parent first, would find a valid class, and hence use the same instance of the class object instantiated by the parent class loader. The problem would be solved.
              <p>
              It works fine in the console or under a running application server, because they will always have the weblogic jar in their system class path. ClassLoaders not having a parent are implied to have the system class loader as their parent - the piece of code does work in this case.
              <p>
              Under Eclipse this is no option, off course. We would restrain us to exactly this version of the APIs used by the weblogic version in the system class path.
              <p>
              I was trying to patch this myself by extending weblogic.jspc by my own class to pass on a proper class loader knowing its parent, and I was sort of successful: The problem disappeared. But I can't gain exactly what I am looking for, because the method runJspc with four parameters (around line 447) of weblogic.jspc is private to the class and its public brother always passes true to this method as the fourth parameter - causing jspc to recompile all JSPs instead of just the requested ones.
              <p>
              Everything refers to WL81SP3.
              <p>
              That's were I got stuck currently. I have read some postings about this problem in the internet - some dating far back into the history. So, I have the impression that there have been some folks around with the same problem. I think the patch I suggested does not any harm and I could simply use jspc in my builder without any problems.
              <p>
              Regards,
              <p>
              Elmar Schwarz

  • Capturing weblogic username and password for use in my console extension

    Hi,
    I have developed a console extension as a war file and it needs to capture the Weblogic username and password so internally it can use the class MBeanServerConnection that needs these during connection. I have therefore created the standard <login-config> <auth-method>FORM</auth-method> ... stuff in the web.xml to output a logon.jsp when my war is accessed in the hope of capturing username and password. My intention is that these would appear in addition to the standard logon that appears when the Weblogic console is 1st accessed.
    However, my console extension logon.jsp does not appear and I think it’s because there is only one logon needed and this is when the main Weblogic console is accessed because my console extension is subordinate to the main Weblogic console.
    Therefore, how can I get my console extension logon.jsp to appear so I can capture the Weblogic username and password?
    Thanks,
    Dave.

    One approach that might work is to write a look and feel console extension that modifies the console's login jsp (vs trying to have a second login jsp).
    http://download.oracle.com/docs/cd/E15523_01/web.1111/e13745/rebrand.htm#i1070459 describes how to write look and feel extensions.
    Basically, you instantiate the look and feel extension template, hand-edit login/LoginForm.jsp, then build and deploy the extension.
    One tricky part is figuring out how to pre-compile the jsps. Here's part of a build script I've used for look and feel extensions. Let me know if you need a sample look and feel extension.
    <project name="sample-look-and-feel" default="build">
    <dirname property="this.dir" file="${ant.file.sample-look-and-feel}" />
    <property environment="env" />
    <property name="src.dir" value="${this.dir}/src" />
    <property name="build.dir" value="${this.dir}/build" />
    <property name="webapp.dir" value="${build.dir}/webapp" />
    <property name="jspc.dir" value="${build.dir}/jspc" />
    <property name="samplename" value="sample-look-and-feel" />
    <property name="wlhome.dir" value="${env.WL_HOME}" />
    <property name="consoleapp.dir" value="${wlhome.dir}/server/lib/consoleapp" />
    <property name="deployment" value="${build.dir}/${samplename}.war" />
    <target name="build">
    <!--
    Make a temporary directory that we will compile the jsps from.
    It includes the console's web.xml (which has the jspc configuration),
    the sample's jsps, and any console taglibs the sample's jsps use.
    -->
    <copy todir="${jspc.dir}">
    <fileset dir="${consoleapp.dir}/webapp">
    <include name="**/struts.jar" />
    <include name="**/standard.jar" />
    <include name="**/beehive-netui-tags.jar" />
    <include name="**/skeleton_taglib.jar" />
    <include name="**/render_taglib.jar" />
    <include name="**/l10n_taglib.jar" />
    <include name="**/*.tld" />
    <include name="**/web.xml" />
    </fileset>
    <fileset dir="${webapp.dir}">
    <include name="**/*.jsp" />
    </fileset>
    </copy>
    <!--
    Compile the jsps out of the temporary directory.
    Put the generate files into the extension's wabapp.
    -->
    <java classname="weblogic.servlet.jsp.jspc20" fork="true" failonerror="false">
    <arg line="-noexit" />
    <arg line="-d ${webapp.dir}/WEB-INF/classes" />
    <arg line="-webapp ${jspc.dir}" />
    <!--
    <arg line="-verboseJspc"/>
    <arg line="-debug"/>
    <arg line="-keepgenerated"/>
    -->
    <classpath>
    <pathelement path="${wlhome.dir}/server/lib/wlw-langx.jar" />
    <fileset dir="${consoleapp.dir}/APP-INF/lib">
    <include name="*.jar" />
    </fileset>
    <fileset dir="${consoleapp.dir}/webapp/WEB-INF/lib">
    <include name="*.jar" />
    </fileset>
    <pathelement path="${java.class.path}" />
    </classpath>
    </java>
    <!-- Remove the temporary directory now that we're done with it. -->
    <delete dir="${jspc.dir}" />
    <!-- Package the extension -->
    <jar destfile="${deployment}" basedir="${webapp.dir}" />
    <!-- remove the webapp directory now that the webapp is built -->
    <delete dir="${webapp.dir}" />
    </target>
    </project>

  • Precompiling JSPs using weblogic.jspc

    Hello,
    My question has more to do with getting the Weblogic precompiler to understand <%@ include file="myFilejsp" %> directives.
    Test scenario:
    In our application, we have used a common JSP page say 'commonJSP' as a header and have included 'commonJSP' in all our other JSP pages.
    Suppose my commonJSP is like this:
    <%
    String hello= "Hello";
    %>
    and suppose my index.jsp is like this
    <%@ include file="commonJSP" %>
    <%
    System.out.println(hello);
    %>
    Now when I serve index.jsp to clients it compiles correctly because the commonJSP is included in the source before compiling.
    HOWEVER, when precompiling the JSPs in my web application using the <java weblogic.jspc ..> tag in my ant build file, I am getting errors on compiling index.jsp that 'hello' cannot be resolved.
    When using the WebLogic JSP compiler, is there any way to tell the compiler to not treat JSP pages as individual 'servlet' classes but look at the 'big picture'?

    Anybody ?

  • Weblogic jspc

    Hi,
    Version: Weblogic 8.1 SP3.
    OS: Sun Solaris.
    I have a requirement wherein I need to be able to compile a jsp as part of a batch job. I read the docs at http://e-docs.bea.com/wls/docs81/jsp/reference.html#65756/ and was hoping to use the java weblogic.jspc command.
    However I am always thrown the "Exception in thread "main" java.lang.NoClassDefFoundError: weblogic/jspc".
    I am not certain what I am doing wrong. Would appreciate any help. Do I have to modify the CLASSPATH settings in startweblogic.sh for this?
    One other question. (this I can answer by trial and error if I get the answer to above..)
    Do I have to include the CLASSPATH which I have already specified in startweblogic.sh when I use the java weblogic.jspc command?
    Thanks a ton.
    Shikhar

    It's me again... Now I am running into a different issues... have posted the command executed and the output.. Any help is appreciated...
    Thanks
    Shikhar
    C:\bea\user_projects\domains\demodomain>java -Dweblogic.jsp.windows.caseSensitiv
    e=true -classpath C:\bea\weblogic81\server\lib\weblogic.jar; weblogic.jspc -verb
    oseJspc C:\bea\user_projects\domains\demodomain\demo\stage\Vignette_Portal\porta
    l.war\global1\jsp\alertsEmail.jsp
    [jspc] warning: expected file /WEB-INF/web.xml not found, tag libraries cannot
    be resolved.
    <Oct 20, 2005 12:10:56 PM CDT> <Warning> <HTTP> <BEA-101181> <Could not find web
    .xml under WEB-INF in the doc root: ..>
    [jspc] parsing /demo/stage/Vignette_Portal/portal.war/global1/jsp/alertsEmail.js
    p:
    [jspc] parsed .\demo\stage\Vignette_Portal\portal.war\global1\jsp\alertsEmail.js
    p in 1002 ms.
    [jspc] generated java file C:\bea\user_projects\domains\demodomain\__alertsEmail
    .java
    [jspc] Invoking the compiler with -encoding UTF-8
    Compiler class: 'com.sun.tools.javac.Main', not found
    java.lang.ClassNotFoundException: com.sun.tools.javac.Main
    at java.net.URLClassLoader$1.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClass(Unknown Source)
    at java.lang.ClassLoader.loadClassInternal(Unknown Source)
    at java.lang.Class.forName0(Native Method)
    at java.lang.Class.forName(Unknown Source)
    at weblogic.utils.compiler.CompilerInvoker.compileMaybeExit(CompilerInvo
    ker.java:406)
    at weblogic.utils.compiler.CompilerInvoker.compile(CompilerInvoker.java:
    328)
    at weblogic.utils.compiler.CompilerInvoker.compile(CompilerInvoker.java:
    336)
    at weblogic.jspc.doCompile(jspc.java:823)
    at weblogic.jspc.runJspc(jspc.java:632)
    at weblogic.jspc.runBodyInternal(jspc.java:410)
    at weblogic.jspc.runBody(jspc.java:319)
    at weblogic.utils.compiler.Tool.run(Tool.java:146)
    at weblogic.utils.compiler.Tool.run(Tool.java:103)
    at weblogic.jspc.main(jspc.java:708)
    Error: [jspc]: 0 file(s) failed:
    Exception in thread "main"
    [Compilation errors : ]
    at weblogic.jspc.doCompile(jspc.java:839)
    at weblogic.jspc.runJspc(jspc.java:632)
    at weblogic.jspc.runBodyInternal(jspc.java:410)
    at weblogic.jspc.runBody(jspc.java:319)
    at weblogic.utils.compiler.Tool.run(Tool.java:146)
    at weblogic.utils.compiler.Tool.run(Tool.java:103)
    at weblogic.jspc.main(jspc.java:708)
    java.lang.Exception: [Compilation errors : ]
    at weblogic.jspc.doCompile(jspc.java:842)
    at weblogic.jspc.runJspc(jspc.java:632)
    at weblogic.jspc.runBodyInternal(jspc.java:410)
    at weblogic.jspc.runBody(jspc.java:319)
    at weblogic.utils.compiler.Tool.run(Tool.java:146)
    at weblogic.utils.compiler.Tool.run(Tool.java:103)
    at weblogic.jspc.main(jspc.java:708)
    C:\bea\user_projects\domains\demodomain>

  • Using weblogic.jspc

    We are trying to use weblogic.jspc for precompiling the jsps in our application. Following the ANT task for doing the same.
              <target name="runJspc" depends="runAssembler">
                   <path id="jspc.path.id">
                        <path refid="class.path"/>
                        <fileset dir="${weblogic.gws.app}/APP-INF">
                             <include name="**/*.jar"/>
                        </fileset>
                   </path>     
              <java classname="weblogic.jspc" fork="yes" failonerror="yes">
                        <classpath refid="jspc.path.id"/>
                        <arg line="-webapp ${weblogic.gws.app}/web -compiler ${javac.exec} -classpath ${gws.cl} -compileAll -d ${weblogic.gws.app}/web/WEB-INF/classes -depend -k -keepgenerated -verbose -verboseJavac"/>
                   </java>
              </target>
              For some reason, this target runs forever, without printing any logs or anthing. It simply hangs at "runJspc :".
              To dig into details, I modified the target as follows :
              <target name="runJspc" depends="prepare">
              <path id="jspc.path.id">
              <path refid="class.path"/>
              <fileset dir="${weblogic.gws.app}/APP-INF">
              <include name="**/*.jar"/>
              </fileset>
              <pathelement path="${weblogic.gws.app}/web/WEB-INF"/>
              </path>
              <java classname="weblogic.jspc" fork="yes" failonerror="yes">
              <classpath refid="jspc.path.id"/>
              <arg line="-d ${weblogic.gws.app}/web/WEB-INF/classes -classpath ${gws.cl} -compiler ${javac.exec}" />
              <arg value="-k" />
              <arg value="-compileAll" />
              <arg value="-depend" />
              <arg value="-verboseJavac" />
              <arg value="${weblogic.gws.app}/web/retail/jsp_app/home/ft_home.jsp"/>
              <jvmarg line="-Xms512m"/>
              <jvmarg line="-Xmx512m"/>
              </java>
              </target>
              Now it throws below error & stops.
              runJspc:
              [java] [jspc] warning: expected file /WEB-INF/web.xml not found, tag libraries cannot be resolved.
              [java] <Apr 14, 2005 11:49:19 AM PDT> <Warning> <HTTP> <BEA-101181> <Could not find web.xml under WEB-INF in the doc root: ..>
              Is there any way to resolve one of the above two problems ?

    Hi Arun,
              It seems that in the second ant target, you decide to compile just a single jsp, while in the first you were trying to compile the complete jsps in a application.
              But in the second target, you forgot to mention -docroot / -webapp target. As a result, the specific error!!.
              To actually debug the first target, try running the program first on commandline , using weblogic.jspc directly passing the arguments.
              This way , you would have a better control over the target, and may be able to isolate the issue easily.

  • Java.io.IOException using weblogic.jspc

    I've seen a number of similar questions on this but no answers. Can
              anyone provide some insight?
              I have a JSP containing a custom tag library that compiles and executes
              successfully when deployed as a war file under wls 5.1 sp8 but running
              the weblogic.jspc compiler from the command line produces a
              java.io.IOException: cannot resolve '/WEB-INF/tlds/struts-template.tld'
              into a valid tag library.
              The web.xml file includes:
              <taglib>
              <taglib-uri>/WEB-INF/tlds/struts-template.tld</taglib-uri>
              <taglib-location>/WEB-INF/tlds/struts-template.tld</taglib-location>
              </taglib>
              The command I'm using is:
              java -Dweblogic.home=/opt/weblogic
              weblogic.jspc
              -d /home/wmeier/java/StrutsTemplate/build/jsp
              -docroot /home/wmeier/java/StrutsTemplate/web
              -contextPath StrutsTemplate
              -encoding default
              -keepgenerated
              -g
              introduction.jsp
              I can get the jsp compiler to work when I change the taglib uri
              declaration from
              <%@ taglib uri='/WEB-INF/tlds/struts-template.tld'...
              to
              <%@ taglib uri='/tlds/struts-template.tld'
              This modified uri also works as a war file under WebLogic but fails
              under the Tomcat 3.2 reference implementation.
              Does anyone have any ideas how I can get the compiler to work without
              hacking the taglib uri?
              Thanks,
              Bill Meier
              

    CeciNEstPasUnProgrammeur wrote:
    Hm, well... the API docs say for non-existing files you get an IllegalArgumentException, and IOException is for "no application registered" or "application won't start"...
    Just a guess: is the firewall blocking the execution?I don't think it is a fire wall issue since everything runs on the same machine (the file is created and invoked on the same machine)
    Any other ideas?

  • Wls 8.1 sp2: weblogic.jspc complains about struts-html tags

              Hi,
              I am trying to compile jsps with weblogic.jspc, which use struts' html tags. However,
              the compilation fails with the following message:
              [java] Translation of /views/viewPageBody.jsp failed: (line 3): Error in using
              tag library uri='/tags/struts-html' prefix='html': The Tag class 'org.apache.struts.taglib.html.BaseTag'
              has no setter method corresponding to TLD declared attribute 'server', (JSP 1.1
              spec, 5.4.1)
              I opened the BaseTag class from the struts jar and found the setter exists for
              the attribute 'server' of html tld. So does the property 'server'. The property
              'server' is a string and the parameter in the setter is a string. I read about
              the jspc errors in wls 8.1 about the setter parameter being of different type
              than the property. However, that is not the case here. I tried using both Sun's
              and BEA's jdk. None of them help. Btw, there is another attribute mentioned in
              the html tld, which is 'target'. The compiler doesn't complain yet about this.:(
              Also, I happened to compile other apps which have struts logic tags.
              My environment:
              OS: Win2k sp3
              WLS: 8.1 sp2
              JDK: Sun's 1.4.2 sp4 / Bea's 1.4.1 sp5 (tried both)
              Ant: 1.5.3 (I had an issue earlier with ant until I found that Bea officially
              without any mention supports only ant 1.5.3.)
              I would appreciate any help in this regard.
              Thanks,
              Abbas
              

              What version of Struts are you trying to use?
              Are you certain you're not encountering a different instance of that class in
              an unexpected location in your classpath?
              "Abbas" <[email protected]> wrote:
              >
              >Hi,
              >I am trying to compile jsps with weblogic.jspc, which use struts' html
              >tags. However,
              >the compilation fails with the following message:
              >
              >[java] Translation of /views/viewPageBody.jsp failed: (line 3): Error
              >in using
              >tag library uri='/tags/struts-html' prefix='html': The Tag class 'org.apache.struts.taglib.html.BaseTag'
              >has no setter method corresponding to TLD declared attribute 'server',
              >(JSP 1.1
              >spec, 5.4.1)
              >
              >I opened the BaseTag class from the struts jar and found the setter exists
              >for
              >the attribute 'server' of html tld. So does the property 'server'. The
              >property
              >'server' is a string and the parameter in the setter is a string. I read
              >about
              >the jspc errors in wls 8.1 about the setter parameter being of different
              >type
              >than the property. However, that is not the case here. I tried using
              >both Sun's
              >and BEA's jdk. None of them help. Btw, there is another attribute mentioned
              >in
              >the html tld, which is 'target'. The compiler doesn't complain yet about
              >this.:(
              >Also, I happened to compile other apps which have struts logic tags.
              >
              >
              >My environment:
              >OS: Win2k sp3
              >WLS: 8.1 sp2
              >JDK: Sun's 1.4.2 sp4 / Bea's 1.4.1 sp5 (tried both)
              >Ant: 1.5.3 (I had an issue earlier with ant until I found that Bea officially
              >without any mention supports only ant 1.5.3.)
              >
              >I would appreciate any help in this regard.
              >
              >Thanks,
              >
              >Abbas
              

  • Weblogic.appc compiler for Weblogic 9 and higher version

    We had problem precompiling the jsp's using weblogic.jspc compiler after migrating the project from 8.1 to 9.2. From the edocs weblogic documentation we see that jspc compiler is deprecated from weblogic 9 onwards and they recommend using weblogic.appc for precompiling the jsp's.
    Please note if you are passing runtime expression values in the name attribute of the jsp param tag, you will have to explicitly enabke "<rtexprvalue-jsp-param-name>" to true in weblogic.xml deployment descriptor (format shown below).
    <weblogic-web-app>
    <jsp-descriptor>
    <rtexprvalue-jsp-param-name>true</rtexprvalue-jsp-param-name>
    </jsp-descriptor>
    </weblogic-web-app>
    Below is the edocs link which has JSP descriptors information for Weblogic 9,2
    http://e-docs.bea.com/wls/docs92/webapp/weblogic_xml.html#wp1038491
    - - Tarun

    The solution given in the below link worked for me .
    http://a-developer-life.blogspot.com/2010/11/injecting-into-ejb3-with-google-guice.html?showComment=1328674836129#c7251888680841418914

  • Appending a _ in front of the jsp class name when using weblogic.jspc

     

    http://e-docs.bea.com/wls/docs60/jsp/reference.html
              java weblogic.jspc -d /weblogic/classes -keepgenerated primero.jsp
              "rb" <[email protected]> wrote in message
              news:[email protected]...
              >
              > hi,
              >
              > i do
              >
              > java weblogic.jspc -d /weblogic/classes primero.jsp
              >
              > and it only is generated a _primero.class and do not appear
              > the .java ?
              >
              > what i do bad ?
              >
              > thanks for advance
              >
              >
              > Rodrigo Fonseca da Fonseca <[email protected]> wrote:
              > >Hi,
              > >
              > >I'm using weblogic.jspc to compile some jsp fiels. The compilation is
              > >complete and successfully, but the names of generated files .java and
              > >..class are strange.
              >
              >
              >
              > >
              > >For example, compiling a file named change_login_data.jsp, the resulting
              > >files are change95_login_95_data.java and
              > >change95_login_95_data.class. Compiling a file named buy.jsp, the
              > >resulting files are buy.java and buy.class (fine situation). Why???
              > >
              > >I'm using:
              > >
              > >java weblogic.jspc -d c:\jsp_result -classpath
              > >
              >
              >c:\weblogic\myserver\serverclasses;c:\weblogic\lib\weblogicaux.jar;c:\weblo
              gic\classes
              > >-compiler jikes.exe -J-verbose -keepgenerated -verbose
              > >change_login_data.jsp
              > >
              > >
              > >thanks
              > >Rodrigo
              > >
              > >
              > >
              > >Mark Spotswood wrote:
              > >>
              > >> The namespace for java class files is more restrictive
              > >> than for JSP files. We prepend these underscores so
              > >> that if, for example, someone names their JSP "1.jsp",
              > >> we get a class file with a legal name. We did consider
              > >> not doing this for files which started with characters
              > >> we kenw to be valid (in fact we may have put it in a
              > >> service pack), but later found that this was not sufficient
              > >> because its possible to name a jsp file something that
              > >> clashes with java keywords ("class.jsp" for example).
              > >> Rather than making the scheme even more complex,
              > >> we decided to go back to the original sheme of always
              > >> prepending the underscore.
              > >> --
              > >> mark
              > >>
              > >> Mika Moilanen wrote:
              > >>
              > >> > >>>>> "Shankar" == Shankar Roy <[email protected]> writes:
              > >> >
              > >> > Shankar> Problem seems to go away with weblogic510sp4.jar in
              compilation
              > >classpath.
              > >> > Shankar> Shankar.
              > >> >
              > >> > Shankar> Shankar Roy wrote:
              > >> >
              > >> > >> Hi,
              > >> > >> Can anyone tell why when I invoke weblogic.jspc the class file
              that
              > >is
              > >> > >> generated has a _ in front of the class name
              > >> > >>
              > >> > >> java -classpath
              > >> > >>
              >
              >/space/shankar/weblogic/lib/weblogicaux.jar:/space/shankar/weblogic/classes
              /boot:/space/shankar/weblogic/classes:/space/shankar/dev/dev/lib/activation.
              jar:/space/shankar/dev/dev/lib/classes12.zip:/space/shankar/dev/dev/lib/mail
              .jar:/space/shankar/dev/dev/lib/oroinc.jar:/usr/java/lib/classes.zip
              > >> > >> weblogic.jspc -package com.careassured.jsp -commentary login.jsp
              > >> > >>
              > >> > >> produces a class file by the name _login.class
              > >> > >>
              > >> > >> Thanks for any help pointers.
              > >> > >> Shankar.
              > >> >
              > >> > Not with WLS5.1 and weblogic510sp6.jar, we still get '_' prefixed
              > >> > classes...
              > >> >
              > >> > Actually we're suffering quite a lot because of this bug in
              > >> > weblogic.jspc. Are there any plans for fix?
              > >> >
              > >> > --
              > >> > Best Regards,
              > >> > Mika
              > >> > ----------------------------------------------------------
              > >> > [email protected] phone: +358-0-511-23587
              > >> > Nokia Networks, PO box 320, FIN-00045 NOKIA GROUP, Finland
              > >> > ----------------------------------------------------------
              >
              

  • WebLogic Portal and Workshop 9.2 Beta now available!

    Hello All -
    We're excited to announce the public availability of the WebLogic Workshop and WebLogic Portal 9.2 open Beta release on bea.com.
    A beta version of the electronic documentation has also been posted to e-docs.
    Portal 9.2 adds significant new capabilities which are part of the beta to target our core market and expand in new directions by providing:
    * A WorkShop development environment based on Eclipse
    * Content Management enhancements including a WYSIWYG editor
    * Improved Federation and Production Ops capabilities
    * The GroupSpace collaborative application and framework
    Following are the links and information to get you started with Beta 9.2:
    * Download: http://commerce.bea.com/showproduct.jsp?family=WLPORTAL&major=9.2&minor=-1
    * Beta Home page: http://wlp.bea.com/wlw_wlp_beta92
    * Documentation:
    - WebLogic Portal: http://edocs.bea.com/wlp/docs92
    - WebLogic Workshop: http://edocs.bea.com/workshop/docs92
    - WebLogic Platform: http://edocs.bea.com/common/docs92
    * Newsgroups: As a public beta, BEA will not offer support through the BEA Support group. Please use the following newsgroups to log and discuss issues:
    - WebLogic Workshop newsgroup: http://forums.bea.com/bea/forum.jspa?forumID=600000011
    - WebLogic Portal newsgroup: http://forums.bea.com/bea/forum.jspa?forumID=600000012
    - WebLogic Platform newsgroup (if you are unsure whether the issue belongs to WebLogic Portal or WebLogic Workshop): http://forums.bea.com/bea/forum.jspa?forumID=600000013
    Best regards,
    The Beta 9.2 Team

    The Beta 9.2 Team,
    9.2 features sounds good and interesting. We are using BEA's Content management system(8.1) extensively.
    Our requirement is to create a portlet for Content Owner/Users to create HTML documents with images and upload it into BEA Repository. Upon uploading, Content Admin needs to be notified through email and they will either approve or reject the document. The content status again needs to be notified to the content owner/user via email.
    1. As known to everyone 8.1 doesn't have WYSIWYG editor and is included in 9.2. Can i reuse the 9.2 WYSIWYG functionality into 8.1 as a portlet??
    2. The following thread(http://forums.bea.com/bea/message.jspa?messageID=400001479&tstart=0) says
    - workflow ==> We have limited workflow support. We plan to enhance this in our next major release.
    Does this limited workflow support include email notification?
    Any inputs would be greatly appreciated!!
    Thanks,
    -Nach.

  • WebLogic Portal and Workshop 9.2 Beta is Live!

    Hello All -
    We're excited to announce the public availability of the WebLogic Workshop and WebLogic Portal 9.2 open Beta release on bea.com.
    A beta version of the electronic documentation has also been posted to e-docs.
    Portal 9.2 adds significant new capabilities which are part of the beta to target our core market and expand in new directions by providing:
    * A WorkShop development environment based on Eclipse
    * Content Management enhancements including a WYSIWYG editor
    * Improved Federation and Production Ops capabilities
    * The GroupSpace collaborative application and framework
    Following are the links and information to get you started with Beta 9.2:
    * Download: http://commerce.bea.com/showproduct.jsp?family=WLPORTAL&major=9.2&minor=-1
    * Beta Home page: http://wlp.bea.com/wlw_wlp_beta92
    * Documentation:
    - WebLogic Portal: http://edocs.bea.com/wlp/docs92
    - WebLogic Workshop: http://edocs.bea.com/workshop/docs92
    - WebLogic Platform: http://edocs.bea.com/common/docs92
    * Newsgroups: As a public beta, BEA will not offer support through the BEA Support group. Please use the following newsgroups to log and discuss issues:
    - WebLogic Workshop newsgroup: http://forums.bea.com/bea/forum.jspa?forumID=600000011
    - WebLogic Portal newsgroup: http://forums.bea.com/bea/forum.jspa?forumID=600000012
    - WebLogic Platform newsgroup (if you are unsure whether the issue belongs to WebLogic Portal or WebLogic Workshop): http://forums.bea.com/bea/forum.jspa?forumID=600000013
    Best regards,
    The Beta 9.2 Team

    The Beta 9.2 Team,
    9.2 features sounds good and interesting. We are using BEA's Content management system(8.1) extensively.
    Our requirement is to create a portlet for Content Owner/Users to create HTML documents with images and upload it into BEA Repository. Upon uploading, Content Admin needs to be notified through email and they will either approve or reject the document. The content status again needs to be notified to the content owner/user via email.
    1. As known to everyone 8.1 doesn't have WYSIWYG editor and is included in 9.2. Can i reuse the 9.2 WYSIWYG functionality into 8.1 as a portlet??
    2. The following thread(http://forums.bea.com/bea/message.jspa?messageID=400001479&tstart=0) says
    - workflow ==> We have limited workflow support. We plan to enhance this in our next major release.
    Does this limited workflow support include email notification?
    Any inputs would be greatly appreciated!!
    Thanks,
    -Nach.

  • WebLogic Portal and Workshop 9.2 Beta is now available!

    Hello All -
    We're excited to announce the public availability of the WebLogic Workshop and WebLogic Portal 9.2 open Beta release on bea.com.
    A beta version of the electronic documentation has also been posted to e-docs.
    Portal 9.2 adds significant new capabilities which are part of the beta to target our core market and expand in new directions by providing:
    * A WorkShop development environment based on Eclipse
    * Content Management enhancements including a WYSIWYG editor
    * Improved Federation and Production Ops capabilities
    * The GroupSpace collaborative application and framework
    Following are the links and information to get you started with Beta 9.2:
    * Download: http://commerce.bea.com/showproduct.jsp?family=WLPORTAL&major=9.2&minor=-1
    * Beta Home page: http://wlp.bea.com/wlw_wlp_beta92
    * Documentation:
    - WebLogic Portal: http://edocs.bea.com/wlp/docs92
    - WebLogic Workshop: http://edocs.bea.com/workshop/docs92
    - WebLogic Platform: http://edocs.bea.com/common/docs92
    * Newsgroups: As a public beta, BEA will not offer support through the BEA Support group. Please use the following newsgroups to log and discuss issues:
    - WebLogic Workshop newsgroup: http://forums.bea.com/bea/forum.jspa?forumID=600000011
    - WebLogic Portal newsgroup: http://forums.bea.com/bea/forum.jspa?forumID=600000012
    - WebLogic Platform newsgroup (if you are unsure whether the issue belongs to WebLogic Portal or WebLogic Workshop): http://forums.bea.com/bea/forum.jspa?forumID=600000013
    Best regards,
    The Beta 9.2 Team

    The Beta 9.2 Team,
    9.2 features sounds good and interesting. We are using BEA's Content management system(8.1) extensively.
    Our requirement is to create a portlet for Content Owner/Users to create HTML documents with images and upload it into BEA Repository. Upon uploading, Content Admin needs to be notified through email and they will either approve or reject the document. The content status again needs to be notified to the content owner/user via email.
    1. As known to everyone 8.1 doesn't have WYSIWYG editor and is included in 9.2. Can i reuse the 9.2 WYSIWYG functionality into 8.1 as a portlet??
    2. The following thread(http://forums.bea.com/bea/message.jspa?messageID=400001479&tstart=0) says
    - workflow ==> We have limited workflow support. We plan to enhance this in our next major release.
    Does this limited workflow support include email notification?
    Any inputs would be greatly appreciated!!
    Thanks,
    -Nach.

Maybe you are looking for

  • JCO Server Instances

    We have developed JCO Server program ,so that the ABAP calls the JCO Server program,so that we can set values in the Export Parameters of the RFM.This I wrote using the Example5 code,but I need to understand ,that if we define two or three instances

  • "Privacy" in settings on iPad 1?

    I'm trying to change the privacy settings so I can directly save images from google chrome to my photo library, but whenever I try I'm told I need to change my privacy settings. Upon going to settings, there's no "Privacy" icon available. I've looked

  • Smart Object + Illustrator

    I have an eps file as a layer in my PS document placed as an SO. When I chose to edit contents and made my changes in Illustrator the SO updated correctly but now it seems to be lower res than what was there originally (I'd say 72ppi) . Is this what

  • Troubles with skype 2.0

    Hi! I`m running Archlinux x86_64. I downloaded skype, install lib32 and when I run skype it gets me such error: skype: error while loading shared libraries: libXv.so.1: wrong ELF class: ELFCLASS64 Google says says that this becouse Xv lib is 64 arch.

  • Strange GDM behavior after recent update

    Hi folks, 3 days ago I ran pacman -Syu, and since then GDM behaves different. Before, it had the blue background and started instantly, now it takes several seconds after the switch from tty and then first displays the blue background, then turns dar