Home Answers Viewqa EJB Issue when deploying mdb jar in weblogic

 
 


Tarun
Issue when deploying mdb jar in weblogic
0 Answer(s)      2 months and 24 days ago
Posted in : EJB

Hi,

I have written the code to read messages from queue.But when i deploy this in weblogic 9.2 after creating a jar file it is showing unmarshaller failed Below is the code

MyMdb.java

package com.mdb.ejb;

import javax.ejb.EJBException; import javax.ejb.MessageDrivenBean; import javax.ejb.MessageDrivenContext; import javax.jms.JMSException; import javax.jms.Message; import javax.jms.MessageListener; import javax.jms.TextMessage;

/** * Message-Driven Bean implementation class for: MyMdb * */

public class MyMdb implements javax.ejb.MessageDrivenBean,javax.jms.MessageListener {

/**
 * 
 */
private static final long serialVersionUID = 1L;

/**
 * Default constructor. 
 */
public MyMdb() {
    // TODO Auto-generated constructor stub
}

/**
 * @see MessageListener#onMessage(Message)
 */
public void onMessage(Message message) {
    // TODO Auto-generated method stub
    System.out.println("on two thtr ");
    TextMessage textMessage = (TextMessage) message;

        try {
            System.out.println("\n\n\t(mdb) MyMDB Received \n"+ textMessage.getText());
            SendMail.sendMail(textMessage.getText());
        }
        catch (JMSException e)
        {
            e.printStackTrace();
        }

}

public void ejbRemove() throws EJBException {
    // TODO Auto-generated method stub

}

public void setMessageDrivenContext(MessageDrivenContext arg0)
        throws EJBException {
    // TODO Auto-generated method stub

}

}

ejb-jar.xml

MyMdb com.mdb.ejb.MyMdb Container destinationType javax.jms.Queue isTransacted java.lang.String true
isJmsRedeliveredBroken java.lang.String false
MyMdb onMessage Required

weblogic-ejb-jar.xml

MyMdb 10 10 qjndi cfjndi

It is shwoing below mentioned exception

An error occurred during activation of changes, please see the log for details. ???Exception preparing module: EJBModule(MessageDrivenBeanProject) Unable to deploy EJB: MessageDrivenBeanProject.jar from MessageDrivenBeanProject.jar: There are 2 nested errors: weblogic.ejb.container.compliance.ComplianceException: In EJB MyMdb, the message-driven bean class must implement the javax.ejb.MessageDrivenBean interface. at weblogic.ejb.container.compliance.MessageDrivenBeanClassChecker.checkMessageDrivenImplementsMDB(MessageDrivenBeanClassChecker.java:54) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:592) at weblogic.ejb.container.compliance.EJBComplianceChecker.check(EJBComplianceChecker.java:262) at weblogic.ejb.container.compliance.EJBComplianceChecker.checkDeploymentInfo(EJBComplianceChecker.java:216) at weblogic.ejb.container.ejbc.EJBCompiler.complianceCheckJar(EJBCompiler.java:875) at weblogic.ejb.container.ejbc.EJBCompiler.checkCompliance(EJBCompiler.java:843) at weblogic.ejb.container.ejbc.EJBCompiler.doCompile(EJBCompiler.java:229) at weblogic.ejb.container.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:497) at weblogic.ejb.container.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:464) at weblogic.ejb.container.deployer.EJBDeployer.runEJBC(EJBDeployer.java:432) at weblogic.ejb.container.deployer.EJBDeployer.compileJar(EJBDeployer.java:754) at weblogic.ejb.container.deployer.EJBDeployer.compileIfNecessary(EJBDeployer.java:657) at weblogic.ejb.container.deployer.EJBDeployer.prepare(EJBDeployer.java:1201) at weblogic.ejb.container.deployer.EJBModule.prepare(EJBModule.java:355) at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:93) at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:360) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26) at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:56) at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:46) at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:615) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26) at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:191) at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:147) at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:61) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.createAndPrepareContainer(ActivateOperation.java:189) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doPrepare(ActivateOperation.java:87) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.prepare(AbstractOperation.java:217) at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentPrepare(DeploymentManager.java:718) at weblogic.deploy.internal.targetserver.DeploymentManager.prepareDeploymentList(DeploymentManager.java:1185) at weblogic.deploy.internal.targetserver.DeploymentManager.handlePrepare(DeploymentManager.java:247) at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.prepare(DeploymentServiceDispatcher.java:157) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doPrepareCallback(DeploymentReceiverCallbackDeliverer.java:157) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$000(DeploymentReceiverCallbackDeliverer.java:12) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$1.run(DeploymentReceiverCallbackDeliverer.java:45) at weblogic.work.ServerWorkManagerImpl$WorkAdapterImpl.run(ServerWorkManagerImpl.java:518) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209) at weblogic.work.ExecuteThread.run(ExecuteThread.java:181) and weblogic.ejb.container.compliance.ComplianceException: In EJB MyMdb, a Message-driven EJB must define an ejbCreate method that takes no parameters. at weblogic.ejb.container.compliance.MessageDrivenBeanClassChecker.checkEjbCreateMethod(MessageDrivenBeanClassChecker.java:401) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:592) at weblogic.ejb.container.compliance.EJBComplianceChecker.check(EJBComplianceChecker.java:262) at weblogic.ejb.container.compliance.EJBComplianceChecker.checkDeploymentInfo(EJBComplianceChecker.java:216) at weblogic.ejb.container.ejbc.EJBCompiler.complianceCheckJar(EJBCompiler.java:875) at weblogic.ejb.container.ejbc.EJBCompiler.checkCompliance(EJBCompiler.java:843) at weblogic.ejb.container.ejbc.EJBCompiler.doCompile(EJBCompiler.java:229) at weblogic.ejb.container.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:497) at weblogic.ejb.container.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:464) at weblogic.ejb.container.deployer.EJBDeployer.runEJBC(EJBDeployer.java:432) at weblogic.ejb.container.deployer.EJBDeployer.compileJar(EJBDeployer.java:754) at weblogic.ejb.container.deployer.EJBDeployer.compileIfNecessary(EJBDeployer.java:657) at weblogic.ejb.container.deployer.EJBDeployer.prepare(EJBDeployer.java:1201) at weblogic.ejb.container.deployer.EJBModule.prepare(EJBModule.java:355) at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:93) at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:360) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26) at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:56) at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:46) at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:615) at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26) at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:191) at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:147) at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:61) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.createAndPrepareContainer(ActivateOperation.java:189) at weblogic.deploy.internal.targetserver.operations.ActivateOperation.doPrepare(ActivateOperation.java:87) at weblogic.deploy.internal.targetserver.operations.AbstractOperation.prepare(AbstractOperation.java:217) at weblogic.deploy.internal.targetserver.DeploymentManager.handleDeploymentPrepare(DeploymentManager.java:718) at weblogic.deploy.internal.targetserver.DeploymentManager.prepareDeploymentList(DeploymentManager.java:1185) at weblogic.deploy.internal.targetserver.DeploymentManager.handlePrepare(DeploymentManager.java:247) at weblogic.deploy.internal.targetserver.DeploymentServiceDispatcher.prepare(DeploymentServiceDispatcher.java:157) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.doPrepareCallback(DeploymentReceiverCallbackDeliverer.java:157) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer.access$000(DeploymentReceiverCallbackDeliverer.java:12) at weblogic.deploy.service.internal.targetserver.DeploymentReceiverCallbackDeliverer$1.run(DeploymentReceiverCallbackDeliverer.java:45) at weblogic.work.ServerWorkManagerImpl$WorkAdapterImpl.run(ServerWorkManagerImpl.java:518) at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209) at weblogic.work.ExecuteThread.run(ExecuteThread.java:181) ??? ??? There are 2 nested errors: weblogic.ejb.container.compliance.ComplianceException: In EJB MyMdb, the message-driven bean class must implement the javax.ejb.MessageDrivenBean interface. ???

View Answers









Related Pages:
Issue when deploying mdb jar in weblogic
Issue when deploying mdb jar in weblogic  Hi, I have written the code to read messages from queue.But when i deploy this in weblogic 9.2 after creating a jar file it is showing unmarshaller failed Below is the code MyMdb.java
Deploying Servlet in Weblogic 9.2 - Servlet Interview Questions
Deploying Servlet in Weblogic 9.2  Hi Friends, I am new to web application, can u explain briefly wat is "Deploying a .war,.jar,.ear files... configuration of the hosting server application. When the server encounters a particular
DEVELOPING & DEPLOYING A PACKAGED EJB
<?xml version="1.0" ?> <!DOCTYPE weblogic-ejb-jar PUBLIC '-//BEA...' ----------------------------------------------------------------------- Now, we copy the jar file to the WebLogic folder...\mydomain\applications Start the weblogic server and the jar will be deployed
Deploying Servlet in Weblogic 9.2 - Servlet Interview Questions
Deploying Servlet in Weblogic 9.2   Hi Friend thanks in advance, can u give me steps for deploying servlet using weblogic server 9.2
Tomcat jar file issue - JSP-Servlet
Tomcat jar file issue  Hello All, Currently in my application we... folder from JRUN server to Tomcat 6.0.29 webapps folder. When our GUI code... of experience before ?Appreciate your help in this issue. Thanks in Advance
Deploying Weblogic Server in MyEclipseBlue6.6 - IDE Questions
Deploying Weblogic Server in MyEclipseBlue6.6  Hi I am facing some problem in deploying "weblogicserver8.1" in my "MyEclipseBlue6.6".Please provide me detailed path of BEA home directory, Web logic Installation directory
I got build failed when deploying enterprise application - EJB
I got build failed when deploying enterprise application  I created...-user: init-project: do-init: post-init: init-check: init: deps-jar: deps-j2ee-archive: init: deps-module-jar: deps-ear-jar: init: deps-jar: compile
Deploying and testing Stateless Session Bean
="${deploymentdescription}/jar/"   includes="ejb-jar.xml,weblogic-cmp-rdbms...Deploying and testing Stateless Session Bean... ear file. We will deploy our application using WebLogic console. Building ear
Issue in Converting .zip file to .jar file?
Issue in Converting .zip file to .jar file?  I have a folder called "printpdf.jar". I have changed the .jar to .zip and did some customizations. After which i had "zipped" it again and made as ".jar". Now the final file
servlet with weblogic
servlet with weblogic  hi everyone.... When I'm running this program on weblogic server8.1 import java.io.*; import java.sql.*; import javax.servlet.*; import javax.servlet.http.*; class DataInsertion extends HttpServlet
DEVELOPING & DEPLOYING A PACKAGED EJB (WEBLOGIC-7) & ACCESSING IT BY A PACKAGED SERVLET (TOMCAT4.1) 
<?xml version="1.0" ?> <!DOCTYPE weblogic-ejb-jar PUBLIC '-//BEA...' ----------------------------------------------------------------------- Now, we copy the jar file to the WebLogic folder...\mydomain\applications Start the weblogic server and the jar will be deployed
Reading a file from Jar JAVA
Reading a file from Jar JAVA  I have added one excel sheet into a jar file. can anybody tell me how i can read that file. actually when i am running code from eclipse i able to read it but when i am adding that jar file
Reading a file from Jar JAVA
Reading a file from Jar JAVA  I have added one excel sheet into a jar file. can anybody tell me how i can read that file. actually when i am running code from eclipse i able to read it but when i am adding that jar file
JTABLE Issue
to go back for another search. Now issue is -- when I put some input data... to customer name. But when I click on Back button and provide some other name
how can i export a .jar file include .mbd file?
how can i export a .jar file include .mbd file?  i have a project of java.it includes a .mdb file, when i export to .jar file i eclipse, it show a error that can't export .jar file width the .mdb file ? how can i import this .mdb
dialogbox issue
dialogbox issue  in my application,when i click on button it is showing dialobBox ,for this i added one action listenr.it is working fine.but...,the dialogBox is still opening.and when i clickedon any region of applocation
javascript issue
javascript issue  hi, i have an xml file which have country name and there browsers name list so now in 1st dropdown list country name should print and when we select country corresponding to that in 2nd dropdown list browsers
Cascade Issue
; FKstuff), stuff. When I don't use cascading, I get an error: "Cannot add.... I need some sort of cascading. It works when I add cascading in the set property..., even when the other part of the PK is not thesame user. So basicly the previous
HTML ISSUE
HTML ISSUE  Hi, We have a requirement wherein we have to access a link generated using html tag 'href' ie: This href value is fetched from sum table in other schema. When we click this link, username n password pop-up
Related to weblogic server8.1
Related to weblogic server8.1  hi Everybody, i have write a simple servlet program and deploy on weblogic8.1 server. when I'm running this app. when I'm testing this app. this error is occurred. Error 500--Internal Server Error
Building Web Application With Ant and Deploying on Jboss 3.0
Building Web Application With Ant and Deploying on Jboss 3.0... and .jar files   Meta-inf      ...,.jar and application.xml file are packaged in the above format. Enterprise
Deployment Steps in Weblogic Server - Development process
Deployment Steps in Weblogic Server  Hi Friends, Can anyone give me steps for Deploying application in web logic server ( both versions 8.1 and 9.2 ) with Eclipse IDE
Runnable JAR
Runnable JAR  How to create runnable JAR file in eclipse ? Please provide me step by step demo... I am windows 7 user. I have made one jar file but when I double click it,it doesn't run. Why so
Runnable JAR
Runnable JAR  How to create runnable JAR file in eclipse ? Please provide me step by step demo... I am windows 7 user. I have made one jar file but when I double click it,it doesn't run. Why so
MDB - EJB
MDB  Hi All, can we make MDB is Synchronous ??? if yes then how????  Hi friend, i am sending simple code. Actually MDBs only live in an EJB server - all the Swing code you've supplied is not MDB, its regular JMS
Wats Deploying war in Target Server - Development process
Wats Deploying war in Target Server   Hi Friends, I am new to web application, can u explain briefly wat is "Deploying a .war,.jar,.ear files in target server. Thank u in advance   Hi rajendra
Workshop for WebLogic 10.1
Workshop for WebLogic 10.1       BEA Workshop for WebLogic 10.1 offers nothing less than the #1 Commercial Eclipse-based IDE for BEA WebLogic Service-Oriented
Resultset Issue in SQL
Resultset Issue in SQL  when i call rs.next() in my code it is returning false, though im having valid query to execute and fetch a row from database.how can i resolve this issue. My code is: SELECT JOBDESCRIPTION,CATEGORY
Tomcat start up issue: SEVERE: Error listenerStart - IDE Questions
Tomcat start up issue: SEVERE: Error listenerStart   Hi When I... the following issue and I am not able to access my application. SEVERE: Error... me which jars we have to add to to solve listenerStart Error .Give me the jar
Issue in JSF and Richfaces.
Issue in JSF and Richfaces.  Hi,I am with a issue in JSF... the fields.And again when i put my cursor at firstname field and press"Tab" and when it comes to Secretid field it will be validating tat field and rest
maven subversion issue
maven subversion issue   m doing work on maven and subversion i have...+in+Subversion but by following this site when i have added scm and tag base like scm:svn... org.apache.maven.plugins maven-release-plugin svn+ssh://file:///E:/my-app-reposs then when
JavaFX issue - Java3D
the application from Netbeans. But if I run the jar file as a standalone
EJB-MDB - EJB
EJB-MDB  What are the MDB transaction attributes
Struts 2 issue
Struts 2 issue  hi, I have one jsp page and having one hidden field methodName and when we submit request we get value in action class and again i... to same action now problem is when we submit request first time e.g value
maven subversion issue
but by following this site when i have added scm and tag base like scm:svn:svn... org.apache.maven.plugins maven-release-plugin svn+ssh://file:///E:/my-app-reposs then when i m
Deploying Struts and testing struts 2 hello world application
Deploying Struts and testing struts 2 hello world application   ...;struts2helloworld\WEB-INF\src" directory of the web application and issue... and create jar file "struts2tutorial.jar" into the lib directory of your web
Error with Maven while deploying the war file
Error with Maven while deploying the war file  Hi, I am new to maven... I created java spring hibernate project.. and i kept all .java files... com.mindtree.entity Simple jar 1.0-SNAPSHOT Simple java.net
jar file - Java Beginners
jar file  jar file When creating a jar file it requires a manifest... options in jar file. What is Jar File? JAR files are packaged in the zip format  What is Jar File?JAR files are packaged in the zip format making
Error with Maven while deploying the war file
Error with Maven while deploying the war file  Hi, I am new...;jar-with-dependencies</descriptorRef> <...; </build> </project> But after deploying that i got this error
Creating an executable jar file
Creating an executable jar file  When I try to create jar.exe through CMD, the manifest file created doesn't contain Main-Class attribute, even though it is included in text file used during creation of jar file
Copy .mdb file for backup.
Copy .mdb file for backup.  hi.. i am new to java... in my application , at one place for taking back up i have to copy .mdb file from one place to another ... please can anyone help me, how can i do that ....and also if possible
Jar file - Java Beginners
Jar file  Hello this is my second question and i hope atleast i will get answer i bulid a jar file of my project using netbeans but now problem is when i open that jar file in command prompt i got error exception in thread
jms to mdb - JMS
jms to mdb  how to invoke MDB from JMS? is there any server configuration file?  Hi Friend, Please visit the following link: http://www.roseindia.net/ejb/MessageDrivenBeans.shtml http://www.roseindia.net/ejb
How to solve concurrency issue when an application is running on two machine to fetch record from one database
How to solve concurrency issue when an application is running on two machine to fetch record from one database  I have developed an application... it. I want to make sure that when application run on two machine
creating JAR - Java Beginners
installed SQL and Tomcat.I created a JAR of my java project and included... and tried to update the library of the web project.Unfortunately, when i add the new JAR to the lib, the WEBAPPlication libraries doesnot reflect the new class added
Java Calendar issue - Date Calendar
Singapore time zone When i send the element from client to server my cal obj works... to client to display time in Singapore timezone Here is the issue my Calendar Obj
Error 500-Server are not find the jar file in the program of upload the file - JSP-Servlet
Error 500-Server are not find the jar file in the program of upload... the issue is not yours to troubleshoot or resolve, there are a few things you can do... of the most common error message seen when checking out during an online
UNICODE or SQL statement issue - JDBC
with having ASCII and other With UNICODE 1] when i trying to pass parameter...] when trying to pass parameter ASCII and fetches UNICODE it retrieves only.... to me their is problem in SENDING and Retrieving the database bcz when trying
back button issue - Java Beginners
back button issue  Hello, I have a site that asks for user and password to connect it. When the user pushs de LogOut button and later another user pushs the back button of the explorator he can entry in the page of first user

Ask Questions?

If you are facing any programming issue, such as compilation errors or not able to find the code you are looking for.

Ask your questions, our development team will try to give answers to your questions.