Quantcast
Channel: A Portal to a Portal
Viewing all articles
Browse latest Browse all 1850

WebSphere Liberty Profile - Where's my stuff ?

$
0
0
I saw this: -

[14/02/17 10:50:51:653 GMT] 0000002b com.ibm.ws.webcontainer.webapp                               W SRVE0190E: File not found: /foo.jsp
[14/02/17 10:50:51:744 GMT] 0000002b com.ibm.ws.logging.internal.impl.IncidentImpl                I FFDC1015I: An FFDC Incident has been created: "com.ibm.ws.jsp.webcontainerext.JSPErrorReport: JSPG0036E: Failed to find resource /foo.jsp com.ibm.ws.webcontainer.filter.FilterInstanceWrapper.doFilter 144" at ffdc_17.02.14_10.50.51.0.log
[14/02/17 10:53:03:226 GMT] 0000004f com.ibm.ws.webcontainer.extension                            W SRVE0190E: File not found: /login.html


on my local installation of WebSphere Liberty Profile (WLP) on my Mac.

What was strange was that the so-called missing files were definitely there.

Or, to be more precise, they were here: -

 ~/Downloads/wlp/usr/servers/defaultServer/apps/expanded/DefaultWebApplication.war/

HelloHTML.jspHelloVXML.jspHelloWML.jspHitCount.jspWEB-INFbanner.gifindex.htmlloginError.jsp
HelloHTMLError.jspHelloVXMLError.jspHelloWMLError.jspMETA-INFauth_error.jspfoo.jsplogin.htmllogout.html


I'd checked my server.xml for the specific web application: -

    <webApplication id="DefaultWebApplication"
    location="DefaultWebApplication.war"
    name="DefaultWebApplication" suppressUncoveredHttpMethodWarning="true" contextRoot="DefaultWebApplication">
    <application-bnd>
    <security-role name="All Role" id="admin">
    <special-subject type="ALL_AUTHENTICATED_USERS"></special-subject>
    </security-role>
    </application-bnd>
    </webApplication>


and I'd proven that the context root wasn't the problem, as I *WAS* able to access certain pages, such as this: -


So, to summarise my position, I had a web application deployed to Liberty, suitably referenced in server.xml serving SOME but not ALL requested pages ….

So I then dug into the file-system further …..

… and found this: -

 ~/Downloads/wlp/usr/servers/defaultServer/apps/DefaultWebApplication.war.xml 

<?xml version="1.0" encoding="UTF-8"?>
<archive>
    <dir sourceOnDisk="/Users/davidhay/Documents/workspace/DefaultWebApplication/WebContent" targetInArchive="/"/>
    <dir sourceOnDisk="/Users/davidhay/Documents/workspace/DefaultWebApplication/ImportedClasses" targetInArchive="/WEB-INF/classes/"/>
</archive>


And that's the problem ….

This file appears to "override" what's in the server.xml file, meaning that the actual root ( from where the content is served ) is the Eclipse workspace.

I proved this by coping the missing files: -

cp ~/Downloads/wlp/usr/servers/defaultServer/apps/expanded/DefaultWebApplication.war/log* /Users/davidhay/Documents/workspace/DefaultWebApplication/WebContent/

which did the trick.

Next step is to see whether I actually need the DefaultWebApplication.war.xml file, as it's been helpfully provided by the WebSphere Developer Tools in Eclipse, with which I've been managing the WLP instance.

Fun fun fun


Viewing all articles
Browse latest Browse all 1850

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>