MyEclipse Forums
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Author Message
sgits
Post subject: deploying to Websphere 6.1: Failed to read web-app_2_5.xsd  PostPosted: Mar 27, 2012 - 03:22 PM



Joined: Mar 27, 2012
Posts: 2

I'm attempting to deploy a project to a local, development Websphere 6.1 profile in the following manner: Servers tab > Rclick server > Add Deployment... > select a project

However, the deployment fails with the following error message:

Code:
org.xml.sax.SAXParseException: schema_reference.4: Failed to read schema document 'http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd', because 1) could not find the document; 2) the document could not be read; 3) the root element of the document is not <xsd:schema>.


I tried visiting that particular URL in my browser and sometimes the .xsd is available and sometimes not. When it is available, I then get similar errors pertaining to either javaee_5.xsd or jsp_2_1.xsd, which I see are referenced in web-app_2_5.xsd as follows:

Code:
  <xsd:include schemaLocation="javaee_5.xsd"/>
  <xsd:include schemaLocation="jsp_2_1.xsd"/>


How can I proceed with my deployments? Is there a way to prevent the deployment process from reaching out to the Internet, perhaps by using the XML Catalog instead?

Thanks!

- Ted
 
 View user's profile Send private message  
Reply with quote Back to top
support-swapna
Post subject:   PostPosted: Mar 28, 2012 - 07:08 AM



Joined: Nov 11, 2010
Posts: 2192

sgits ,

Sorry that you are seeing this issue. Thank you for the log files.

Can you please answer some more questions for us ?

1. What kind of a project is it? Is it a portlet project? Please share the project details.

2. Can you please try exporting the project as WAR or EAR file (whichever is appropriate) and deploying the file using the WAS admin console to see if the issue persists?

3. Do you know which particular file is referencing the xsds?

Let us know how it works for you.

_________________
Swapna
MyEclipse Support
 
 View user's profile Send private message  
Reply with quote Back to top
sgits
Post subject:   PostPosted: Mar 28, 2012 - 05:48 PM



Joined: Mar 27, 2012
Posts: 2

Hi Swapna,

Thanks for your reply.

>> 1. What kind of a project is it? Is it a portlet project? Please share the project details.
It's a Struts1 app, which I deploy to our test and production environments as a WAR file.

>> 3. Do you know which particular file is referencing the xsds?
It's web.xml.

>> 2. Can you please try exporting the project as WAR or EAR file (whichever is appropriate)
>> and deploying the file using the WAS admin console to see if the issue persists?

This method resulted in a failure to upload the WAR file, both in the existing local profile connected to MyEclipse and a brand new, unconnected profile I created this morning. Checking the logs/server1/SystemErr.log, I see the following:

Code:
[3/28/12 16:00:07:347 GMT] 00000022 SystemErr     R org.eclipse.jst.j2ee.commonarchivecore.internal.exception.DeploymentDescriptorLoadException: IWAE0022E Exception occurred loading deployment descriptor for module "UII.war" in EAR file "c:\my-dev\IBM\WAS6.1Ex\profiles\TestServer\wstemp<!-- [display] -->\upload\UII_war.ear"
Stack trace of nested exception:
org.eclipse.jst.j2ee.commonarchivecore.internal.exception.DeploymentDescriptorLoadException: WEB-INF/web.xml
Stack trace of nested exception:
org.eclipse.jst.j2ee.commonarchivecore.internal.exception.ResourceLoadException: IWAE0007E Could not load resource "WEB-INF/web.xml" in archive "UII.war"
Stack trace of nested exception:
org.eclipse.emf.common.util.WrappedException: org.xml.sax.SAXParseException: src-resolve: Cannot resolve the name 'javaee:descriptionGroup' to a(n) 'group' component.



This leads me to believe that the issue lies in my local installation of Websphere and not MyEclipse. I did some research and discovered that Websphere 6.1 is at JEE 2.4, not JEE 2.5, so I changed the following in the web.xml:

From:
Code:
<web-app version="2.5"
   xmlns="http://java.sun.com/xml/ns/javaee"
   xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
   xsi:schemaLocation="http://java.sun.com/xml/ns/javaee
   http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd">

To:
Code:
<web-app version="2.4"
    xmlns="http://java.sun.com/xml/ns/j2ee"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">


Deployments via MyEclipse to the local Websphere profile are now successful, so I think I'm good now. I still find it a bit odd that I can continue to deploy WAR files to my test and production environments without issue, and I was able to deploy a project to a local profile five days ago.

Regardless, thanks for pointing me in the right direction!

- Ted
 
 View user's profile Send private message  
Reply with quote Back to top
support-swapna
Post subject:   PostPosted: Mar 29, 2012 - 06:14 AM



Joined: Nov 11, 2010
Posts: 2192

sgits ,

Glad that it is working.
Do let us know if you have any issues.

_________________
Swapna
MyEclipse Support
 
 View user's profile Send private message  
Reply with quote Back to top
Display posts from previous:     
Jump to:  
All times are GMT - 6 Hours
Post new topic   Reply to topic
View previous topic Printable version Log in to check your private messages View next topic
Powered by PNphpBB2 © 2003-2004 The PNphpBB Group
Credits