Solved

Why does my MDB's weblogic-ejb-jar.xml and ejb-jar.xml fail XSD validation?

Posted on 2010-11-16
4
2,921 Views
Last Modified: 2013-12-10
I've created an EJB 3.0 MDB but cannot even get to the point of starting the local WebLogic 10.3.2 server to test because the weblogic-ejb-jar.xml and ejb-jar.xml files fail XSD validation.  

Does anyone have working examples of these two files for an MDB that listens on a queue on WebLogic 10.3.2 server?

Here are the two files as they currently exist in my workspace.  I am surprised they fail validation because in large part I cut/pasted them from another thread in this forum.  The thread was posted about 5 years ago though, so perhaps the format of these files has changed.

ejb-jar.xml

<?xml version="1.0" encoding="UTF-8"?>
<ejb-jar xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:ejb="http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd" version="3.0">
  <display-name>LabAutoODSInterfaceEJB</display-name>
  <enterprise-beans>
    <message-driven>
      <ejb-name>LabAutoODSInterfaceEJB</ejb-name>
      <ejb-class>ejbs.ODSInterfaceMDB</ejb-class>
      <transaction-type>Container</transaction-type>
      <acknowledge-mode>auto_acknowledge</acknowledge-mode>
      <message-driven-destination>
        <destination-type>javax.jms.Queue</destination-type>
        <subscription-durability>Durable</subscription-durability>
      </message-driven-destination>
    </message-driven>
  </enterprise-beans>
</ejb-jar>

weblogic-ejb-jar.xml

<?xml version="1.0" encoding="UTF-8"?>
<wls:weblogic-ejb-jar xmlns:wls="http://xmlns.oracle.com/weblogic/weblogic-ejb-jar" 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/ejb-jar_3_0.xsd http://xmlns.oracle.com/weblogic/weblogic-ejb-jar http://xmlns.oracle.com/weblogic/weblogic-ejb-jar/1.0/weblogic-ejb-jar.xsd">
  <!--weblogic-version:10.3.2-->
  <weblogic-enterprise-bean>
    <ejb-name>LabAutoODSInterfaceEJB</ejb-name>
    <message-driven-descriptor>
      <destination-jndi-name>jms/Queue-OdsInterfaceMDB</destination-jndi-name>
    </message-driven-descriptor>
  </weblogic-enterprise-bean>
</wls:weblogic-ejb-jar>

Any and all help is appreciated!
0
Comment
Question by:ZBigBeer
4 Comments
 
LVL 10

Expert Comment

by:ECollin
Comment Utility
any stack trace ?
0
 
LVL 19

Expert Comment

by:ramazanyich
Comment Utility
I think you should remove xmlns:ejb attribute from ejb-jar.xml file
0
 
LVL 17

Accepted Solution

by:
sweetfa2 earned 500 total points
Comment Utility
<?xml version="1.0" encoding="UTF-8"?>
<ejb-jar xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:ejb="http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/ejb-jar_3_0.xsd" version="3.0">
  <display-name>LabAutoODSInterfaceEJB</display-name>
  <enterprise-beans>
    <message-driven>
      <ejb-name>LabAutoODSInterfaceEJB</ejb-name>
      <ejb-class>ejbs.ODSInterfaceMDB</ejb-class>
      <transaction-type>Container</transaction-type>
      <message-destination-type>javax.jms.Queue</message-destination-type>
    </message-driven>
  </enterprise-beans>
</ejb-jar>

Open in new window



<?xml version="1.0" encoding="UTF-8"?>
<wls:weblogic-ejb-jar xmlns:wls="http://xmlns.oracle.com/weblogic/weblogic-ejb-jar" 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/ejb-jar_3_0.xsd http://xmlns.oracle.com/weblogic/weblogic-ejb-jar http://xmlns.oracle.com/weblogic/weblogic-ejb-jar/1.0/weblogic-ejb-jar.xsd">
  <!--weblogic-version:10.3.2-->
  
  <wls:weblogic-enterprise-bean>
    <wls:ejb-name>LabAutoODSInterfaceEJB</wls:ejb-name>
    <wls:message-driven-descriptor>
      <wls:destination-jndi-name>jms/Queue-OdsInterfaceMDB</wls:destination-jndi-name>
    </wls:message-driven-descriptor>
  </wls:weblogic-enterprise-bean>
</wls:weblogic-ejb-jar>

Open in new window

0
 

Author Closing Comment

by:ZBigBeer
Comment Utility
Thank you for the solution.  I am sincerely grateful for your help.
0

Featured Post

What Is Threat Intelligence?

Threat intelligence is often discussed, but rarely understood. Starting with a precise definition, along with clear business goals, is essential.

Join & Write a Comment

Verbose logging is used to diagnose garbage collector problems. By default, -verbose:gc output is written to either native_stderr.log or native_stdout.log.   It is also possible to redirect the logs to a user-specified file. This article will de…
This exercise is about for the following scenario: Dmgr and One node with 2 application server. Each application server contains it owns application. Application server name as follows server1 contains app1 server2 contains app1 Prereq…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
Excel styles will make formatting consistent and let you apply and change formatting faster. In this tutorial, you'll learn how to use Excel's built-in styles, how to modify styles, and how to create your own. You'll also learn how to use your custo…

772 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now