Xsl:include and WAR Files

          We are trying to deploy our application using WAR file approach. We are using
          Weblogic 6.0 SP2 All our JSP and servlets are working fine.
          We have our reports generated based on XSL files. XSL files are put into the war
          file.
          In my transformation servlet, I am loading the original xsl file by calling getResourceAsStream(xslFileName);
          During the xsl transformation if we have any includes for another xsl file, I
          am getting an exception
          java.net.MalformedURLException: no protocol: myIncluded.xsl
          Basically in my original XSL file I have the following line
          <xsl:include href="myIncluded.xsl" />
          Could somebody tell me what I should doing to get rid off this exception.
          Thanks in advance
          SK
          

The href attribute needs a protocal to determin what kind of uri it is dealing with file,http, etc..
try changing this
<xsl:include href="myIncluded.xsl" />to this
<xsl:include href="file://./myIncluded.xsl" />
or this
<xsl:include href="file://myIncluded.xsl" />
I'm not sure how this plays out seeing how your using the getResourceAsStream method. I dont know if getting a resource this way will allow the xsl processor to resolve the url correctly or not. You may have to use a jar protocal or something like that to get it to work. You may even need to specify the absolute url to the include file.

Similar Messages

  • How to deploy ear file with jar file and war file with different names

    Hi,
    As part of weblogic migration from WL 6.1 sp3 to WL 10, Iam facing some problem.
    Problem:
    I have one ear file(abc.ear) to deploy which contains one jar file(xyz.jar) and one war file(pqr.war).
    In config.xml file of WL 6.1, it was mentioned as :
    <Application Deployed="true" Name="abc" Path="./config/mydomain/applications/abc.ear">
    <EJBComponent Name="xyz" Targets="myserver" URI="xyz.jar"/>
    <WebAppComponent Name="pqr" Targets="myserver" URI="pqr.war"/>
    </Application>.
    The above is working fine.
    But in config.xml file WL10,I cannot mention the same.
    I need to have different application anmes for ear,jar and war.If I deploy as a ear file,the jar and war files are deployed with the same ear file name.
    I tried the following options:
    1) Deploying as a ear file by adding <sub-deployments>
    2) Deploying both war and jar seperately which is not recommended in my application.
    Please provide the content I should place in the config.xml so that everything works fine correctly.
    Any help is appreciated.

    Hi,
    As part of weblogic migration from WL 6.1 sp3 to WL 10, Iam facing some problem.
    Problem:
    I have one ear file(abc.ear) to deploy which contains one jar file(xyz.jar) and one war file(pqr.war).
    In config.xml file of WL 6.1, it was mentioned as :
    <Application Deployed="true" Name="abc" Path="./config/mydomain/applications/abc.ear">
    <EJBComponent Name="xyz" Targets="myserver" URI="xyz.jar"/>
    <WebAppComponent Name="pqr" Targets="myserver" URI="pqr.war"/>
    </Application>.
    The above is working fine.
    But in config.xml file WL10,I cannot mention the same.
    I need to have different application anmes for ear,jar and war.If I deploy as a ear file,the jar and war files are deployed with the same ear file name.
    I tried the following options:
    1) Deploying as a ear file by adding <sub-deployments>
    2) Deploying both war and jar seperately which is not recommended in my application.
    Please provide the content I should place in the config.xml so that everything works fine correctly.
    Any help is appreciated.

  • How to make ear and war file

    hi ,
    can anyone tell me how to make the ear and war file ??/
    Regards,
    Shruti.

    hello shruti
    to make war file enter the following command through command prompt
    jar -cvf filename.war give one space then .(dot)
    bye

  • Explain about JAR,EAR and WAR files

    Explain :what is JAR,EAR and WAR files and how is useful in creating archive files in java with more example?

    Please look up this type of information on your own.
    http://java.sun.com/reference/glossary/index.html

  • EAR and WAR file deployment

    hi,
    Does anyone have information on how to use the EARASSEMBLER
    tool for creating ear files and war files?????
    thanks

    Hi Cheenai,
    EARASSEMBLER is an Orion tool and it is not supported in the
    current release of Oracle9iAS Containers for J2EE (even though
    it's bundled with the installation).
    You may download Oracle9i JDeveloper Release Candidate as the
    integrated development tool to build, assemble, package and
    deploy any J2EE applications (EJB-JAR, WAR, EAR files etc.):
    http://otn.oracle.com/software/products/jdev/content.html
    You may also download the "ant" command line tool to build and
    package J2EE files:
    http://jakarta.apache.org/ant/

  • Ear and War file difference

    I have created and loaded WAR files for Web Applications on my Tomcat 4.1.27 web container.
    I have also heard about EAR files and was wondering if I have the correct definition. On one of my Google searches it says: EAR files contain JAR files and WAR files.
    I assume an EAR file can contain many JAR and WAR files wrapped into one file (EAR)? Another way of looking at it is if I have for example 3 WAR files, I can put all 3 in an EAR file?

    All the archive files used in Java apps are basically ZIP files with the extension changed.
    JARs are used to package classes.
    WARs are used to package web applications ( the complete directory structure are mandated by J2EE specs ) and may contain JARs
    EARs are used to package a J2EE application ( think web app + EJBs in general ) and may consist of many web modules packaged as WARs.
    Take a look at this too: http://searchwebservices.techtarget.com/expert/KnowledgebaseAnswer/0,289625,sid26_gci837938,00.html
    People on the forum help others voluntarily, it's not their job.
    Help them help you.
    Learn how to ask questions first: http://faq.javaranch.com/java/HowToAskQuestionsOnJavaRanch
    (Yes I know it's on JavaRanch but I think it applies everywhere)
    ----------------------------------------------------------------

  • Problems faced when using xsl:include and extension functions

    I am Working in XML and XSLT using Oracle's XML Parser V2.
    Previously i had worked in Microsoft technology using MSXMLParser.
    I am facing some problems in XSLT. They are as below...
    1. Using <xsl-include href="Somexsl.xsl">
    the oraclexmlparser processor is giving the error : XSL-1002: Error while processing include XSL file (no protocol: Submenu.xsl).
    * Can u tell me why i am getting this error, and what is the fix for this.
    The same case with <xsl:import> too.
    2. In case i have to write some functions in the previous WD of xsl i used these statements
    <?xml version='1.0'?>
    <!DOCTYPE PageRoot SYSTEM "../../Common/dtd/PageNavBar.dtd">
    <xsl:stylesheet
    xmlns:xsl="http://www.w3.org/TR/WD-xsl"
    xmlns:html="http://www.w3.org/TR/REC-html40"
    result-ns="">
    <xsl:script xmlns:xsl="uri:xsl"><![CDATA[
    var strWebContentPath = "/SurSITE/Content/";
    var strWebImagePath = "/SurSITE/sursitegraphics/";
    function IncScript()
    return "<script language='javascript' src='/SurSITE/Includes/avalidations.js'></script>";
    ]]>
    </xsl:script>
    To call the function i used this
    <xsl:eval no-entities='true'> IncScript();</xsl:eval>
    * Can u tell me how do i do this now, i tried with the code above using the current name space (<xsl:stylesheet version="1.1"
    xmlns:xsl="http://www.w3.org/1999/XSL/Transform" />)
    Please use the example given above.
    I will be very greatfull to u if u can give me some suggestion or help for the above said problems.
    Thanking you and eagerly waiting for your reply(s).
    null

    The current version is "1.0" not "1.1"
    You haven't included the code for what your <xsl:include>
    statement looks like, which seems to be what it's complaining
    about...
    XSLT 1.0 has no <xsl:eval>, this is a microsoft specific tag
    from a pre-XSLT-1.0 version.
    XSLT 1.0 has no <xsl:script> element either.

  • WorkShop 3.2.0 - WEB-INF/classes not included in war file

    I've created the "Faces Example" project in Workshop Studio 3.2.0 and it's running fine. However, when I export the war file to run it on another server the class files located at "WEB-INF/classes" are not included with the war.
    Any suggestions on what I may be doing wrong would be greatly appreciated.
    thks!

    Unfortunately no, the issue with output folder being ignored occurs only with example apps bundled with Workshop product.
    You can try the following workaround:
    - In Workshop, Project > Properties - Java Build Path, switch to Source tab - "Remove the source folder listing" - Click OK and dismiss Properties window.
    - Project > Properties - Java Build Path > Source Tab, add the same source folder entry - Click OK
    - Export as WAR
    With this you should see the class files bundled under output directory structure (Ex: WEB-INF/classes).

  • Clustering, unix symbolic links, and war files

              Hello,
              we use symbolic links in our web application to a large shared storage device.
              This works when running a single server, when the application is not a war file.
              When we cluster the application, the admin server creates a war file, blindly
              follows the symbolic links and tries to include all files in the shared storage
              device. Bad!
              Is there a work-around to this problem in a clustered configuration?
              -Thanks-
              

              hi,
              can you tell me know you deploy your app to the cluster member
              manually? do you run each member as an admin server? how do
              you group them into a cluster then?
              thanks,
              yan
              "Philippe Lantin" plantin_AT_cobaltgroup.com wrote:
              >
              >
              >Yes, this method works. I did want to keep a central admin server to
              >avoid have
              >multiple configuration files, and deploy new code to only one location.
              >I suppose
              >I could do this via a shared drive.
              >
              >I have an open case with BEA on this issue. The root of the problem appears
              >to
              >be that the jar format isn't equipped to deal with symbolic links. Webapps
              >which
              >are exploded in directories lose their symbolic links when packaged in
              >a war.
              >
              >Thanks,
              >
              >Philippe Lantin
              >
              >"Cameron Purdy" <[email protected]> wrote:
              >>I've never used that centralized deployment feature; rather I've always
              >>configured each of the cluster members manually, partly because of the
              >>bug
              >>in the admin server in 6.0 (?) that would not allow it to deploy to
              >the
              >>cluster.
              >>
              >>Can you try to deploy the application manually?
              >>
              >>Peace,
              >>
              >>--
              >>Cameron Purdy
              >>Tangosol Inc.
              >><< Tangosol Server: How Weblogic applications are customized >>
              >><< Download now from http://www.tangosol.com/download.jsp >>
              >>
              >>
              >><Philippe Lantin plantin_AT_cobaltgroup.com> wrote in message
              >>news:[email protected]...
              >>>
              >>>
              >>> Hi,
              >>>
              >>> our web application is not a war when we use a single server. We simply
              >>use a
              >>> directory under "applications". This method works correctly with symbolic
              >>links
              >>> under weblogic v.6.1.
              >>>
              >>> To test our application in the cluster, we use the previous single
              >>server
              >>as the
              >>> administration server, leaving the application directory intact. We
              >>create
              >>a cluster
              >>> definition with it's target members using this web application.
              >>>
              >>> When we start up the cluster members, the administration server creates
              >>a
              >>war
              >>> file that is distributed to to cluster members. This is not somthing
              >>we
              >>control,
              >>> this is automatically done by weblogic.
              >>>
              >>> This is where we run into trouble. When the admin server creates the
              >>war
              >>file
              >>> to distribute to the cluster target, it follows the symbolic links
              >>and
              >>recursively
              >>> includes all files and directories. This creates a huge war file,
              >and
              >>is
              >>obviously
              >>> not the behavior we are looking for.
              >>>
              >>> Creating a war file manually doesn't help, since jar doesn't support
              >>symbolic
              >>> links.
              >>>
              >>> Thanks,
              >>>
              >>> Philippe Lantin
              >>>
              >>>
              >>> "Cameron Purdy" <[email protected]> wrote:
              >>> >I don't understand at which point you are running into a problem.
              >>> >
              >>> >> we use symbolic links in our web application to a large shared
              >storage
              >>> >device.
              >>> >
              >>> >That is not uncommon, for example to use a Sun storage box or EMC
              >>with
              >>> >some
              >>> >fault tolerant characteristics to host the application images etc.
              >>> >
              >>> >> This works when running a single server, when the application is
              >>not
              >>> >a war
              >>> >file.
              >>> >
              >>> >Do you mean when it is "exploded"? Does it work with a single server
              >>> >when
              >>> >the app is a war file?
              >>> >
              >>> >> When we cluster the application, the admin server creates a war
              >>file,
              >>> >blindly
              >>> >> follows the symbolic links and tries to include all files in the
              >>shared
              >>> >storage
              >>> >> device.
              >>> >
              >>> >This is the part that I don't follow. Are you using 6.1sp1? What
              >are
              >>> >the
              >>> >steps that you are taking with the admin server?
              >>> >
              >>> >Peace,
              >>> >
              >>> >--
              >>> >Cameron Purdy
              >>> >Tangosol Inc.
              >>> ><< Tangosol Server: How Weblogic applications are customized >>
              >>> ><< Download now from http://www.tangosol.com/download.jsp >>
              >>> >
              >>> >
              >>> ><Philippe Lantin plantin_AT_cobaltgroup.com> wrote in message
              >>> >news:[email protected]...
              >>> >>
              >>> >>
              >>> >> Hello,
              >>> >>
              >>> >> we use symbolic links in our web application to a large shared
              >storage
              >>> >device.
              >>> >> This works when running a single server, when the application is
              >>not
              >>> >a war
              >>> >file.
              >>> >> When we cluster the application, the admin server creates a war
              >>file,
              >>> >blindly
              >>> >> follows the symbolic links and tries to include all files in the
              >>shared
              >>> >storage
              >>> >> device. Bad!
              >>> >>
              >>> >> Is there a work-around to this problem in a clustered configuration?
              >>> >>
              >>> >> -Thanks-
              >>> >>
              >>> >>
              >>> >>
              >>> >
              >>> >
              >>>
              >>
              >>
              >
              

  • Xsl:include and xml:import

    I want to use another stylesheet within the original one.
    the documentation just said how to declare an
    xsl:include or xsl:import element as top level, but no examples about how to call the imported or included stylesheet.
    I'll appreciate any examples you can provide to me .
    Thanks
    Chris

    I've done this, and the way i think about it is that each "imported" XSL document combines (or are appended) into the XSL document that imports the other XSL documents. As such, all of the template matching that is occuring has to be consistent with the way the XML tags are matching up with XSL templates.
    It is important that the templates in each imported XSL document will match up to the XML tags that the templates are designed to transform.
    In other words, if i have an employee list <emp>, and an XSL template matching the <emp> element, i can produce a transformation on the list itself. now, i can define a transformation for a child element of <emp> by "importing" the XSL document that defines the template match for the child element (for example, "emp/lastName" can be what the second XSL document matches on).
    Long story short, if you can paste the imported XSL into the importing XSL and things still work, then you can separate them out into multiple modular XSL files for inclusion.
    -dave
    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by Christos Kouros ([email protected]):
    I want to use another stylesheet within the original one.
    the documentation just said how to declare an
    xsl:include or xsl:import element as top level, but no examples about how to call the imported or included stylesheet.
    I'll appreciate any examples you can provide to me .
    Thanks
    Chris<HR></BLOCKQUOTE>
    null

  • How to work with two different backend with same MI Server and war file

    Hi All,
    We have a requirement that we need to work with one Middleware for two backends. For that we had to copy MAM30 sync bo's to zsync BO'S with the name ZMAM30. Now both sync BO'S will point to different backends.
    I have a standard war file which was working well with standards sync bo's. Now to work on zsync bo's what all the changes do I have to do in the standard war file(code).
    As per my knowledge we have a file called "syncbonamelist.properties" which maps the sync bo keys. Also there is another file called "mapping.xml" file which maps the package name with BO name.
    Can any body please tell me, are there any other files needed to be change like "meRepMeta.xml", other than any existing code like java objects are also needed to be changed.
    Your help in this regard is highly appreciable.
    Regards
    Murthy

    Hi Murthy,
    I try to get my head around the question:WHY?
    The reason for my question is, that this influences the answer!
    Because of several reasons it is NOT possible to handle MAM and zMAM Bos at the SAME TIME on the SAME MACHINE in the way you describe it - and it makes no sence to do so at all! But anyway......
    Lets say you have two backends, cause you have two different areas of the company. But both want to use the same MI server - but the client should be independend.
    So you need two apps. One uses the MAM BOs and the second one uses the zMAMBos.
    If this is the case, dev should be straight forward I think and you solution should work already......... so I ask myself, what is the problem you have? Do you get an error?
    - First create a new MEREPMETA-XML with just the zMAMBOs instead of the MAM BOs.
    - Change the two files you mentioned above.
    This should be all then.
    If you have a look into the implementation for MAM001Impl for example, there you find a line like:
         private static final String SYNC_BO_NAME
              = ResourceBundle.getBundle("com.sap.mbs.mam.bo.impl.syncbonamelist").getString("MAM30_040");
    This takes the name from the properties file and maps it to the real BO. So changing the name in the property file to
    MAM30_040 = zMAM30_040
    will result in MAM uses the zMAM BOs.
    Be aware: after you place the WAR file in the WEBAPPS folder and do a restart to deploy the file, you need to do a data reset to make sure the new MEREPMETA.XML is read.
    AND: two apps! one for MAM and one for zMAM BOs. One APP is not possible! Cause if you have something like that in the properties file:
    MAM30_040 = MAM30_040
    MAM30_040 = zMAM30_040
    if will only take the first reading.
    But I think this is clear to you anyway
    Regards,
    Oliver

  • Web application deployment failure when Mozilla Rhino 15R2 included in war file

    Hi Guys
    I'm currently attempting to deploy a web application under weblogic 6.1.
    The application makes use of Mozilla Rhino15R2, packaged in the file js.jar.
    With js.jar contained in the WEB-INF\lib directory in the war file, the
    application fails to install, the weblogic.log file has the following entry.
    ####<22-Oct-00 09:53:53 BST> <Info> <HTTP> <winnt2> <winnt2> <main> <system>
    <> <101053> <[HTTP winnt2] Loading web app: SWIFTAccessControl>
    ####<22-Oct-00 09:53:53 BST> <Info> <HTTP> <winnt2> <winnt2> <main> <system>
    <> <101059> <[winnt2] Loading SWIFTAccessControl from WAR file:
    I:\bea\wlserver6.1\.\config\mydomain\applications\.wlnotdelete\wl_comp53845.
    war>
    ####<22-Oct-00 09:53:53 BST> <Info> <HTTP> <winnt2> <winnt2> <main> <system>
    <> <101031>
    <[WebAppServletContext(6025277,SWIFTAccessControl,/SWIFTAccessControl)]
    extracting classfiles to
    I:\bea\wlserver6.1\config\mydomain\applications\.wlnotdelete\WEB-INF\_tmp_wa
    r_winnt2_winnt2_SWIFTAccessControl:>
    ####<22-Oct-00 09:53:53 BST> <Debug> <HTTP> <winnt2> <winnt2> <main>
    <system> <> <101158> <Exception thrown while loading SWIFTAccessControl:
    java.lang.IllegalArgumentException: Prefix string too short>
    java.lang.IllegalArgumentException: Prefix string too short
    ####<22-Oct-00 09:53:54 BST> <Error> <J2EE> <winnt2> <winnt2> <main>
    <system> <> <160001> <Error deploying application SWIFTAccessControl: Could
    not load SWIFTAccessControl>
    If I rebuild the war file, excluding js.jar weblogic successfull deploys the
    application and I can access the application. Question has anyone come
    across a similar problem and does any one know of a solution. I'd be most
    grateful for any help on this one.
    Regards
    Tony

    Check this thread...
    Spring's JSF DelegatingVariableResolver cause InvocationTargetException

  • Problems with properties files and war files in weblogic 5.1

              I work with WebLogic 5.1 and I'm trying to deploy a web application which gets
              a properties file. If I deploy it as an expanded directory hierarchy (with the
              properties files into WEB-INF/classes) I have no problems. While deploying it
              by a .war file I get this message: "en_GB java.util.MissingResourceException:
              Can't find resource for base name Agent, locale en " (the getBundle() method is
              trying to get an english property file). What could I do? Is it really a weblogic
              5.1 bug?
              Thanks,
              David
              

    This issue comes up repeatably. It's a real bug.
              I believe this problem was fixed in a 5.1 service pack, but I'm trying to
              find out the exact disposition of the issue. Noone seems to be complaining
              about this under 6.x, so a fix seems to have been made, the only question is
              whether or not it got back-ported to a 5.1 service pack.
              Gary
              david <[email protected]> wrote in message
              news:3ac4a39a$[email protected]..
              >
              > I work with WebLogic 5.1 and I'm trying to deploy a web application which
              gets
              > a properties file. If I deploy it as an expanded directory hierarchy (with
              the
              > properties files into WEB-INF/classes) I have no problems. While deploying
              it
              > by a .war file I get this message: "en_GB
              java.util.MissingResourceException:
              > Can't find resource for base name Agent, locale en " (the getBundle()
              method is
              > trying to get an english property file). What could I do? Is it really a
              weblogic
              > 5.1 bug?
              > Thanks,
              > David
              

  • Description of EAR and WAR files

    Does anybody know or has a link with the description of the files/directory's that are standard in EAR/WAR files.
    Example: what is the functionality of the web.xml.
    Thnx.

    http://java.sun.com/webservices/docs/ea2/tutorial/doc/WebApp3.html
    http://java.sun.com/j2ee/tutorial/1_3-fcs/doc/WCC3.html#64295
    http://jakarta.apache.org/tomcat/tomcat-4.1-doc/appdev/deployment.html
    http://www-3.ibm.com/software/webservers/appserv/doc/v40/ae/infocenter/was/000101.html
    http://java.sun.com/j2ee/tutorial/1_3-fcs/doc/Tools8.html#63061

  • Creating ear and war file from deploy file programatically

    Hi All,
    Is there any API available in oc4j to create an ear or war file from a .deploy file...........??
    Thanx in advance.

    There isn't a public API that let's you hook up to the deploy file in JDeveloper.
    You might be able to achieve this with the JDeveloper Ant task:
    http://www.oracle.com/technology/products/jdev/htdocs/partners/addins/exchange/anttasks/index.html

Maybe you are looking for

  • Don't restore form values on tab restore

    A part of my website uses a lot of forms on a single page. On the page, you can filter the items (each item has his own form) and alter them. A single entry looks like this: [name] [select for status] [other select]. Other significant things are that

  • How can I restore my old library?

    Hi! I hope this question will make sense and that one of you can help. I lost all my music when I ejected my hard drive incorrectly. I still have, though, my iTunes files corresponding to that music: all the files starting with "iTunes Library" in th

  • Dual boot: Arch and another Linux (GRUB issue)

    Hi, everybody, I've got two SATA hard drives: sda and sdb. There is a Linux on sdb, and the GRUB in it's MBR. Here's /boot/grub/menu.lst (sdb): timeout 10 color black/cyan yellow/cyan gfxmenu (hd0,0)/usr/share/gfxboot/themes/pclinuxos/boot/message de

  • Is anyone using Pegasus with iMovie?

    I purchased Pegasus when I got my new macbook Pro, latest version purchased a few months ago. Pegasus seems fast and promising. Decided to get all my iMovie stuff and organize it onto Pegasus. I had been using a Powermac G5 previously. Was using fina

  • FMF0-RFFMS200 not working

    Hi all. We are trying to make payment program for FM to work properly. However we are unable to do so. In our test system we posted several invoices for the same vendor and paid all of then un one payment. We have entries for all of these invoices FM