About weblogic.ejb.utils.DDCreator
Hello,
I had a problem deploying EJB using VisualAge 3.5 and Integration Kit.
Using "Generating EJB jar", VisualAge shows a exception
"NoDefClassNotFound weblogic.ejb.utils.DDCreator"
What can i do ?
Regards
[email protected]
Do you have an access to source code of your EJBes?
If you do, compose a deployment descriptor manually,
it's not that hard.
Regards,
Slava Imeshev
"alien5415" <[email protected]> wrote in message
news:3c1d841c$[email protected]..
>
Dear sir:
thank you for reply.and there's a new question,would you please helpme:
when execute "java weblogic.ejb20.utils.DDConverter -d .DeploymentDescriptor.txt",
i got such err "ERROR: There was an error reading"DeploymentDescriptor.txt".
The input file has to be a WLS 4.5 deployment descriptor text file or WLS5.1
jar file." it seemd that the txt file format not correct.
what should i do to fix it.follwing is the fileDeploymentDescriptor.txt(it's
sun's sample.):
(SessionDescriptor
; This file must start with SessionDescriptor or EntityDescriptor
;Indicate the name which the bean will be bound into the JNDI name as
beanHomeName demo.DemoHome
; The enterprise Java Bean class (see step #4)
enterpriseBeanClassName ejb.demo.DemoBean
homeInterfaceClassName ejb.demo.DemoHome
; The home interface implemented by a class generated by the container
; provided tools see step #3
remoteInterfaceClassName ejb.demo.Demo
; See step #2
isReentrant false
; Always false for session beans
stateManagementType STATELESS_SESSION
; Either STATELESS_SESSION or STATEFUL_SESSION.
; DemoBean is a stateless session bean
sessionTimeout 5; seconds
(controlDescriptors
; This section decides the run-time properties when a method is called.
; The DEFAULT sub-section applies to all methods, but can be overridden
; on a per-method basis, similar to the "accessControlEntries" above.
(DEFAULT
isolationLevel TRANSACTION_SERIALIZABLE
transactionAttribute TX_REQUIRED
runAsMode CLIENT_IDENTITY
); end isolationLevel
); end controlDescriptors
(environmentProperties
maxBeansInFreePool 100
); end environmentProperties
); end SessionDescriptor
thank you very much
Similar Messages
-
Weblogic.ejb.utils.DDCreator
does anyone know where does weblogic.ejb.utils.DDCreator locate.
i installed weblogic6.0 on redhat7.1.
i cann't find it in any jar under /lib.
thanks a lot!Do you have an access to source code of your EJBes?
If you do, compose a deployment descriptor manually,
it's not that hard.
Regards,
Slava Imeshev
"alien5415" <[email protected]> wrote in message
news:3c1d841c$[email protected]..
>
Dear sir:
thank you for reply.and there's a new question,would you please helpme:
when execute "java weblogic.ejb20.utils.DDConverter -d .DeploymentDescriptor.txt",
i got such err "ERROR: There was an error reading"DeploymentDescriptor.txt".
The input file has to be a WLS 4.5 deployment descriptor text file or WLS5.1
jar file." it seemd that the txt file format not correct.
what should i do to fix it.follwing is the fileDeploymentDescriptor.txt(it's
sun's sample.):
(SessionDescriptor
; This file must start with SessionDescriptor or EntityDescriptor
;Indicate the name which the bean will be bound into the JNDI name as
beanHomeName demo.DemoHome
; The enterprise Java Bean class (see step #4)
enterpriseBeanClassName ejb.demo.DemoBean
homeInterfaceClassName ejb.demo.DemoHome
; The home interface implemented by a class generated by the container
; provided tools see step #3
remoteInterfaceClassName ejb.demo.Demo
; See step #2
isReentrant false
; Always false for session beans
stateManagementType STATELESS_SESSION
; Either STATELESS_SESSION or STATEFUL_SESSION.
; DemoBean is a stateless session bean
sessionTimeout 5; seconds
(controlDescriptors
; This section decides the run-time properties when a method is called.
; The DEFAULT sub-section applies to all methods, but can be overridden
; on a per-method basis, similar to the "accessControlEntries" above.
(DEFAULT
isolationLevel TRANSACTION_SERIALIZABLE
transactionAttribute TX_REQUIRED
runAsMode CLIENT_IDENTITY
); end isolationLevel
); end controlDescriptors
(environmentProperties
maxBeansInFreePool 100
); end environmentProperties
); end SessionDescriptor
thank you very much -
Question about weblogic.ejb20.utils.DDConverter
Hello.
I have convert DD using weblogic.ejb20.utils.DDConverter.
But error happens.
D:\>java weblogic.ejb20.utils.DDConverter -EJBVer 2.0 -d . forex_tr.jar
new.jar
DDConverter starting at 2002-02-21 ¿ÀÈÄ 4:35:26...
Source file list:
forex_tr.jar
new.jar
Output directory: .
Converting forex_tr.jar ...
DDConverter failed due to an unexpected Exception. The stack trace is:
java.lang.ClassCastException:
weblogic.management.descriptors.cmp20.WeblogicRDB
MSBeanMBeanImpl
at
weblogic.ejb20.utils.ddconverter.DDConverterBase.convertBeansTo20(DDC
onverterBase.java:284)
at
weblogic.ejb20.utils.ddconverter.DDConverterBase.convertTo20(DDConver
terBase.java:235)
at
weblogic.ejb20.utils.ddconverter.DDConverter_1120.convert(DDConverter
_1120.java:88)
at weblogic.ejb20.utils.DDConverter.main(DDConverter.java:155)
DDConverter was unable to convert all the input beans due to conversion
errors.
See "ddconverter.log" for details.
Bye.
Hyun Min.It's my mistake.
I not used -c option.
java weblogic.ejb20.utils.DDConverter -EJBVer 2.0 -d . -c new.jar
forex_tr.jar
"Hyun Min" <[email protected]> wrote in message
news:[email protected]..
Hello.
I have convert DD using weblogic.ejb20.utils.DDConverter.
But error happens.
D:\>java weblogic.ejb20.utils.DDConverter -EJBVer 2.0 -d . forex_tr.jar
new.jar
DDConverter starting at 2002-02-21 ¿ÀÈÄ 4:35:26...
Source file list:
forex_tr.jar
new.jar
Output directory: .
Converting forex_tr.jar ...
DDConverter failed due to an unexpected Exception. The stack trace is:
java.lang.ClassCastException:
weblogic.management.descriptors.cmp20.WeblogicRDB
MSBeanMBeanImpl
at
weblogic.ejb20.utils.ddconverter.DDConverterBase.convertBeansTo20(DDC
onverterBase.java:284)
at
weblogic.ejb20.utils.ddconverter.DDConverterBase.convertTo20(DDConver
terBase.java:235)
at
weblogic.ejb20.utils.ddconverter.DDConverter_1120.convert(DDConverter
_1120.java:88)
at weblogic.ejb20.utils.DDConverter.main(DDConverter.java:155)
DDConverter was unable to convert all the input beans due to conversion
errors.
See "ddconverter.log" for details.
Bye.
Hyun Min. -
Invalid weblogic-ejb-jar.xml ??
I have a question about weblogic-ejb-jar.xml file entries.
weblogic 9.1 server says it is invalid while deploying my file
my file is as under,
<?xml version="1.0"?><!DOCTYPE weblogic-ejb-jar PUBLIC '-//BEA Systems,
Inc.//DTD WebLogic 8.1.0 EJB//EN'
'http://www.bea.com/servers/wls810/dtd/weblogic-ejb-jar.dtd'>
<weblogic-ejb-jar xmlns="http://www.bea.com/ns/weblogic/910"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.bea.com/ns/weblogic/910
http://www.bea.com/ns/weblogic/910/weblogic-ejb-jar.xsd">
<weblogic-enterprise-bean>
<ejb-name>MessageAccess</ejb-name>
<message-driven-descriptor>
<resource-adapter-jndi-name>SystemModule-test</resource-adapter-jndi-name>
</message-driven-descriptor>
</weblogic-enterprise-bean>
</weblogic-ejb-jar>
can anybody help what is wrong with it?I used Korean language in comment.
But the charset of XML was iso-8859-1.
Sorry.
"mariah" <[email protected]> wrote:
>
Hi, I am migrating to WebLogic Server 6.1 from 5.1.
And for the weblogic-ejb-jar.xml,
the following error occurs:
ERROR: Error parsing 'META-INF/weblogic-ejb-jar.xml' line 14: An invalid
XML character
(Unicode: 0xb8) was found in the comment.
ERROR: ejbc found errors
The errorneous line is the following comment. (it's fine in 5.1)
<!-- if false, ... -->
Must I remove this comment?
Thanks in advance. -
How can I fix the problem like this?( in JBuilder6+Weblogic+ejb)
"Cabin.ejbgrpx": D:\JBuilder6\jdk1.3.1\bin\javaw -classpath "D:\java_code\jb6\MyFirstEJB\classes;D:\bea\weblogic700\server\lib\weblogic_sp.jar;D:\bea\weblogic700\server\lib\weblogic.jar;D:\JBuilder6\lib\jbuilder.jar;D:\JBuilder6\lib\help.jar;D:\JBuilder6\lib\gnuregexp.jar;D:\JBuilder6\jdk1.3.1\demo\jfc\Java2D\Java2Demo.jar;D:\JBuilder6\jdk1.3.1\jre\lib\i18n.jar;D:\JBuilder6\jdk1.3.1\jre\lib\jaws.jar;D:\JBuilder6\jdk1.3.1\jre\lib\rt.jar;D:\JBuilder6\jdk1.3.1\jre\lib\sunrsasign.jar;D:\JBuilder6\jdk1.3.1\lib\dt.jar;D:\JBuilder6\jdk1.3.1\lib\htmlconverter.jar;D:\JBuilder6\jdk1.3.1\lib\tools.jar;D:\JBuilder6\jdk1.3.1\lib\ejb.jar;D:\JBuilder6\jdk1.3.1\lib\tools.jar;D:\JBuilder6\patch\jb6_all_001.jar;D:\JBuilder6\lib\activation.jar;D:\JBuilder6\lib\beandt.jar;D:\JBuilder6\lib\borlandxml.jar;D:\JBuilder6\lib\castor-xml.jar;D:\JBuilder6\lib\castor.jar;D:\JBuilder6\lib\cx.jar;D:\JBuilder6\lib\dbswing.jar;D:\JBuilder6\lib\dbswingdt.jar;D:\JBuilder6\lib\dbtools.jar;D:\JBuilder6\lib\dt.jar;D:\JBuilder6\lib\dx.jar;D:\JBuilder6\lib\gnuregexp.jar;D:\JBuilder6\lib\help.jar;D:\JBuilder6\lib\iastools.jar;D:\JBuilder6\lib\ias_common.jar;D:\JBuilder6\lib\internetbeans.jar;D:\JBuilder6\lib\jakarta-regexp-1.1.jar;D:\JBuilder6\lib\javaws.jar;D:\JBuilder6\lib\jbcl.jar;D:\JBuilder6\lib\jbuilder.jar;D:\JBuilder6\lib\jdbcx.jar;D:\JBuilder6\lib\jdom.jar;D:\JBuilder6\lib\jds.jar;D:\JBuilder6\lib\jdsremote.jar;D:\JBuilder6\lib\jdsserver.jar;D:\JBuilder6\lib\junit.jar;D:\JBuilder6\lib\mail.jar;D:\JBuilder6\lib\sqltools.jar;D:\JBuilder6\lib\unittest.jar;D:\JBuilder6\lib\webserverglue.jar;D:\JBuilder6\lib\xalan.jar;D:\JBuilder6\lib\xerces.jar;D:\JBuilder6\lib\xml4j.jar;D:\JBuilder6\lib\xmlbeans.jar;D:\JBuilder6\lib\xmldbms.jar;D:\JBuilder6\lib\bes\agentclient.jar;D:\JBuilder6\lib\bes\asrt.jar;D:\JBuilder6\lib\bes\client.jar;D:\JBuilder6\lib\bes\guicore.jar;D:\JBuilder6\lib\bes\jaas.jar;D:\JBuilder6\lib\bes\jcert.jar;D:\JBuilder6\lib\bes\jnet.jar;D:\JBuilder6\lib\bes\jsse.jar;D:\JBuilder6\lib\bes\lm.jar;D:\JBuilder6\lib\bes\vbdev.jar;D:\JBuilder6\lib\bes\vbejb.jar;D:\JBuilder6\lib\bes\vbjdev.jar;D:\JBuilder6\lib\bes\vbjorb.jar;D:\JBuilder6\lib\bes\vbsec.jar;D:\JBuilder6\lib\bes\xmlrt.jar"
weblogic.ejbc -keepgenerated -compiler D:/JBuilder6/bin/bcjW D:/java_code/jb6/MyFirstEJB/Cabin.jar.jar
D:/java_code/jb6/MyFirstEJB/Cabin.jar
"Cabin.ejbgrpx": Spaces in the temporary directory path may cause WebLogic EJBC utility
to produce fatal compile errors.
"Cabin.ejbgrpx": <2002-5-30 下午11时32分20秒> <Warning>
<EJB> <010054> <EJB Deployment: CabinBean has a class com.titan.cabin.CabinBean which
is in the classpath. This class should only be located in the ejb-jar file.>
"Cabin.ejbgrpx": <2002-5-30 下午11时32分20秒> <Warning>
<EJB> <010054> <EJB Deployment: CabinBean has a class com.titan.cabin.CabinHome which
is in the classpath. This class should only be located in the ejb-jar file.>
"Cabin.ejbgrpx": <2002-5-30 下午11时32分20秒> <Warning>
<EJB> <010054> <EJB Deployment: CabinBean has a class com.titan.cabin.Cabin which
is in the classpath. This class should only be located in the ejb-jar file.>
"Cabin.ejbgrpx": <2002-5-30 下午11时32分20秒> <Warning>
<EJB> <010054> <EJB Deployment: CabinBean has a class com.titan.cabin.CabinPK which
is in the classpath. This class should only be located in the ejb-jar file.>
"Cabin.ejbgrpx": ERROR: The classes which ejbc generated from your home and remote
interfaces cannot be loaded. Please ensure that you have set the -d option to a
writeable directory.
"Cabin.ejbgrpx": ERROR: ejbc found errorsiTunes error 54
-
Failed to load weblogic-ejb-jar.xml
Hi,
I try to deploy an EJB on Weblogic 9.1, but the weblogic-ejb-jar seems to cause this exception :
======================================================
[wlappc] <30 oct. 2006 12 h 13 CET> <Error> <J2EE> <BEA-160187> <weblogic.appc failed to compile your application. Recompile with the -verbose option for more details. Please see the error message(s) below.>
[wlappc] com.bea.xml.XmlException: failed to load java type corresponding to e=weblogic-ejb-jar@http://www.bea.com/ns/weblogic/910
[wlappc] at com.bea.staxb.runtime.internal.UnmarshalResult.getPojoBindingType(UnmarshalResult.java:325)
[wlappc] at com.bea.staxb.runtime.internal.UnmarshalResult.determineTypeForGlobalElement(UnmarshalResult.java:292)
[wlappc] at com.bea.staxb.runtime.internal.UnmarshalResult.determineTypeForGlobalElement(UnmarshalResult.java:302)
[wlappc] at com.bea.staxb.runtime.internal.UnmarshalResult.determineRootType(UnmarshalResult.java:283)
[wlappc] at com.bea.staxb.runtime.internal.UnmarshalResult.unmarshalDocument(UnmarshalResult.java:153)
[wlappc] at com.bea.staxb.runtime.internal.UnmarshallerImpl.unmarshal(UnmarshallerImpl.java:65)
[wlappc] at weblogic.descriptor.internal.MarshallerFactory$1.createDescriptor(MarshallerFactory.java:138)
[wlappc] at weblogic.descriptor.DescriptorManager.createDescriptor(DescriptorManager.java:271)
[wlappc] at weblogic.descriptor.DescriptorManager.createDescriptor(DescriptorManager.java:240)
[wlappc] at weblogic.descriptor.DescriptorManager.createDescriptor(DescriptorManager.java:300)
[wlappc] at weblogic.application.descriptor.AbstractDescriptorLoader.createDescriptor(AbstractDescriptorLoader.java:344)
[wlappc] at weblogic.application.descriptor.CachingDescriptorLoader.createDescriptor(CachingDescriptorLoader.java:188)
[wlappc] at weblogic.application.descriptor.AbstractDescriptorLoader.createDescriptor(AbstractDescriptorLoader.java:328)
[wlappc] at weblogic.application.descriptor.AbstractDescriptorLoader.getDescriptor(AbstractDescriptorLoader.java:237)
[wlappc] at weblogic.application.descriptor.AbstractDescriptorLoader.getRootDescriptorBean(AbstractDescriptorLoader.java:217)
[wlappc] at weblogic.ejb.spi.EjbJarDescriptor.parseWeblogicEjbJarBean(EjbJarDescriptor.java:171)
[wlappc] at weblogic.ejb.container.dd.xml.DDUtils.processWLEjbJarXMLWithSchema(DDUtils.java:706)
[wlappc] at weblogic.ejb.container.dd.xml.DDUtils.parseWLDD(DDUtils.java:535)
[wlappc] at weblogic.ejb.container.dd.xml.DDUtils.createDescriptorFromJarFile(DDUtils.java:358)
[wlappc] at weblogic.ejb.container.dd.xml.DDUtils.createReadOnlyDescriptorFromJarFile(DDUtils.java:141)
[wlappc] at weblogic.ejb.container.ejbc.EJBCompiler.parseDescriptors(EJBCompiler.java:1345)
[wlappc] at weblogic.ejb.container.ejbc.EJBCompiler.compileEJB(EJBCompiler.java:431)
[wlappc] at weblogic.application.compiler.AppcUtils.compileEJB(AppcUtils.java:292)
[wlappc] at weblogic.application.compiler.EJBCompiler.compile(EJBCompiler.java:95)
[wlappc] at weblogic.application.compiler.flow.AppCompilerFlow.compileInput(AppCompilerFlow.java:113)
[wlappc] at weblogic.application.compiler.flow.AppCompilerFlow.compile(AppCompilerFlow.java:43)
[wlappc] at weblogic.application.compiler.FlowDriver$FlowStateChange.next(FlowDriver.java:55)
[wlappc] at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:26)
[wlappc] at weblogic.application.compiler.FlowDriver.run(FlowDriver.java:24)
[wlappc] at weblogic.application.compiler.Appc.runBody(Appc.java:151)
[wlappc] at weblogic.utils.compiler.Tool.run(Tool.java:158)
[wlappc] at weblogic.utils.compiler.Tool.run(Tool.java:115)
======================================================
Here is my weblogic-ejb-jar.xml file :
======================================================
<?xml version="1.0" encoding="ISO-8859-1"?>
<weblogic-ejb-jar xmlns="http://www.bea.com/ns/weblogic/910"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.bea.com/ns/weblogic/910
http://www.bea.com/ns/weblogic/910/weblogic-ejb-jar.xsd">
<weblogic-enterprise-bean>
<ejb-name>MyMDB</ejb-name>
<message-driven-descriptor>
<resource-adapter-jndi-name>ActiveMQRA</resource-adapter-jndi-name>
<connection-factory-jndi-name>myQCF</connection-factory-jndi-name>
</message-driven-descriptor>
<resource-description>
<res-ref-name>jms/factory</res-ref-name>
<jndi-name>myQCF</jndi-name>
</resource-description>
<resource-env-description>
<resource-env-ref-name>jms/queue</resource-env-ref-name>
<jndi-name>queue.out</jndi-name>
</resource-env-description>
</weblogic-enterprise-bean>
</weblogic-ejb-jar>
======================================================
So, it looks like this problem : http://forums.bea.com/bea/message.jspa?messageID=600018030&tstart=0
I just need a confirmation :
- is the "res-ref-name" format incorrect with '/' character ?
- is the jndi-name format incorrect with '.' character ?
Else, what is the problem with this DD ?
Thanks,
Rudy"shubha" <[email protected]> wrote:
>
hi ,
Ejb with ejb-name 'hellobean' in ejb-jar.xml
should be specified in weblogic-ejb-jar.xml with <weblogic-enterprise-bean></weblogic-enterprise-bean>
i am having problem in deploying the most simple bean on wls7.0 .
when i try to open the bean module with the weblogic builder i get the
following
message
weblogic.ejb20.WLDeploymentException: Could not locate bean with ejb-name
'hellobean'
in weblogic-ejb-jar.xml
at weblogic.ejb20.deployer.CompositeMBeanDescriptor.initialize60(CompositeMBeanDescriptor.java:249)
at weblogic.ejb20.deployer.CompositeMBeanDescriptor.init(CompositeMBeanDescriptor.java:180)
at weblogic.ejb20.deployer.CompositeMBeanDescriptor.<init>(CompositeMBeanDescriptor.java:171)
at weblogic.marathon.model.EJBJarCMBean.setup(EJBJarCMBean.java:408)
at weblogic.marathon.tasks.OpenModuleTask.figureOutModule(OpenModuleTask.java:76)
at weblogic.marathon.tasks.OpenModuleTask.figureOutModule(OpenModuleTask.java:109)
at weblogic.marathon.tasks.OpenModuleTask.runBackground(OpenModuleTask.java:64)
at weblogic.jellybeans.core.task.TaskThread.execute(TaskThread.java:114)
at weblogic.jellybeans.core.task.TaskThread.run(TaskThread.java:55)
Could not locate bean with ejb-name 'hellobean' in weblogic-ejb-jar.xml
Module hello1 descriptors failed to load
if anyone has come across the same problem and have debugged it please
help me
out
thanks in advance -
Help: I'm sure it is a Bug in JNI calling WebLogic EJB
Help me! I'm using jni to call weblogic EJB from a Com+ component,here is the code:
// This is the main project file for VC++ application project
// generated using an Application Wizard.
#include "stdafx.h"
#pragma unmanaged
#include <windows.h>
#include <jni.h>
#include <process.h>
#include <stdio.h>
#define USER_CLASSPATH "C:\\myClasses;C:\\j2sdk1.4.0\\lib\\tools.jar;Z:\\wlserver6.1\\lib\\weblogic.jar;"
/* where Prog.class is */
JavaVM *jvm;
* Function GetJNIEnv(void) returns the java environment pointer
* in case we are executing on a thread other than the one the
* jvm was created on.
JNIEnv* GetJNIEnv(void){
JNIEnv *env = NULL;
jint nRet = jvm->GetEnv((void **)&env, JNI_VERSION_1_2);
if(nRet == JNI_EDETACHED){
jvm->AttachCurrentThread((void **)&env, NULL);
return env;
* Function DoJNDI(void *arg) uses the Java Invocation API to
* execute the following Java code:
* Hashtable prop = new Hashtable();
* prop.put(Context.INITIAL_CONTEXT_FACTORY, "weblogic.jndi.WLInitialContextFactory"
* prop.put( Context.PROVIDER_URL, "t3://192.168.40.137:7001" );
* ctxInitial = new InitialDirContext( prop );
void DoJNDI(void *arg){
jclass clsHash, clsInitDirCx;
jmethodID mHashInit, mHashPut, mInitDirCxInit;
jobject objHash, objInitDirCx;
JNIEnv *env = GetJNIEnv(); // Get the environment if on a different thread
clsHash = env->FindClass("java/util/Hashtable");
mHashInit = env->GetMethodID(clsHash, "<init>", "()V");
objHash = env->NewObject(clsHash, mHashInit);
mHashPut = env->GetMethodID(clsHash, "put", "(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;");
jstring jstrICxFactoryPut = env->NewStringUTF("java.naming.factory.initial");
jstring jstrICxFactoryVal = env->NewStringUTF("weblogic.jndi.WLInitialContextFactory");
env->CallObjectMethod(objHash, mHashPut, jstrICxFactoryPut,jstrICxFactoryVal);
jstring jstrProviderUrlPut = env->NewStringUTF("java.naming.provider.url");
jstring jstrProviderUrlVal = env->NewStringUTF("t3://192.168.40.137:7001");
env->CallObjectMethod(objHash, mHashPut, jstrProviderUrlPut,jstrProviderUrlVal);
clsInitDirCx = env->FindClass("javax/naming/InitialContext");
mInitDirCxInit = env->GetMethodID(clsInitDirCx, "<init>", "(Ljava/util/Hashtable;)V");
objInitDirCx = env->NewObject(clsInitDirCx, mInitDirCxInit, objHash);
if(objInitDirCx == NULL){
printf("%s test FAILED:\n\n", (char*)arg);
else{
printf("%s test PASSED\n\n", (char*)arg);
jvm->DetachCurrentThread();
* Function main(void) creates a JVM, and calls DoJNDI twice:
* Once as a regular function call, and once as a spun off thread.
void main() {
JavaVMInitArgs vm_args;
JavaVMOption options[5];
options[0].optionString = "-client";
options[1].optionString =
"-cp " USER_CLASSPATH;
options[2].optionString =
"-Djava.class.path=" USER_CLASSPATH;
//options[3].optionString =
// "-Xbootclasspath:c:\\j2sdk1.4.0\\lib\\tools.jar;z:\\wlserver6.1\\lib\\weblogic_sp.jar;z:\\wlserver6.1\\lib\\weblogic.jar;";
options[3].optionString =
"-Xbootclasspath/a:c:\\j2sdk1.4.0\\lib\\tools.jar;z:\\wlserver6.1\\lib\\weblogic_sp.jar;";
options[4].optionString =
"-Xbootclasspath/p:c:\\j2sdk1.4.0\\lib\\tools.jar;z:\\wlserver6.1\\lib\\weblogic_sp.jar;";
vm_args.version = 0x00010002;
vm_args.options = options;
vm_args.nOptions = 5;
vm_args.ignoreUnrecognized = JNI_TRUE;
JNIEnv *env;
jint res = JNI_CreateJavaVM(&jvm, (void**)&env, &vm_args);
// *** Make the magic calls! (Both lines should do the same thing) ***
DoJNDI((void*)"Function call");
_beginthread(DoJNDI,0,(void *)"Thread call");
/* wait for thread(s) to finish */
Sleep(5000);
jvm->DestroyJavaVM();
But it always send me a Exception like below:
javax.naming.NoInitialContextException: Cannot instantiate class: weblogic.jndi.WLInitialContextFactory.
Root exception is java.lang.ClassNotFoundException: weblogic/jndi/WLInitialContextFactory
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:207)
at com.sun.naming.internal.VersionHelper12.loadClass(VersionHelper12.java:42)
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:649)
at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243)
at javax.naming.InitialContext.init(InitialContext.java:219)
at javax.naming.InitialContext.<init>(InitialContext.java:195)
when I search this problem in java.sun.com,an article announce that it is a bug that
JNDI not support multi-threads call,and it is fixed is JDK1.4 beta. The link is:
http://developer.java.sun.com/developer/bugParade/bugs/4307751.html
It seems that weblogic's JNDI is not support multi-thread call. what can i do?Try adding the following code before instantiating your initial context:
Thread.currentThread().setContextClassLoader( ClassLoader.getSystemClassLoader()
This fixed the problem for me.
-Brian
"Edward Lu" <[email protected]> wrote:
>
Help me! I'm using jni to call weblogic EJB from a Com+ component,here is
the code:
// This is the main project file for VC++ application project
// generated using an Application Wizard.
#include "stdafx.h"
#pragma unmanaged
#include <windows.h>
#include <jni.h>
#include <process.h>
#include <stdio.h>
#define USER_CLASSPATH "C:\\myClasses;C:\\j2sdk1.4.0\\lib\\tools.jar;Z:\\wlserver6.1\\lib\\weblogic.jar;"
/* where Prog.class is */
JavaVM *jvm;
* Function GetJNIEnv(void) returns the java environment pointer
* in case we are executing on a thread other than the one the
* jvm was created on.
JNIEnv* GetJNIEnv(void){
JNIEnv *env = NULL;
jint nRet = jvm->GetEnv((void **)&env, JNI_VERSION_1_2);
if(nRet == JNI_EDETACHED){
jvm->AttachCurrentThread((void **)&env, NULL);
return env;
* Function DoJNDI(void *arg) uses the Java Invocation API to
* execute the following Java code:
* Hashtable prop = new Hashtable();
* prop.put(Context.INITIAL_CONTEXT_FACTORY, "weblogic.jndi.WLInitialContextFactory"
* prop.put( Context.PROVIDER_URL, "t3://192.168.40.137:7001" );
* ctxInitial = new InitialDirContext( prop );
void DoJNDI(void *arg){
jclass clsHash, clsInitDirCx;
jmethodID mHashInit, mHashPut, mInitDirCxInit;
jobject objHash, objInitDirCx;
JNIEnv *env = GetJNIEnv(); // Get the environment if on a different thread
clsHash = env->FindClass("java/util/Hashtable");
mHashInit = env->GetMethodID(clsHash, "<init>", "()V");
objHash = env->NewObject(clsHash, mHashInit);
mHashPut = env->GetMethodID(clsHash, "put", "(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object;");
jstring jstrICxFactoryPut = env->NewStringUTF("java.naming.factory.initial");
jstring jstrICxFactoryVal = env->NewStringUTF("weblogic.jndi.WLInitialContextFactory");
env->CallObjectMethod(objHash, mHashPut, jstrICxFactoryPut,jstrICxFactoryVal);
jstring jstrProviderUrlPut = env->NewStringUTF("java.naming.provider.url");
jstring jstrProviderUrlVal = env->NewStringUTF("t3://192.168.40.137:7001");
env->CallObjectMethod(objHash, mHashPut, jstrProviderUrlPut,jstrProviderUrlVal);
clsInitDirCx = env->FindClass("javax/naming/InitialContext");
mInitDirCxInit = env->GetMethodID(clsInitDirCx, "<init>", "(Ljava/util/Hashtable;)V");
objInitDirCx = env->NewObject(clsInitDirCx, mInitDirCxInit, objHash);
if(objInitDirCx == NULL){
printf("%s test FAILED:\n\n", (char*)arg);
else{
printf("%s test PASSED\n\n", (char*)arg);
jvm->DetachCurrentThread();
* Function main(void) creates a JVM, and calls DoJNDI twice:
* Once as a regular function call, and once as a spun off thread.
void main() {
JavaVMInitArgs vm_args;
JavaVMOption options[5];
options[0].optionString = "-client";
options[1].optionString =
"-cp " USER_CLASSPATH;
options[2].optionString =
"-Djava.class.path=" USER_CLASSPATH;
//options[3].optionString =
// "-Xbootclasspath:c:\\j2sdk1.4.0\\lib\\tools.jar;z:\\wlserver6.1\\lib\\weblogic_sp.jar;z:\\wlserver6.1\\lib\\weblogic.jar;";
options[3].optionString =
"-Xbootclasspath/a:c:\\j2sdk1.4.0\\lib\\tools.jar;z:\\wlserver6.1\\lib\\weblogic_sp.jar;";
options[4].optionString =
"-Xbootclasspath/p:c:\\j2sdk1.4.0\\lib\\tools.jar;z:\\wlserver6.1\\lib\\weblogic_sp.jar;";
vm_args.version = 0x00010002;
vm_args.options = options;
vm_args.nOptions = 5;
vm_args.ignoreUnrecognized = JNI_TRUE;
JNIEnv *env;
jint res = JNI_CreateJavaVM(&jvm, (void**)&env, &vm_args);
// *** Make the magic calls! (Both lines should do the same thing) ***
DoJNDI((void*)"Function call");
_beginthread(DoJNDI,0,(void *)"Thread call");
/* wait for thread(s) to finish */
Sleep(5000);
jvm->DestroyJavaVM();
But it always send me a Exception like below:
javax.naming.NoInitialContextException: Cannot instantiate class: weblogic.jndi.WLInitialContextFactory.
Root exception is java.lang.ClassNotFoundException: weblogic/jndi/WLInitialContextFactory
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:207)
at com.sun.naming.internal.VersionHelper12.loadClass(VersionHelper12.java:42)
at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:649)
at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243)
at javax.naming.InitialContext.init(InitialContext.java:219)
at javax.naming.InitialContext.<init>(InitialContext.java:195)
when I search this problem in java.sun.com,an article announce that it is
a bug that
JNDI not support multi-threads call,and it is fixed is JDK1.4 beta. The
link is:
http://developer.java.sun.com/developer/bugParade/bugs/4307751.html
It seems that weblogic's JNDI is not support multi-thread call. what can
i do? -
Use of externally-defined/ in weblogic-ejb-jar.xml
I am trying to use Global Roles defined via the Weblogic console to control access to EJB methods.
I am using the <externally-defined/> tag in security role assignments, however when I deploy to Weblogic I get the following error :
<8/09/2004 04:21:42 PM GMT+10:00> <Error> <Deployer> <BEA-149205> <Failed to initialize the application appsdirmars-marketdata_ear due to error weblogic.manag
ement.ApplicationException: Prepare failed. Task Id = null
Module Name: ejb-marketdata.jar, Error: [EJB:011024]The XML parser encountered an error in your deployment descriptor. Please ensure that your deployment descriptor corresponds to the format in the DTD. The error was:
Error parsing file 'META-INF/weblogic-ejb-jar.xml' at line: 51 column: 26. Element type "externally-defined" must be declared..
at weblogic.j2ee.J2EEApplicationContainer.checkForErrors(J2EEApplication
Container.java:1612)
at weblogic.j2ee.J2EEApplicationContainer.prepare(J2EEApplicationContain
er.java:1207)
at weblogic.j2ee.J2EEApplicationContainer.prepare(J2EEApplicationContain
er.java:1051)
at weblogic.j2ee.J2EEApplicationContainer.prepare(J2EEApplicationContain
er.java:823)
at weblogic.management.deploy.slave.SlaveDeployer$Application.prepare(Sl
aveDeployer.java:2925)
at weblogic.management.deploy.slave.SlaveDeployer.prepareAllApplications
(SlaveDeployer.java:967)
at weblogic.management.deploy.slave.SlaveDeployer.resume(SlaveDeployer.j
ava:349)
at weblogic.management.deploy.DeploymentManagerServerLifeCycleImpl.resum
e(DeploymentManagerServerLifeCycleImpl.java:229)
at weblogic.t3.srvr.SubsystemManager.resume(SubsystemManager.java:131)
at weblogic.t3.srvr.T3Srvr.resume(T3Srvr.java:966)
at weblogic.t3.srvr.T3Srvr.run(T3Srvr.java:361)
at weblogic.Server.main(Server.java:32)
I am running Weblogic 8.1 SP3 on Windows XP Pro.
The XML is valid for the specified DTD according to my XML editor.
The relevevant fragment from weblogic-ejb-jar.xml is included below.
Any help much appreciated.
Gavin.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE weblogic-ejb-jar PUBLIC "-//BEA Systems, Inc.//DTD WebLogic 8.1.0 EJB//EN" "http://www.bea.com/servers/wls810/dtd/weblogic-ejb-jar.dtd">
<weblogic-ejb-jar>
<security-role-assignment>
<role-name>MarsAdmin</role-name>
<externally-defined/>
</security-role-assignment>
<security-role-assignment>
<role-name>MarsViewer</role-name>
<externally-defined/>
</security-role-assignment>
</weblogic-ejb-jar>I tried using the <global-role/> tag instead - this does deploy without any errors - but when I call the secure EJB method I get the Security Violation error below.
The DTD says using the <global-role/> tag is fine, albeit deprecated, but the Weblogic 8.1 manual says this has been replaced by <externally-defined/>, so I'm not sure if this should work or not.
[EJB:010160]Security Violation: User: 'ghughes' has insufficient permission to access EJB: type=<ejb>, application=_appsdir_mars-marketdata_ear, module=ejb-marketdata.jar, ejb=marketdata.MarketDataManager, method=getEnergyOverview, methodInterface=Remote, signature={java.util.Date}.
So on the whole I'd prefer to work out why Weblogic isn't recognising <externally-defined/> - I've included the full deployment descriptor below - I'm generating it using the latest snapshot of XDoclet - is the DTD specified correct for Weblogic 8.1 SP3 ? (It matches the one specified in http://e-docs.bea.com/wls/docs81/ejb/DDreference-ejb-jar.html - but I can't think of anything else that could be wrong).
Any tips much appreciated as I need to enable an administrator to customise these roles at runtime rather than hard-coding the role - group mappings into the deployment descriptors.
Thanks,
Gavin.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE weblogic-ejb-jar PUBLIC "-//BEA Systems, Inc.//DTD WebLogic 8.1.0 EJB//EN" "http://www.bea.com/servers/wls810/dtd/weblogic-ejb-jar.dtd">
<weblogic-ejb-jar>
<description><![CDATA[Generated by XDoclet]]></description>
<weblogic-enterprise-bean>
<ejb-name>marketdata.MarketDataManager</ejb-name>
<stateless-session-descriptor>
</stateless-session-descriptor>
<reference-descriptor>
</reference-descriptor>
<jndi-name>marketdata.MarketDataManager</jndi-name>
<local-jndi-name>marketdata.MarketDataManagerLocal</local-jndi-name>
</weblogic-enterprise-bean>
<weblogic-enterprise-bean>
<ejb-name>marketdata.MessageManager</ejb-name>
<message-driven-descriptor>
<pool>
<max-beans-in-free-pool>5</max-beans-in-free-pool>
<initial-beans-in-free-pool>1</initial-beans-in-free-pool>
</pool>
<destination-jndi-name>FileTopic</destination-jndi-name>
<connection-factory-jndi-name>JMSConnectionFactory</connection-factory-jndi-name>
<jms-polling-interval-seconds>10</jms-polling-interval-seconds>
<jms-client-id>1</jms-client-id>
</message-driven-descriptor>
<transaction-descriptor>
<trans-timeout-seconds>10</trans-timeout-seconds>
</transaction-descriptor>
<reference-descriptor>
</reference-descriptor>
<enable-call-by-reference>True</enable-call-by-reference>
</weblogic-enterprise-bean>
<!--
To add enterprise beans that you have deployment descriptor info for, add
a file to your XDoclet merge directory called weblogic-enterprise-beans.xml that contains
the <weblogic-enterprise-bean></weblogic-enterprise-bean> markup for those beans.
-->
<!-- xdoclet merge file -> weblogic-ejb-jar.xml -->
<security-role-assignment>
<role-name>MarsAdmin</role-name>
<externally-defined/>
</security-role-assignment>
<security-role-assignment>
<role-name>MarsViewer</role-name>
<externally-defined/>
</security-role-assignment>
<idempotent-methods>
</idempotent-methods>
</weblogic-ejb-jar>
Message was edited by [email protected] at Sep 8, 2004 8:45 PM -
How can one invoke a WebLogic EJB from a BPEL Server hosted on OC4J?
How can one invoke a WebLogic EJB from a BPEL Server hosted on OC4J?
Reason I ask is I keep getting this error:
javax.naming.NoInitialContextException: Cannot instantiate cla
ss: weblogic.jndi.WLInitialContextFactory [Root exception is java.lang.ClassNotF
oundException: weblogic.jndi.WLInitialContextFactory]
Note: I am using <bpelx:exec> as a way to execute some java program.
Essentially my java client (essentially an EJB client hosted on Oc4J) needs access to wlclient.jar since it needs access to weblogic.jndi.WLInitialContextFactory. I have a EJB client running on BPEL server hosted on Oc4J that needs to access some EJBs hosted on weblogic.
Where do I place this wlclient.jar so that BPEL PM can start peacefully and at runtime discover the InitialContextFactory classes?
Placing it in the j2ee/home/applib doesn't solve the problem. The server fails to start up if I do this
I tried placing it in BPEL-INF\lib directory ...
I still get the same exception...see below for exception dump
I verified the BPEL suitcase, and it in fact does contain the jar file wlclient.jar
integration\orabpel\domains\default\deploy contains the bpel_BPELProcess2_1.0.jar file and snapshot of that is as follows:
<PRE>
│ bpel.xml
│ BPELProcess2.bpel
│ BPELProcess2.jpr
│ BPELProcess2.wsdl
│ bpel_BPELProcess2_1.0.jar
│ build.xml
│ buildxml.copy
│ graphics.xml
│
├───BPEL-INF
│ └───lib
│ myEJB.jar
│ wlclient.jar
│
├───META-INF
│ MANIFEST.MF
│
└───output
bpel_BPELProcess2_1.0.jar
</PRE>
I tried using the BPEL-INF\jar directory...Is this something the obant automatically detects? or do I have to modify the build.xml? I created this directory and let Jdev deploy to local BPEL server->default domain handle it
#####################3
I even tried copying the wlclient.jar to
integration\orabpel\system\classes but this doesn't help since the BPEL PM fails to start if I explode this jar into this directory.
In short,where do I place the wlclient.jar so that this exception can be contained.
I edited the build.xml to point to the jar, that too didn't work, unless I made some mistake in the file
<bpelc classpath="${basedir}/BPEL-INF/classes;${home}/system/classes;${home}/lib/j2ee_1.3.01.jar;${basedir}/BPEL-INF/jar/wlclient.jar" input="${basedir}/bpel.xml" rev="${rev}" deploy="${deploy}" />
</target>
</project>
DETAILS on ERROR
I get the following error
Process "BPELProcess2" (revision "1.0") successfully compiled.
<2005-12-14 09:17:55,770> <INFO> <default.collaxa.cube.engine.deployment> Proces
s "BPELProcess2" (revision "1.0") successfully loaded.
05/12/14 09:18:36 weblogic.jndi.WLInitialContextFactory
javax.naming.NoInitialContextException: Cannot instantiate cla
ss: weblogic.jndi.WLInitialContextFactory [Root exception is java.lang.ClassNotF
oundException: weblogic.jndi.WLInitialContextFactory]
05/12/14 09:18:36 at javax.naming.spi.NamingManager.getInitialContext(Nami
ngManager.java:652)
05/12/14 09:18:36 at javax.naming.InitialContext.getDefaultInitCtx(Initial
Context.java:243)
05/12/14 09:18:36 at javax.naming.InitialContext.init(InitialContext.java:
219)
05/12/14 09:18:36 at javax.naming.InitialContext.<init>(InitialContext.jav
a:195)
05/12/14 09:18:36 at com.ejb.test.MapFinder.getDefaultMapName(Map
Finder.java:37)
##################3
with the bpelx all I have is two lines of code that creates a java object and calls a method on it.
The method does this:
private String initialContextFactory = "weblogic.jndi.WLInitialContextFactory";
private String providerUrl = "t3://localhost:7001";
private String urlPkgPrefixes = "";
private String mapEjbJndiName = "ejb/mycompany/Redlands";
public String getDefaultMapName() {
try {
Hashtable env = new Hashtable();
env.put(Context.INITIAL_CONTEXT_FACTORY, getInitialContextFactory());
env.put(Context.PROVIDER_URL, getProviderUrl());
if (getUrlPkgPrefixes() != null && !getUrlPkgPrefixes().equals(""))
env.put(Context.URL_PKG_PREFIXES, getUrlPkgPrefixes());
System.out.println(" " + getInitialContextFactory());
System.out.println(" " + getProviderUrl());
System.out.println(" " + getUrlPkgPrefixes());
System.out.println(" " + getEjbName());
// Get a naming context
context = new InitialContext(env);
Object ms = context.lookup(getEjbName());
MyEJBHome home = (MyEJBHome ) PortableRemoteObject.narrow(ms, MyEJBHome.class);
myEjb = home.create();
return myEjb.getDefaultName();
} catch (RemoteException re){
System.out.println(re.getCause().getMessage());
catch (Exception ex) {
ex.printStackTrace();
return null; //if unable to resolve the context factory etc...
}I did exactly as you suggested. I edited the application.xml and added this
<library path="C:\ArcGIS\test\bea\wlclient.jar"/>
I didn't add weblogic because the needed classes were all in wlclient.jar
I also edited the BASE_OB_CLASSPATH to include this jar.
Here is the result when I just start BPEL PM Server. Somehow BPEL PM doesn't like to have wlclient.jar in its classpath during startup.
Failed to create "worker" bean; exception reported is: "javax.naming.NameNotFoun
dException: remaining name: env
at weblogic.j2eeclient.SimpleContext.lookup(SimpleContext.java:49)
at weblogic.j2eeclient.SimpleContext.lookup(SimpleContext.java:57)
at weblogic.j2eeclient.SimpleContext.lookup(SimpleContext.java:62)
at javax.naming.InitialContext.lookup(InitialContext.java:347)
at com.collaxa.cube.engine.ejb.impl.WorkerBean.ejbCreate(WorkerBean.java
:49)
at sun.reflect.GeneratedMethodAccessor2.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at com.evermind.server.ejb.MessageDrivenHome.getInstance(MessageDrivenHo
me.java:1235)
at com.evermind.server.ejb.MessageDrivenHome$2.run(MessageDrivenHome.jav
a:1150)
at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(Relea
sableResourcePooledExecutor.java:186)
at java.lang.Thread.run(Thread.java:534)
<2005-12-29 13:39:05,281> <ERROR> <collaxa> <ServerManager::loadAllDomains>
ORABPEL START-UP ERROR!!!!!!!!
OraBPEL run-time system failed to start due to exception:
Could not initialize jms connection pool.
Could not initialize connection pool for connection factory "java:comp/env/jms/
ollaxa/BPELInvokerQueueFactory"; the reason is remaining name: env/jms/collaxa/
PELInvokerQueueFactory.
Note: So what I did was to removed the entry from application.xml and tried with just obsetenv.bat having the wlclient.jar added to it. This too failed!!
Here is a snapshot of the error I got.
Process "BPELProcess2" (revision "1.0") successfully compiled.
<2005-12-29 13:53:11,207> <INFO> <default.collaxa.cube.engine.deployment> Proces
s "BPELProcess2" (revision "1.0") successfully loaded.
05/12/29 13:53:32 Cannot instantiate class: weblogic.jndi.WLInitialContextFactor
y
05/12/29 13:53:32 javax.naming.NoInitialContextException: Cannot instantiate cla
ss: weblogic.jndi.WLInitialContextFactory [Root exception is java.lang.ClassNotF
oundException: weblogic.jndi.WLInitialContextFactory]
05/12/29 13:53:32 at javax.naming.spi.NamingManager.getInitialContext(Nami
ngManager.java:652)
05/12/29 13:53:32 at javax.naming.InitialContext.getDefaultInitCtx(Initial
Context.java:243)
05/12/29 13:53:32 at javax.naming.InitialContext.init(InitialContext.java:
219)
05/12/29 13:53:32 at javax.naming.InitialContext.<init>(InitialContext.jav
a:195)
05/12/29 13:53:32 at com.esri.adf.ejb.test.MapFinder.getDefaultMapName(Map
Finder.java:57)
05/12/29 13:53:32 at bpel.p0.ExecLetBxExe1.execute(ExecLetBxExe1.java:62)
05/12/29 13:53:32 at com.collaxa.cube.engine.ext.wmp.BPELXExecWMP.__execut
eStatements(BPELXExecWMP.java:49)
05/12/29 13:53:32 at com.collaxa.cube.engine.ext.wmp.BPELActivityWMP.perfo
rm(BPELActivityWMP.java:185)
05/12/29 13:53:32 at com.collaxa.cube.engine.CubeEngine.performActivity(Cu
beEngine.java:3398)
05/12/29 13:53:32 at com.collaxa.cube.engine.CubeEngine.handleWorkItem(Cub
eEngine.java:1905)
05/12/29 13:53:32 at com.collaxa.cube.engine.dispatch.message.instance.Per
formMessageHandler.handleLocal(PerformMessageHandler.java:75)
05/12/29 13:53:32 at com.collaxa.cube.engine.dispatch.DispatchHelper.handl
eLocalMessage(DispatchHelper.java:100)
05/12/29 13:53:32 at com.collaxa.cube.engine.dispatch.DispatchHelper.sendM -
Deployment plan fails for weblogic-ejb-jar.xml
FILE FOR PLAN TO ACT ON:
application.ear\ReferenceTableSession.jar\META-INF\weblogic-ejb-jar.xml
<?xml version="1.0" encoding="utf-8"?>
<weblogic-ejb-jar xmlns="http://www.bea.com/ns/weblogic/10.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.bea.com/ns/weblogic/10.0 http://www.bea.com/ns/weblogic/10.0/weblogic-ejb-jar.xsd">
<weblogic-enterprise-bean>
<ejb-name>referencetablesession</ejb-name>
<stateless-session-descriptor>
<pool>
<max-beans-in-free-pool>100</max-beans-in-free-pool>
<initial-beans-in-free-pool>0</initial-beans-in-free-pool>
</pool>
<stateless-clustering>
<stateless-bean-is-clusterable>true</stateless-bean-is-clusterable>
</stateless-clustering>
</stateless-session-descriptor>
<transaction-descriptor>
<trans-timeout-seconds>150</trans-timeout-seconds>
</transaction-descriptor>
<enable-call-by-reference>true</enable-call-by-reference>
<jndi-name>XYZ_ejb/ProviderMaintSvc/referencetablesession</jndi-name>
</weblogic-enterprise-bean>
<transaction-isolation>
<isolation-level>TransactionReadCommitted</isolation-level>
<method>
<ejb-name>referencetablesession</ejb-name>
<method-name>*</method-name>
</method>
</transaction-isolation>
</weblogic-ejb-jar>
DEPLOYMENT PLAN:
<?xml version='1.0' encoding='utf-8'?>
<deployment-plan xmlns="http://www.bea.com/ns/weblogic/deployment-plan"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.bea.com/ns/weblogic/deployment-plan http://www.bea.com/ns/weblogic/deployment-plan/1.0/deployment-plan.xsd">
<application-name>application.ear</application-name>
<variable-definition>
<variable>
<name>VAR_referencetablesession</name>
<value>ejb/ProviderClaimOnlineSvc/referencetablesession</value>
</variable>
</variable-definition>
<module-override>
<module-name>ReferenceTableSession.jar</module-name>
<module-type>ejb</module-type>
<module-descriptor external="false">
<root-element>weblogic-ejb-jar</root-element>
<uri>META-INF/weblogic-ejb-jar.xml</uri>
<variable-assignment>
<name>VAR_referencetablesession</name>
<xpath>/weblogic-ejb-jar/weblogic-enterprise-bean/\[ejb-name="referencetablesession"\]/jndi-name</xpath>
<operation>replace</operation>
</variable-assignment>
</module-descriptor>
</module-override>
<config-root>servers/AdminServer/upload</config-root>
</deployment-plan>
ERROR FROM CONSOLE:
Message icon - Error An error occurred during activation of changes, please see the log for details.
Message icon - Error Exception preparing module: EJBModule(ReferenceTableSession.jar) [EJB:011023]An error occurred while reading the deployment descriptor. The error was: Unmarshaller failed.
Message icon - Error Bean already exists: "[email protected]f2(/WeblogicEnterpriseBeans[referencetablesession])"
ERROR FROM LOG:
<Oct 2, 2009 1:08:25 PM CDT> <Error> <J2EE> <BEA-160197> <Unable to load descriptor servers/ms34/tmp/_WL_user/ProviderClaimOnlineSvc/y1anoa/ReferenceTableSession.jar/META-INF/weblogic-ejb-jar.xml of module ReferenceTableSession.jar. The error is weblogic.descriptor.DescriptorException: Unmarshaller failed
at weblogic.descriptor.internal.MarshallerFactory$1.createDescriptor(MarshallerFactory.java:152)
at weblogic.descriptor.BasicDescriptorManager.createDescriptor(BasicDescriptorManager.java:306)
at weblogic.application.descriptor.AbstractDescriptorLoader2.getDescriptorBeanFromReader(AbstractDescriptorLoader2.java:788)
at weblogic.application.descriptor.AbstractDescriptorLoader2.mergeDescriptorBeanWithPlan(AbstractDescriptorLoader2.java:703)
at weblogic.application.descriptor.AbstractDescriptorLoader2.loadDescriptorBean(AbstractDescriptorLoader2.java:776)
at weblogic.ejb.spi.EjbJarDescriptor.parseWeblogicEjbJarBean(EjbJarDescriptor.java:160)
at weblogic.ejb.container.dd.xml.EjbDescriptorReaderImpl.processWLEjbJarXMLWithSchema(EjbDescriptorReaderImpl.java:719)
at weblogic.ejb.container.dd.xml.EjbDescriptorReaderImpl.parseWLDD(EjbDescriptorReaderImpl.java:541)
at weblogic.ejb.container.dd.xml.EjbDescriptorReaderImpl.processWeblogicEjbJarXML(EjbDescriptorReaderImpl.java:380)
at weblogic.ejb.container.dd.xml.EjbDescriptorReaderImpl.createReadOnlyDescriptorFromJarFile(EjbDescriptorReaderImpl.java:191)
at weblogic.ejb.spi.EjbDescriptorFactory.createReadOnlyDescriptorFromJarFile(EjbDescriptorFactory.java:93)
at weblogic.ejb.container.deployer.EJBModule.loadEJBDescriptor(EJBModule.java:1198)
at weblogic.ejb.container.deployer.EJBModule.prepare(EJBModule.java:380)
at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:93)
at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:387)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:58)
at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:42)
at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:615)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:191)
at weblogic.application.internal.EarDeployment.prepare(EarDeployment.java:16)
at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:155)
at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:60)
at weblogic.deploy.internal.targetserver.operations.RedeployOperation.createAndPrepareContainer(RedeployOperation.java:98)
at weblogic.deploy.internal.targetserver.operations.RedeployOperation.doPrepare(RedeployOperation.java:122)
Thanks,
Rob
Edited by: user11337024 on Oct 5, 2009 2:31 PMFILE FOR PLAN TO ACT ON:
application.ear\ReferenceTableSession.jar\META-INF\weblogic-ejb-jar.xml
<?xml version="1.0" encoding="utf-8"?>
<weblogic-ejb-jar xmlns="http://www.bea.com/ns/weblogic/10.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.bea.com/ns/weblogic/10.0 http://www.bea.com/ns/weblogic/10.0/weblogic-ejb-jar.xsd">
<weblogic-enterprise-bean>
<ejb-name>referencetablesession</ejb-name>
<stateless-session-descriptor>
<pool>
<max-beans-in-free-pool>100</max-beans-in-free-pool>
<initial-beans-in-free-pool>0</initial-beans-in-free-pool>
</pool>
<stateless-clustering>
<stateless-bean-is-clusterable>true</stateless-bean-is-clusterable>
</stateless-clustering>
</stateless-session-descriptor>
<transaction-descriptor>
<trans-timeout-seconds>150</trans-timeout-seconds>
</transaction-descriptor>
<enable-call-by-reference>true</enable-call-by-reference>
<jndi-name>XYZ_ejb/ProviderMaintSvc/referencetablesession</jndi-name>
</weblogic-enterprise-bean>
<transaction-isolation>
<isolation-level>TransactionReadCommitted</isolation-level>
<method>
<ejb-name>referencetablesession</ejb-name>
<method-name>*</method-name>
</method>
</transaction-isolation>
</weblogic-ejb-jar>
DEPLOYMENT PLAN:
<?xml version='1.0' encoding='utf-8'?>
<deployment-plan xmlns="http://www.bea.com/ns/weblogic/deployment-plan"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.bea.com/ns/weblogic/deployment-plan http://www.bea.com/ns/weblogic/deployment-plan/1.0/deployment-plan.xsd">
<application-name>application.ear</application-name>
<variable-definition>
<variable>
<name>VAR_referencetablesession</name>
<value>ejb/ProviderClaimOnlineSvc/referencetablesession</value>
</variable>
</variable-definition>
<module-override>
<module-name>ReferenceTableSession.jar</module-name>
<module-type>ejb</module-type>
<module-descriptor external="false">
<root-element>weblogic-ejb-jar</root-element>
<uri>META-INF/weblogic-ejb-jar.xml</uri>
<variable-assignment>
<name>VAR_referencetablesession</name>
<xpath>/weblogic-ejb-jar/weblogic-enterprise-bean/\[ejb-name="referencetablesession"\]/jndi-name</xpath>
<operation>replace</operation>
</variable-assignment>
</module-descriptor>
</module-override>
<config-root>servers/AdminServer/upload</config-root>
</deployment-plan>
ERROR FROM CONSOLE:
Message icon - Error An error occurred during activation of changes, please see the log for details.
Message icon - Error Exception preparing module: EJBModule(ReferenceTableSession.jar) [EJB:011023]An error occurred while reading the deployment descriptor. The error was: Unmarshaller failed.
Message icon - Error Bean already exists: "[email protected]f2(/WeblogicEnterpriseBeans[referencetablesession])"
ERROR FROM LOG:
<Oct 2, 2009 1:08:25 PM CDT> <Error> <J2EE> <BEA-160197> <Unable to load descriptor servers/ms34/tmp/_WL_user/ProviderClaimOnlineSvc/y1anoa/ReferenceTableSession.jar/META-INF/weblogic-ejb-jar.xml of module ReferenceTableSession.jar. The error is weblogic.descriptor.DescriptorException: Unmarshaller failed
at weblogic.descriptor.internal.MarshallerFactory$1.createDescriptor(MarshallerFactory.java:152)
at weblogic.descriptor.BasicDescriptorManager.createDescriptor(BasicDescriptorManager.java:306)
at weblogic.application.descriptor.AbstractDescriptorLoader2.getDescriptorBeanFromReader(AbstractDescriptorLoader2.java:788)
at weblogic.application.descriptor.AbstractDescriptorLoader2.mergeDescriptorBeanWithPlan(AbstractDescriptorLoader2.java:703)
at weblogic.application.descriptor.AbstractDescriptorLoader2.loadDescriptorBean(AbstractDescriptorLoader2.java:776)
at weblogic.ejb.spi.EjbJarDescriptor.parseWeblogicEjbJarBean(EjbJarDescriptor.java:160)
at weblogic.ejb.container.dd.xml.EjbDescriptorReaderImpl.processWLEjbJarXMLWithSchema(EjbDescriptorReaderImpl.java:719)
at weblogic.ejb.container.dd.xml.EjbDescriptorReaderImpl.parseWLDD(EjbDescriptorReaderImpl.java:541)
at weblogic.ejb.container.dd.xml.EjbDescriptorReaderImpl.processWeblogicEjbJarXML(EjbDescriptorReaderImpl.java:380)
at weblogic.ejb.container.dd.xml.EjbDescriptorReaderImpl.createReadOnlyDescriptorFromJarFile(EjbDescriptorReaderImpl.java:191)
at weblogic.ejb.spi.EjbDescriptorFactory.createReadOnlyDescriptorFromJarFile(EjbDescriptorFactory.java:93)
at weblogic.ejb.container.deployer.EJBModule.loadEJBDescriptor(EJBModule.java:1198)
at weblogic.ejb.container.deployer.EJBModule.prepare(EJBModule.java:380)
at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:93)
at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:387)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:58)
at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:42)
at weblogic.application.internal.BaseDeployment$1.next(BaseDeployment.java:615)
at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:37)
at weblogic.application.internal.BaseDeployment.prepare(BaseDeployment.java:191)
at weblogic.application.internal.EarDeployment.prepare(EarDeployment.java:16)
at weblogic.application.internal.DeploymentStateChecker.prepare(DeploymentStateChecker.java:155)
at weblogic.deploy.internal.targetserver.AppContainerInvoker.prepare(AppContainerInvoker.java:60)
at weblogic.deploy.internal.targetserver.operations.RedeployOperation.createAndPrepareContainer(RedeployOperation.java:98)
at weblogic.deploy.internal.targetserver.operations.RedeployOperation.doPrepare(RedeployOperation.java:122)
Thanks,
Rob
Edited by: user11337024 on Oct 5, 2009 2:31 PM -
Loss of Weblogic EJB functionality from 2EA2 to 2 Release
I get the following error when running with control bound to Weblogic EJB. Same problem in new or existing projects. JSC and computer have been restarted. The EJB worked fine in 2EA2.
Description: An unhandled exception occurred during the execution of the web application. Please review the following stack trace for more information regarding the error.
Exception Details: org.apache.jasper.JasperException
com.sun.data.provider.DataProviderException: java.lang.reflect.InvocationTargetException
Possible Source of Error:
Class Name: org.apache.jasper.servlet.JspServletWrapper
File Name: JspServletWrapper.java
Method Name: service
Line Number: 384
Source not available. Information regarding the location of the exception can be identified using the exception stack trace below.
Stack Trace:
org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:384)
org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:301)
org.apache.jasper.servlet.JspServlet.service(JspServlet.java:251)
javax.servlet.http.HttpServlet.service(HttpServlet.java:860)
sun.reflect.NativeMethodAccessorImpl.invoke0(NativeMethodAccessorImpl.java:-2)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:585)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:249)
java.security.AccessController.doPrivileged(AccessController.java:-2)
javax.security.auth.Subject.doAsPrivileged(Subject.java:517)
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:282)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:165)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:257)
org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:55)
org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:161)
java.security.AccessController.doPrivileged(AccessController.java:-2)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:723)
org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:482)
org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:417)
org.apache.catalina.core.ApplicationDispatcher.access$000(ApplicationDispatcher.java:80)
org.apache.catalina.core.ApplicationDispatcher$PrivilegedForward.run(ApplicationDispatcher.java:95)
java.security.AccessController.doPrivileged(AccessController.java:-2)
org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:313)
com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:322)
com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:130)
com.sun.rave.web.ui.appbase.faces.ViewHandlerImpl.renderView(ViewHandlerImpl.java:311)
com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:221)
com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
sun.reflect.NativeMethodAccessorImpl.invoke0(NativeMethodAccessorImpl.java:-2)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:585)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:249)
java.security.AccessController.doPrivileged(AccessController.java:-2)
javax.security.auth.Subject.doAsPrivileged(Subject.java:517)
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:282)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:165)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:257)
org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:55)
org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:161)
java.security.AccessController.doPrivileged(AccessController.java:-2)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
com.sun.rave.web.ui.util.UploadFilter.doFilter(UploadFilter.java:194)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:210)
org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:55)
org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:161)
java.security.AccessController.doPrivileged(AccessController.java:-2)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:263)
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:225)
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:173)
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:161)
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:132)
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:933)
org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:185)
com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:653)
com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:534)
com.sun.enterprise.web.connector.grizzly.ProcessorTask.doTask(ProcessorTask.java:403)
com.sun.enterprise.web.connector.grizzly.WorkerThread.run(WorkerThread.java:55)
Exception Details: javax.faces.FacesException
org.apache.jasper.JasperException: com.sun.data.provider.DataProviderException: java.lang.reflect.InvocationTargetException
Possible Source of Error:
Class Name: com.sun.faces.context.ExternalContextImpl
File Name: ExternalContextImpl.java
Method Name: dispatch
Line Number: 327
Source not available. Information regarding the location of the exception can be identified using the exception stack trace below.
Stack Trace:
com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:327)
com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:130)
com.sun.rave.web.ui.appbase.faces.ViewHandlerImpl.renderView(ViewHandlerImpl.java:311)
com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:221)
com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
sun.reflect.NativeMethodAccessorImpl.invoke0(NativeMethodAccessorImpl.java:-2)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:585)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:249)
java.security.AccessController.doPrivileged(AccessController.java:-2)
javax.security.auth.Subject.doAsPrivileged(Subject.java:517)
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:282)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:165)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:257)
org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:55)
org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:161)
java.security.AccessController.doPrivileged(AccessController.java:-2)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
com.sun.rave.web.ui.util.UploadFilter.doFilter(UploadFilter.java:194)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:210)
org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:55)
org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:161)
java.security.AccessController.doPrivileged(AccessController.java:-2)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:263)
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:225)
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:173)
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:161)
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:132)
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:933)
org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:185)
com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:653)
com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:534)
com.sun.enterprise.web.connector.grizzly.ProcessorTask.doTask(ProcessorTask.java:403)
com.sun.enterprise.web.connector.grizzly.WorkerThread.run(WorkerThread.java:55)
Exception Details: com.sun.rave.web.ui.appbase.ApplicationException
org.apache.jasper.JasperException: com.sun.data.provider.DataProviderException: java.lang.reflect.InvocationTargetException
Possible Source of Error:
Class Name: com.sun.rave.web.ui.appbase.faces.ViewHandlerImpl
File Name: ViewHandlerImpl.java
Method Name: destroy
Line Number: 601
Source not available. Information regarding the location of the exception can be identified using the exception stack trace below.
Stack Trace:
com.sun.rave.web.ui.appbase.faces.ViewHandlerImpl.destroy(ViewHandlerImpl.java:601)
com.sun.rave.web.ui.appbase.faces.ViewHandlerImpl.renderView(ViewHandlerImpl.java:316)
com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:87)
com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:221)
com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:117)
javax.faces.webapp.FacesServlet.service(FacesServlet.java:198)
sun.reflect.NativeMethodAccessorImpl.invoke0(NativeMethodAccessorImpl.java:-2)
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
java.lang.reflect.Method.invoke(Method.java:585)
org.apache.catalina.security.SecurityUtil$1.run(SecurityUtil.java:249)
java.security.AccessController.doPrivileged(AccessController.java:-2)
javax.security.auth.Subject.doAsPrivileged(Subject.java:517)
org.apache.catalina.security.SecurityUtil.execute(SecurityUtil.java:282)
org.apache.catalina.security.SecurityUtil.doAsPrivilege(SecurityUtil.java:165)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:257)
org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:55)
org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:161)
java.security.AccessController.doPrivileged(AccessController.java:-2)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
com.sun.rave.web.ui.util.UploadFilter.doFilter(UploadFilter.java:194)
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:210)
org.apache.catalina.core.ApplicationFilterChain.access$000(ApplicationFilterChain.java:55)
org.apache.catalina.core.ApplicationFilterChain$1.run(ApplicationFilterChain.java:161)
java.security.AccessController.doPrivileged(AccessController.java:-2)
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:157)
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:263)
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:225)
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:173)
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:161)
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:132)
org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:551)
org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:933)
org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:185)
com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:653)
com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:534)
com.sun.enterprise.web.connector.grizzly.ProcessorTask.doTask(ProcessorTask.java:403)
com.sun.enterprise.web.connector.grizzly.WorkerThread.run(WorkerThread.java:55)Did you deploy the web app to the bundled Sun appserver? Can you look at the server.log from the appserver (<creator-install-dir>/SunAppServer8/logs/server.log) and see what exceptioin you have? My guess is that it failed when invoking your EJBs?
-dongmei -
Weblogic.ejb.extensions.LockTimedOutException
Hi,
I am running an application on wl4.5.1 and the app server seems to hang and average of about once a week and we have to restart it it seems really random. The only pattern we've noticed from looking at the log files is that just before we go down we get a lot of weblogic.ejb.extensions.LockTimedOutException ' s. There seems to be a deadlock for access to one of the entity beans and the requesting transactions timeout. Is it possible that the appserver hangs because of these exceptions getting thrown and all the appservers resouces get used up so it doesn't take any more requests? Does any one have any ideas/experience with this issue?
Thanks for any help in advance,
R..Hi Rukus,
AFAIK 4.5.1 was EOL-ed quite some time ago, so it may be
pretty hard to get support for this version.
You may find a solution by searching newsgroups
archive. I've done some preliminary work for you,
hopefully it will help:
http://makeashorterlink.com/?M29D32364
Regards,
Slava Imeshev
"Rukus" <[email protected]> wrote in message
news:3eaf0172$[email protected]..
Hi,
I am running an application on wl4.5.1 and the app server seems to hangand average of about once a week and we have to restart it it seems really
random. The only pattern we've noticed from looking at the log files is
that just before we go down we get a lot of
weblogic.ejb.extensions.LockTimedOutException ' s. There seems to be a
deadlock for access to one of the entity beans and the requesting
transactions timeout. Is it possible that the appserver hangs because of
these exceptions getting thrown and all the appservers resouces get used up
so it doesn't take any more requests? Does any one have any
ideas/experience with this issue?
>
Thanks for any help in advance,
R.. -
Weblogic.ejb.extensions.LockTimeOutException HELP!
Hi,
We're seeing weblogic.ejb.extensions.LockTimeOutException when we try
to access some Entity Bean's data member. I'm wondering someone could
help us?
There is some background:
WL server 5.1, SP10 (almost sure:)
Running in Solaris w/ Oracle 8i
The sequence of calls is:
IWorkspaceRemote workspace = (IWorkspaceRemote)
getEntityBean(EJBConstants.JNDI_NAME_WORKSPACE, new
Long(workspaceID));
WorkspaceDetailData wsData = workspace.getWorkspaceDetailData();
( the EJB home is cached in memory ***)
Inside ejbLoad() we're using the Composite Entity EJB pattern (for
lazy loading) and looks something like this:
void ejbLoad() {
m_baseData = loadBaseData();
if (m_detailData != null) {
m_detailData = loadDetailData();
DetailData getWorkspaceDetailData() {
if (m_detailData == null) {
m_detailData = loadDetailData();
THe stack trace I get is:
weblogic.ejb.extensions.LockTimedOutException: Lock for
primaryKey:21071 timed out after 60000 ms.
at weblogic.ejb.internal.LockManagerImpl.waitForLock(LockManagerImpl.java:53)
at weblogic.ejb.internal.LockManagerImpl.lock(LockManagerImpl.java:146)
at weblogic.ejb.internal.LockManagerImpl.lock(LockManagerImpl.java:81)
at weblogic.ejb.internal.StatefulEJBCache.bind(StatefulEJBCache.java:456)
at weblogic.ejb.internal.StatefulEJBObject.getContextForInvoke(StatefulEJBObject.java:162)
at weblogic.ejb.internal.BaseEJBObject.preInvoke(BaseEJBObject.java:476)
at com.intralinks.wsadmin.entity.WorkspaceBeanEOImpl.getWorkspaceDetailData(WorkspaceBeanEOImpl.java:155)
at com.intralinks.util.IntralinksServlet.setWorkspaceIDNoEventLogging(Unknown
Source)
at com.intralinks.util.IntralinksServlet.setWorkspaceID(Unknown
Source)
at com.intralinks.servlets.html.workspaces.EnterWorkspaceServlet.process(Unknown
Source)
Any ideas?
Thanks,
- RobertoHi Roberto,
Check CP, data sources (if they are available in 5.1) etc for oracle instance
parameters like servers, user ids, passwords, urls etc.
S
[email protected] (Roberto) wrote:
Hi,
We're seeing weblogic.ejb.extensions.LockTimeOutException when we try
to access some Entity Bean's data member. I'm wondering someone could
help us?
There is some background:
WL server 5.1, SP10 (almost sure:)
Running in Solaris w/ Oracle 8i
The sequence of calls is:
IWorkspaceRemote workspace = (IWorkspaceRemote)
getEntityBean(EJBConstants.JNDI_NAME_WORKSPACE, new
Long(workspaceID));
WorkspaceDetailData wsData = workspace.getWorkspaceDetailData();
( the EJB home is cached in memory ***)
Inside ejbLoad() we're using the Composite Entity EJB pattern (for
lazy loading) and looks something like this:
void ejbLoad() {
m_baseData = loadBaseData();
if (m_detailData != null) {
m_detailData = loadDetailData();
DetailData getWorkspaceDetailData() {
if (m_detailData == null) {
m_detailData = loadDetailData();
THe stack trace I get is:
weblogic.ejb.extensions.LockTimedOutException: Lock for
primaryKey:21071 timed out after 60000 ms.
at weblogic.ejb.internal.LockManagerImpl.waitForLock(LockManagerImpl.java:53)
at weblogic.ejb.internal.LockManagerImpl.lock(LockManagerImpl.java:146)
at weblogic.ejb.internal.LockManagerImpl.lock(LockManagerImpl.java:81)
at weblogic.ejb.internal.StatefulEJBCache.bind(StatefulEJBCache.java:456)
at weblogic.ejb.internal.StatefulEJBObject.getContextForInvoke(StatefulEJBObject.java:162)
at weblogic.ejb.internal.BaseEJBObject.preInvoke(BaseEJBObject.java:476)
at com.intralinks.wsadmin.entity.WorkspaceBeanEOImpl.getWorkspaceDetailData(WorkspaceBeanEOImpl.java:155)
at com.intralinks.util.IntralinksServlet.setWorkspaceIDNoEventLogging(Unknown
Source)
at com.intralinks.util.IntralinksServlet.setWorkspaceID(Unknown
Source)
at com.intralinks.servlets.html.workspaces.EnterWorkspaceServlet.process(Unknown
Source)
Any ideas?
Thanks,
- Roberto -
Help: weblogic.ejb.extensions.LockTimedOutException
Dear All:
I got this exception in our EJB app:
weblogic.ejb.extensions.LockTimedOutException. Please see attached error
message below. It is not happening every time you call the bean. It is
reproducable with patience.
Have you had this kind of problem and more importantly, how to avoid it?
Our env is: Wl51 with sp 10, jdk1.3.02, Sun Solaris Unix, a cluster contains
2 wl instance
Thanks.
Wed Jun 19 14:26:53 EDT 2002:<I> <TX> Transaction (TxC (5488304, xid =
1024502557372_6636, timeout = 300, txState = Marked Rollback, root = null)
rolled back after 300 sec.
[GC 99080K->85533K(130688K), 0.0227977 secs]
Wed Jun 19 14:26:54 EDT 2002:<I> <EJB JAR deployment
/webapp/dtshc/dts/nmc/ejb/nmcejb.jar> Transaction: '1024502557372_6636'
rolled back due to EJB exception:
weblogic.ejb.extensions.LockTimedOutException: Lock for
primaryKey:com.mm.nmc.entity.ProducerOneYearPlanPK@1700fc timed out after
300000 ms.
at
weblogic.ejb.internal.LockManagerImpl.waitForLock(LockManagerImpl.java:53)
at weblogic.ejb.internal.LockManagerImpl.lock(LockManagerImpl.java:146)
at weblogic.ejb.internal.LockManagerImpl.lock(LockManagerImpl.java:81)
at weblogic.ejb.internal.StatefulEJBCache.bind(StatefulEJBCache.java:456)
at
weblogic.ejb.internal.StatefulEJBObject.getContextForInvoke(StatefulEJBObjec
t.java:162)
at weblogic.ejb.internal.BaseEJBObject.preInvoke(BaseEJBObject.java:476)
at
com.mm.nmc.entity.ProducerOneYearPlanEJBEOImpl.getData(ProducerOneYearPlanEJ
BEOImpl.java:979)
at
com.mm.nmc.session.PersonalTacticalSessionEJB.getTacticalPlanGoals(PersonalT
acticalSessionEJB.java:200)
at
com.mm.nmc.session.PersonalTacticalSessionEJB.getPersonalTacticalPlan(Person
alTacticalSessionEJB.java:165)
at
com.mm.nmc.session.PersonalTacticalSessionEJB.getPersonalTacticalPlan(Person
alTacticalSessionEJB.java:155)
at
com.mm.nmc.session.PersonalTacticalSessionEJBEOImpl.getPersonalTacticalPlan(
PersonalTacticalSessionEJBEOImpl.java:340)
at
com.mm.nmc.session.PersonalTacticalSessionEJBEOImpl_WLSkel.invoke(PersonalTa
cticalSessionEJBEOImpl_WLSkel.java:167)
at
weblogic.rmi.extensions.BasicServerObjectAdapter.invoke(BasicServerObjectAda
pter.java:347)
at
weblogic.rmi.extensions.BasicRequestHandler.handleRequest(BasicRequestHandle
r.java:86)
at
weblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest.java:1
5)
at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:129)
Jiancai He
http://www.hefamily.com
Thanks for your message:
In our case, it is entity EJB. The problem only happens in clustered env,
and only happens in one of the servers.
Question: can wl51 use database to manage the concurrent access of entity
EJBs?
Thanks.
Jiancai
Jiancai He
http://www.hefamily.com
"ludovic le goff" <[email protected]> wrote in message
news:[email protected]...
> Hello,
>
> Basically, it means two (or more) different threads are trying to get an
> exclusive lock on the same entity bean or stateful session bean at the
same
> time. One of the locks eventually times out and this exception is thrown.
>
> There are several things that could cause this, for instance:
>
> - Two threads trying to invoke a method on the same stateful session bean
at
> the same time. The EJB 1.1 spec states that the server must detect this
> condition and throw a RemoteException to all subsequent callers.
> LockTimedOutException is a sub-class of java.rmi.RemoteException.
>
> - Two threads are trying to access the same entity bean instance inside a
> single server in the cluster, and the caller holding the lock does not
> finish fast enough.
>
> You might want to check if you have declared the Remote and home interface
> in your jsp/servlet as global variable. And since it's global, instance
> getting overridden every time. That's why both the two request end up in
> using the same EJBObject.
>
> You should changed your code and make the remote/home interface variable
> declaration as local i.e. within the scope of a single request.
> Then you should not see any problem. Both the threads will use different
> EJBObjects and hence you should not see any exceptions.
>
> You need to code in such a way as to avoid deadlocks. For instance, if
> more than one client accesses the EJBs in different order, a deadlock may
> occur. This deadlock is detected and after a certain timeout (5 minutes by
> default), the deadlock is removed and one of the clients gets a
> LockTimedOutException. For example, if one request in your application has
> entity Account 1 (by doing an ejbFindByPrimaryKey) and is then about to
get
> Customer 1, and if at the same time another request in another business
> method has got Customer 1 and is waiting for Account 1, you'll get a
> deadlock and a LockTimedOutException after 5 minutes. You could avoid
this
> by include the code in a synchronized block. You could also get a
deadlock
> if you're making a reentrant call, e.g., A calls B which calls back to A.
>
> If you haven't already seen this, here's a blurb from "Locking Model for
> Entity EJBs" at
>
http://www.weblogic.com/docs51/classdocs/API_ejb/EJB_environment.html#108796
> 7 that you might find interesting:
>
> The EJB 1.1 container in WebLogic Server Version 5.1 uses a pessimistic
> locking mechanism for entity EJB instances. As clients enlist an EJB or
EJB
> method in a transaction, WebLogic Server places an exclusive lock on the
EJB
> instance or method for the duration of the transaction. Other clients
> requesting the same EJB or method block until the current transaction
> completes.
>
> This method of locking provides reliable access to EJB data, and avoids
> unnecessary calls to ejbLoad() to refresh the EJB instance's persistent
> fields. However, in certain circumstances pessimistic locking may not
> provide the best model for concurrent access to the EJB's data. Once a
> client has locked an EJB instance, other clients are blocked from the
EJB's
> data even if they intend only to read the persistent fields.
>
> In a Nutshell the first exception is a consequence of the second.
>
> Hope this helps,
> Ludovic.
> Developer Relations Engineer
> BEA Customer Support
> "newsgroups.bea.com" <[email protected]> a écrit dans le message news:
> [email protected]...
> > Dear All:
> >
> > I got this exception in our EJB app:
> > weblogic.ejb.extensions.LockTimedOutException. Please see attached error
> > message below. It is not happening every time you call the bean. It is
> > reproducable with patience.
> >
> > Have you had this kind of problem and more importantly, how to avoid it?
> >
> > Our env is: Wl51 with sp 10, jdk1.3.02, Sun Solaris Unix, a cluster
> contains
> > 2 wl instance
> >
> > Thanks.
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> >
> > Wed Jun 19 14:26:53 EDT 2002:<I> <TX> Transaction (TxC (5488304, xid =
> > 1024502557372_6636, timeout = 300, txState = Marked Rollback, root =
null)
> > rolled back after 300 sec.
> >
> > [GC 99080K->85533K(130688K), 0.0227977 secs]
> >
> > Wed Jun 19 14:26:54 EDT 2002:<I> <EJB JAR deployment
> > /webapp/dtshc/dts/nmc/ejb/nmcejb.jar> Transaction: '1024502557372_6636'
> > rolled back due to EJB exception:
> >
> > weblogic.ejb.extensions.LockTimedOutException: Lock for
> > primaryKey:com.mm.nmc.entity.ProducerOneYearPlanPK@1700fc timed out
after
> > 300000 ms.
> >
> > at
> >
weblogic.ejb.internal.LockManagerImpl.waitForLock(LockManagerImpl.java:53)
> >
> > at weblogic.ejb.internal.LockManagerImpl.lock(LockManagerImpl.java:146)
> >
> > at weblogic.ejb.internal.LockManagerImpl.lock(LockManagerImpl.java:81)
> >
> > at
weblogic.ejb.internal.StatefulEJBCache.bind(StatefulEJBCache.java:456)
> >
> > at
> >
>
weblogic.ejb.internal.StatefulEJBObject.getContextForInvoke(StatefulEJBObjec
> > t.java:162)
> >
> > at weblogic.ejb.internal.BaseEJBObject.preInvoke(BaseEJBObject.java:476)
> >
> > at
> >
>
com.mm.nmc.entity.ProducerOneYearPlanEJBEOImpl.getData(ProducerOneYearPlanEJ
> > BEOImpl.java:979)
> >
> > at
> >
>
com.mm.nmc.session.PersonalTacticalSessionEJB.getTacticalPlanGoals(PersonalT
> > acticalSessionEJB.java:200)
> >
> > at
> >
>
com.mm.nmc.session.PersonalTacticalSessionEJB.getPersonalTacticalPlan(Person
> > alTacticalSessionEJB.java:165)
> >
> > at
> >
>
com.mm.nmc.session.PersonalTacticalSessionEJB.getPersonalTacticalPlan(Person
> > alTacticalSessionEJB.java:155)
> >
> > at
> >
>
com.mm.nmc.session.PersonalTacticalSessionEJBEOImpl.getPersonalTacticalPlan(
> > PersonalTacticalSessionEJBEOImpl.java:340)
> >
> > at
> >
>
com.mm.nmc.session.PersonalTacticalSessionEJBEOImpl_WLSkel.invoke(PersonalTa
> > cticalSessionEJBEOImpl_WLSkel.java:167)
> >
> > at
> >
>
weblogic.rmi.extensions.BasicServerObjectAdapter.invoke(BasicServerObjectAda
> > pter.java:347)
> >
> > at
> >
>
weblogic.rmi.extensions.BasicRequestHandler.handleRequest(BasicRequestHandle
> > r.java:86)
> >
> > at
> >
>
weblogic.rmi.internal.BasicExecuteRequest.execute(BasicExecuteRequest.java:1
> > 5)
> >
> > at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:129)
> >
> >
> >
> >
> >
> >
> > --
> > Jiancai He
> > http://www.hefamily.com
> >
> >
>
>
-
Weblogic EJB 3 proxy & EJB 3 session bean interface
Does the weblogic EJB 3 session bean proxies implement the bean interface ?
I tried accessing the session bean from within a EJB 3 interceptor - InvocationContext.getTarget()
But it looks like this returns a proxy (created by weblogic internally) that does not implement the bean interface.
I'm unable to integrate Hibernate method validator as a result since the validator API expects the target to either be the actual bean implementation or at least a proxy
that implements the bean interfaces. Can somebody please confirm ?
I'm on weblogic 10.3
thanks!You should be able to see the code we generate by running the weblogic.appc utility on your application, specifying the "-keepgenerated" option to keep the Java source files.
-steve-
Maybe you are looking for
-
Report query XML schema error - Apex Listener 2
I built a simple query: select * from emp in (Shared components > Report Query) When I try to download XML schema for this query (Source Query section) resulting xsd file contains this text: String index out of range: -1 Shared Apex hosting: 4.2.2.0.
-
I want to exchange my Japan iTunes card to U.S.!
I want to exchange my Japan iTunes card to U.S.! Is there a way to do this???
-
I bought the new Apple 2 TB Time Capsule thinking it would be a great way to get a powerful wireless router and handle file backup for both me and my wife's iMacs. She is running an up-to-date version of Snow Leopard and I am on the most recent upda
-
My toyota Seinna 2011 refuses to connect with my Iphone 6 as a "portable player". Message says for me to adjust the player. On the phone it is searching for other devices but not connecting. Now same phone is paired with the car multimedia system
-
Customizing Appearance Available Window Themes/Color Schemes?
*_<Customizing Appearance> Available Window Themes/Color Schemes?_* I'm planning to get a MacBook Pro very soon. I have never used Mac OS, and I would like to know if it is possible to select custom window themes/color schemes? *I'm an old WinXP Vet,