Weblogic 10.3 configuration for serving static content

When we deploy Web Application the default document root of application will be its own root directory. If we want to have all the xml files on the disk to be in different location other than our deployment directory you can use virtual directory mapping in our Applications deployment descriptors. Below is the information on virtual directory mapping.
virtual-directory-mapping
=============================================================================
Use the virtual-directory-mapping element to specify document roots other than the default document root of the Web application for certain kinds of requests, such as image requests. All images for a set of Web applications can be stored in a single location, and need not be copied to the document root of each Web application that uses them. For an incoming request, if a virtual directory has been specified servlet container will search for the requested resource first in the virtual directory and then in the Web application’s original document root. This defines the precedence if the same document exists in both places.
Example:
<virtual-directory-mapping>
<local-path>c:/usr/gifs</local-path>
<url-pattern>/images/*</url-pattern>
<url-pattern>*.jpg</url-pattern>
</virtual-directory-mapping>
<virtual-directory-mapping>
<local-path>c:/usr/common_jsps.jar</local-path>
<url-pattern>*.jsp</url-pattern>
</virtual-directory-mapping>
Below edocs link has more information virtual directory mapping.
http://e-docs.bea.com/wls/docs103/webapp/weblogic_xml.html#wp1039396
- - Tarun

Hi,
I have a web application deployed to one of the managed server nodes.
I need to access web application using the url http://<host>:<port>/webApp/
I dont want to use that way.
I need to access the welcome file directly without using the web application name like the one below.
http://<host>:<port>/welcome.jsp
I have read about virtual-directory-mapping and I have ran the examples which comes with weblogic installation.
I have changed the weblogic.xml that comes with my application as follows
<?xml version="1.0"?>
<!DOCTYPE weblogic-web-app PUBLIC "-//BEA Systems, Inc.//DTD Web Application 8.1//EN" "http://www.bea.com/servers/wls810/dtd/weblogic810-web-jar.dtd">
<weblogic-web-app>
<virtual-directory-mapping>
<local-path>G:/Test</local-path>
<url-pattern>/*.html</url-pattern>
     <url-pattern>/index.jsp</url-pattern>
</virtual-directory-mapping>
</weblogic-web-app>
I have pasted fast_track.html and index.jsp to g:/Test folder.
After i restart the managed server, am still getting" 404 Page not found" error.
Kindly help.
Thanks,
Charan
Edited by: charan27 on Sep 2, 2010 8:11 AM

Similar Messages

  • Serving static content from a directory

    Is it possible to configure WebLogic to serve static content (files) from a directory via an HTTP GET?
    What I need is similar to the Apache functionality of publishing a directory by mapping a URL (http://weblogic.server.xx/somePrefix) to a directory on the file-system (e.g. /path/to/some/dir) and allow one to:
    - list the directory content by visiting the URL
    - fetch files by doing an HTTP GET (this would be by clicking on a file in the listing)
    Can one do this without adding a separate HTTP server on the same machine as WebLogic?

    I believe if you created a WEB-INF directory at that location and added a skeleton web.xml file, you could specify that location when you deployed a new application from the admin console. I believe there should be an option to allow listing the directory contents, perhaps somewhere in the server definition tabs.

  • How to configure Apache to serve static content? Please Help

    Hi Guys,
    I have a set of servers that are:
    - Apache acting as a Load Balance;
    - Admin Server;
    - A cluster with 2 managed servers.
    I have a web application deployed on my cluster, but I would like that the static content would be delivered by the Apache.
    How should I do it?
    Thanks in Advance

    Hi Daniel,
    A Reverse Proxy could do this but keep in mind that the primary goal of the RP is to shield your back channel infrastructure IP/access from either Internet or your private network e.g. secure your back channel infrastructure with a Firewall and expose it only to your Reverse Proxy infrastructure; quite effective for DoS type of attack.
    Apache can be configured to do both static content as well as Reverse Proxy.
    Regards,
    P-H
    http://javaeesupportpatterns.blogspot.com/

  • MDD to ECC Configuration for Vendor PI Content

    Hi,
    I am working on MDM to ECC Scenario for sending Vendor details to ECC using the standard maps available in MDM BUSINESS CONTENT 7.1 SWCV.
    There are two message mappings:
    1) CREMDM.CREMDM04 to CREMAS.CREMAS05
    2) CREMDM.CREMDM04 to ADRMAS.ADRMAS03
    How should I configure the scenario in Integration Directory.
    Do I need to use any splitting condition using Xpaths?
    Can you  send any blogs or SAP Notes avaiable for this?
    Best Regards,
    Harleen Kaur Chadha

    Hello Harleen,
    Maybe this can help you
    /people/harrison.holland5/blog/2006/12/20/xi-configuration-for-mdm-integration--sample-scenario
    http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/107fabbb-b8ca-2b10-04b5-8f34729ef228
    http://www.sdn.sap.com/irj/scn/index?rid=/library/uuid/daa51a96-0b01-0010-738f-a0ecfd06104e
    Regards,
    lpbuff

  • Need hardware configuration for server

    Hi All,
    Need server hardware configuration for deploying and maintaining SSAS cube. Consider OLTP size as 100 GB
    Thanks,
    ATRSAMS

    Hi Atrsams,
    According to your description, you need some hardware recommendations for deploying and maintaining a SQL Server Analysis Services cube, right?
    Though this isn't a sizing recommendation, I'd encourage you to buy as much memory as you can afford. This is generally the choke point I've seen on servers, especially when using SSAS. For the detail information about it, please refer to the links below.
    http://sqlblog.com/blogs/marco_russo/archive/2013/02/12/hardware-sizing-guide-for-ssas-tabular.aspx
    http://www.experts-exchange.com/Hardware/Microsoft_Hardware/Q_27781248.html
    Regards,
    Charlie Liao
    TechNet Community Support

  • Php update/configure for Server 4.0

    I had working Apache2 + PHP 5.6 running perfectly locally for development.
    Web Docs were located in /Sites folder in user directory.
    After Installing Server 4.0 all my setup is messed up. I can configure website again but it not uses PHP I have upgraded to.
    I feel lack of control/configuration for web apps with Server 4.0. How I can get it working back as perviously or uninstall Server 4.0?
    Filip

    I have found solution to fix Apache after uninstallation of Server 4.0
    http://remonpel.nl/2014/08/restore-apache2-service-after-removal-of-server-app/# more-554
    I found also more articles that maybe would help me running my websites with OS X Server.... but for now I have decided to not come back to try this.
    http://remonpel.nl/

  • Best Practice for serving static files (gif, css, js) from front web server

    I am working on optimization of portal performance by moving static files (gif, css, js) to my front web server (apache) for WLP 10 portal application. I end up with moving whole "framework" folder of the portal WebContent to file system served by apache web server (the one which hosts WLS plugin pointing to my WLP cluster). I use <LocationMatch> directives for that:
    Alias /portalapp/framework "/somewhere/servedbyapache/docs/framework"
    <Directory "/somewhere/servedbyapache/docs/framework">
    <FilesMatch "\.(jsp|jspx|layout|shell|theme|xml)$">
    Order allow,deny
    Deny from all
    </FilesMatch>
    </Directory>
    <LocationMatch "/partalapp(?!/framework)">
         SetHandler weblogic-handler
         WLCookieName MYPORTAL
    </LocationMatch>
    So, now browser gets all static files from apache insted of the app server. However, there are several files from bighorn L&F, which are located in the WLP shared lib: skins/bighorn/ window.css, wsrp.css, menu.css, general.css, colors.css; skins/bighorn/borderless/window.css; skeletons/bighorn/js/ util.js, buttons.js; skeleton/bighorn/css/layout.css
    I have to merge these files into the project and physically move them into apache served file system to make mentioned above apache configuration works.
    However, this approach makes me exposed bunch of framework resources, which I do not to intend to change and they should not be change (only custom.css is the place to make custom changes to the bighorn skin). Which is obviously not very elegant solution. The other approach would be intend to create more elaborate expression for LocationMatch (I am not sure it's entirely possible giving location of these shared resources). More radical move - stop using bighorn and create totally custom L&F (skin, skeleton) - which is quire a lot of work (plus - bighorn is working just fine for us).
    I am wondering what is the "Best Practice Approach" approach recommended by Oracle/BEA - giving the fact that I want to serve all static files from my front end apache server instead fo WLS app server.
    Thanks,
    Oleg.

    Oleg,
    you might want to have a look at the official WLP performance support pattern (Metalink DocID 761001.1 ) , which contains a section about "Configuring a Fronting Web Server Serving WebLogic Portal 8.1 Static Artifacts ".
    It was written for WLP 8.1, but most of the settings / recommendations should also to WLP 10.
    --Stefan                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

  • Multiple Apache-Weblogic plug-in configurations for the same host

              Hi BEA,
              I have a situation where I have more than one weblogic server/cluster both using
              the same Apache to proxy. Reading the Apache plug-in configuration I gather that
              below should work. In Apache (httpd.conf):
              <Location /path1>
              SetHandler weblogic-handler
              WeblogicHost app1
              WeblogicPort 7001
              </Location>
              <Location /path2>
              SetHandler weblogic-handler
              WeblogicHost app2
              WeblogicPort 7001
              </Location>
              In this case the later Location of the two works fine and the other seems like
              it is just not there. (If the two are switched the other works fine...) The thing
              is that, if possible, I would like to avoid splitting the two locations onto two
              different VirtualHosts (which works).
              Does anyone have any ideas on how to solve this and still avoid the use of multiple
              VirtualHost-definitions?
              Is it due to a limitation in Apache module architecture that the configuration
              above does not work or is it a design choice in the plug-in?
              //GG
              

              Gunnar,
              I would post this Apache proxy plug in question to the
              weblogic.developer.interest.plug-in forum
              Chuck Nelson
              DRE
              BEA Technical Support
              

  • Weblogic 8.0 configuration for JSTL

    Hi all!
    Can anybody please guide me how to configure Weblogic 8.0 for web development using JSTL ?
    thanks for any sort of support!

    I have installation doc. for weblogic 8.0 SP4
    If you need it send a mail to
    [email protected]
    Regards,
    Rengaraj.RWhat does this have to do with using JSTL? You don't need installation docs for that. If anybody wants them, they can go to BEA to get them.
    %

  • Static content in iAS 6.5 (for JavaWebstart)

    Hello,
    I'm using iAS 6.5.
    I want to serve a jar file for JavaWebstart in a J2EE App (including a war file)
    That works, but it tooks a very long time before Webstart is loading this Jar and it is fully reloaded every time i access that App from Webstart.
    When I put this jar file into the iPlanet Webserver it is loaded much faster and will not be reloaded every time i access this jar file with Webstart.
    1. Is it possible to serve static content in iAS that Webstart is not fully reloading every time, instead of only checking the header informations for a newer version?
    2. Can you give me a link to an iPlanet documentation about how to handle static content iAS/iWS !
    3. Will be the iPlanet Webserver Settings (e.g. KeepAlive) ignored, when i run Webcontent from the Applicationserver (../NASApp/...)?
    Kinds
    Regards

    JAX-RPC, JAX-M and other JAX-x are tested with JDK 1.3.x and higher. Since iAS 6.5 uses jdk 1.3.1, I think JAX-RPC, JAX-M can be used in iAS 6.5. -Officially, as far as I know, iAS 6.5 does not provide any support for JAX-pack.
    Sun ONE AS 7 fully supports JAX-pack, and it has a tool, XRPCC, (now wscompile and wsdeploy) which generates stubs, ties and WSDLs for the services. Also the same tool can be used to generate the stubs, client side artifacts, from any WSDL file.
    And also JAX-run time provides SOAP 1.1, UDDI v2 Registry access and WSDL support. Interoparability between JAX-Run time and other SOAP 1.1 implementations is also tested successfully.
    There are several third partly tools available from different vendors (around 10-12), you may wish to search for them in google. And with that you may generate WSDL for your Apache SOAP services.
    If you are planning to have a standalone web services client, then you can directly use JWSDP at the client side to communicate with the Apache SOAP services on the iPlanet Application Server 6.5.
    Please get back for any further assistance.

  • Static contents

    A weblogic domain with at least 2 managed servers on it and configured a web
    application to serve
    static contents and it works great.
    When I add more images or htmls or any resources, then only the admin server
    picks it but not the
    managed servers. I have to redeploy the web application for the managed
    servers to see it.
    Does anybody know how setup the web application/managed servers pick up the
    new static resources
    without having to redeploy the web application? I can always use different
    web server for it but it
    increases the complexcity of the configuration for weblogic and apache/iis
    Please provide some idea.
    Thanks
    /selvan

    Selvan,
    Here's the info on how to refresh data files without redeploying. In
    6.1, this functionality is included in the release. For 6.0, I believe
    this tool was added in 6.0 sp2 rp2, but I'm not certain. If the tool
    doesn't exist in the version you have, contact support to get the
    correct service pack.
         -- Jim
    WebAppComponents can be refreshed without having to redeploy the whole
    application. any file that doesn't have classloading implications can be
    refreshed. (also known as static data). Examples of files that can be
    refreshed are: .jsp , .html, .gif, .jpg, .xml, .txt etc. Files that
    cannot be refreshed are class files, like ejb's, or other java classes.
    Data refresh in 6.0:
    In 6.0, there is a separate command line tool:
    weblogic.management.tools.WebAppComponentRefreshTool
    that can be invoked either on the command line, or can be constructed
    from within another java application. For information on how to run the
    tool from the command line, run 'java
    weblogic.management.tools.WebAppComponentRefreshTool' with no arguments.
    public WebAppComponentRefreshTool(String adminServerUrl,
    String username,
    String password,
    String appName,
    String compName,
    String[] jsps)
    username - the authenticated user...typically system
    password - the authenticated user's password
    appName - the name of the application (the mbean name)
    compName - the name of the component (the mbean name)
    jsps - an array of files to refresh.
    the appName, and compName are taken from the entries in config.xml. here
    is an example:
    <Application
         Deployed="true" Name="MyApp"
         Path=".\config\mydomain\myapps\MyApp">
         <WebAppComponent
              Name="MyWebAppComponent"
              Targets="managedServer,myserver"
              URI="MyWebAppComponent"/>
    </Application>
    in this case:
    appName would be MyApp
    compName would be MyWebAppComponent
    Data refresh in 6.1:
    refresh in 6.1 works the same way as it does in 6.0, but it has been
    folded into the weblogic.deploy command. you can still do refresh from
    either the command line, or from within a java application, but you can
    use weblogic.deploy to do it.
    Selvan Ramasamy wrote:
    >
    A weblogic domain with at least 2 managed servers on it and configured a web
    application to serve
    static contents and it works great.
    When I add more images or htmls or any resources, then only the admin server
    picks it but not the
    managed servers. I have to redeploy the web application for the managed
    servers to see it.
    Does anybody know how setup the web application/managed servers pick up the
    new static resources
    without having to redeploy the web application? I can always use different
    web server for it but it
    increases the complexcity of the configuration for weblogic and apache/iis
    Please provide some idea.
    Thanks
    /selvan

  • Serve up Static Content - configuration?

    Hello!
    How can I configure WEB AS to serve up static files from an external folder? Is there a configuration in WEB AS to map a context to an external folder with static files?
    Thanks
    /Ray

    Hi Ray,
    Eddy's reply refers to setting the option on the ICM. In case you don't use the ICM, but just the Web AS Java, you can do that using the HTTP Provide Service. You can either create a virtual host (this is the term on Web AS Java for virtual directory ) and set your external directory with static content as its root directory. You can refer to the <a href="http://help.sap.com/saphelp_nw04/helpdata/en/0b/fbf5a47928f84e8d0beba8371508e6/frameset.htm">documentation</a> for details about the configuration procedure.
    Regards,
    Ivo

  • Speed of weblogic serving static pages

    Has anyone seen fairly slow page serving (measured from the end-user's
    point of view) for weblogic 4.5? Even when the system isn't hardly
    loaded at all, we have users complain about slow response times. The
    consensus is the stuff running on WebLogic is slower to appear than the
    rest of the web. We're using servlets, and jsp's. Of course this is
    hard to quantify and isolate, but we'd like to hear if others have moved
    to something like Netscape on the front end because it serves images
    faster?
    david
    David Michaels <[email protected]>
    Director of Technology
    ShockMarket Corporation (650) 330-4665
    [david.vcf]

    We had similar problems when running ejbs and jsps from the same weblogic
    server. Images load very slow. I recommend seperating your jsp server from
    your ejb server. Run two instances of weblogic, one for jsps and one for
    ejbs. In addition, you can use hardware routers that can filter by requests
    such as an alteon or f5 to route requests for images to an image server
    (apache), and all jsp requests to weblogic.We use this configuration and
    have great load times.
    "bpp" <[email protected]> wrote in message
    news:[email protected]..
    David,
    We have found the performance to be better when you serve static pages and
    images from another webserver (Netscape iPlanet). The weblogic webserver
    appears to have a diffucult time delivering images in a timely fashion. It
    also takes away from Weblogic responding to EJB requests.
    Brian Pause
    Tallan
    David Michaels wrote:
    Has anyone seen fairly slow page serving (measured from the end-user's
    point of view) for weblogic 4.5? Even when the system isn't hardly
    loaded at all, we have users complain about slow response times. The
    consensus is the stuff running on WebLogic is slower to appear than the
    rest of the web. We're using servlets, and jsp's. Of course this is
    hard to quantify and isolate, but we'd like to hear if others have moved
    to something like Netscape on the front end because it serves images
    faster?
    david
    David Michaels <[email protected]>
    Director of Technology
    ShockMarket Corporation (650) 330-4665

  • Host static content from Weblogic

    I have a need to host static content from my weblogic server in order to mimic the functionality of our old OHS server. In our case we used Apache rewrite rules in our old server that would catch someone trying to access the server directly by URL or trying to come in through HTTP instead of HTTPS and then pull the switch-a-roo on them and direct them directly to our APEX instance over a HTTPS connection. Is there a way to accomplish this same thing with weblogic without an Apache server acting as your front end?
    I found this article here http://blogs.oracle.com/middleware/2010/06/publish_static_content_to_weblogic.html about hosting static content but in my case I need the content actually at the root level (example http://domain.com/index.html) where I can throw in javascript redirect headers.
    The way I set this up was I have two servers on one box. The first server services standard HTTP requests on port 80. It will do nothing but redirect to the corresponding location on the same machine but over HTTPs on port 443.
    The server running on port 443 actually runs the APEX listener. I would like to deploy something similar to the first one that shows its content at https://server.domain.com to redirect to the Apex listener. I thought I might could repackage the apex listener to accomplish this but I would rather do it as a separate deployment rather than risk damaging our modified production copy of the APEX Listener.
    Anyone have any thoughts?

    What about using a virtual host? Create a virtual host and only target your application to that host.
    http://download.oracle.com/docs/cd/E17904_01/apirefs.1111/e13952/taskhelp/virtual_hosts/VirtualHosts.html
    Then within that virtual host, do something like this to force HTTPS:
    http://weblogicserver.blogspot.com/2009/11/force-confidentiality-for-web.html
    Then have an application that catches everything else deployed to the same server for other IP/hostnames and redirects to that virtual host. I haven't tried it, but I think that might do what you're asking about.

  • Vhost configuration for Adobe Media Server running under linux.

    Please help me with Vhost configuration for Adobe Media Server running under linux.
    I was running a media sharing website for which I wanted to use Adobe Media Server.
    To use, AMS, I disabled the already installed Apache server and installed AMS along with the built in Apache server. I could successfully install AMS and could login to AMS Admin Console through my IP number.
    My existing website, www.mydomain.com is having its contents located at:
    /home/mydomain/public_html
    (Directory created under the old version of Apache not bundled with AMS)
    Users will be uploading their videos, which will get transcoded and will be delivered to the website visitors in the existing scenario.
    To use this website with AMS, this is what I did:
    I created a folder for my domain, www.mydomain.com as below
    /opt/adobe/ams/conf/_defaultRoot_/www.mydomain.com
    Copied Application.xml and Vhost.xml from /opt/adobe/ams/conf/_defaultRoot_/   and pasted them in /opt/adobe/ams/conf/_defaultRoot_/www.mydomain.com
    In the Application.xml file there are 2 entries:
    <Alias name="mydomain.com"></Alias>
    <AppsDir>${/home/mydomain/public_html}</AppsDir>
    Please help me with further steps to be completed:
    Do I need to create a separate VirtualHost entry in the Apache installed with AMS?
    If yes, can I specify already existing document root for my website (/home/mydomain/public_html) or do I need to create a separate folder under webroot/Apache ?
    If yes to point 2 above, then do I need to copy all the existing contents from /home/mydomain/public_html to the newly created folder ?
    I hope, I can serve all my static contents like html pages and php and media like video/audio. In that case do I need create alias to my Media/Alias folder or AMS will automatically start streaming when a video/audio is requested ?
    What other steps do i need to complete?
    Any help in this regard would be highly appreciated.
    Thanks and Regards

    Dear sir or madam,
    Here is Letswin Technology, which specializes in global servers, web hosting, VPS, VPNj. If anything I can do for you, pls contact us!
    Have a nice day!

Maybe you are looking for

  • Disks disappear from my desktop even though they haven't been ejected

    This started happening a couple of days ago... Randomly, whatever CD is in the drive will disappear from my desktop even though I haven't ejected the CD. The only way I've been able to get it to reappear is by ejecting the CD and then re-inserting it

  • "Orphaned" rights in an access level?

    Odd one here.  I query for an access level (SI_KIND = 'CustomRole'), then iterate through the Role Rights collection.  I am finding some rights included that are not shown on the Access Levels screens in the XI 3.x CMC.  Specifically, entries with an

  • Restrict Certain Values seen in Portal

    Hi all, We have MDM/Portal  integreation where i want to Resrtict certain Values which is seen Portal I-Views Suppose I have some values like in my MDM lookup Table Name    Number a           1 b           3 c           4 I don't want allow b and 3 t

  • Setting the minimize/maximize size of Firefox

    Hi, Not really sure where to start, so I figured i'd start here. What i'm trying to do is the following: I want Firefox to shrink/grow to a particular size whenever I press the minimize and maximize buttons. Can this actually be done inside of Firefo

  • OK, Dropped frames due to firewire+external hard drive+camcorder?

    I have an iMac 2.4GHz , 1G Memory (I know this is less than ideal). I have a Firelite Smartdisk 120G plugged into iMac firewire. I am daisychaining my CanonZR500 into the external drive. When I capture video I have lots of dropped frames. Anyone tell