Anupam Kataki

Greenhorn
+ Follow
since Jul 27, 2001
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Anupam Kataki

If you are working on wls 6.x then hot deployment is possible . If your ejb has been packaged then go to the console ( to access http://machine ort/console ) .
Then look at EJB deployment .Further info can be obtained at http://e-docs.bea.com/wls/docs61/programming/index.html

Happy EJBing

Anupam Kataki
19 years ago
Hi there,
I am constructing a small application which needs 3 Entity beans and a session bean ( the session bean calls the entity beans ).
I have deployed the Entity beans individually , and can access them thru a client (java client) .
In my Session Bean I call the Entity beans in the following manner
Object ref = environment.lookup("java:comp/env/ejb/VispohdrHome"); hdrHome = (VispohdrHome)PortableRemoteObject.narrow(ref,VispohdrHome.class);
this implies that in my ejb-jar.xml I have to inclued the following reference information ..............
<ejb-ref>
<ejb-ref-name>ejb/VispocolorHome</ejb-ref-name>
<ejb-ref-type>Entity</ejb-ref-type>
<home>vism.masters.vispocolor.VispocolorHome</home>
<remote>vism.masters.vispocolor.Vispocolor</remote> </ejb-ref>
<ejb-ref>
<ejb-ref-name>ejb/VispohdrHome</ejb-ref-name>
<ejb-ref-type>Entity</ejb-ref-type>
<home>vism.masters.vispohdr.VispohdrHome</home>
<remote>vism.masters.vispohdr.Vispohdr</remote>
</ejb-ref>
<ejb-ref>
<ejb-ref-name>ejb/VispoetaHome</ejb-ref-name>
<ejb-ref-type>Entity</ejb-ref-type>
<home>vism.masters.vispoeta.VispoetaHome</home>
<remote>vism.masters.vispoeta.Vispoeta</remote>
</ejb-ref>
Now when i go to deploy my session bean , I get an error message saying that the EJB's mentioned in the <ejb-ref></ejb-ref> should be defined in the weblogic-ejb-jar.xml .
My question's Are
1) How do I inclued this information in the weblogic-ejb-jar.xml ( keep in mind that the Entity beans that the Session bean will access has already been deployed )?
2) Is There a better way to package the components ?

Thanking in advance
(Aanupam K)
19 years ago
Hi ,
I am having problem in accessing an EJB ( Entity Bean of 1.1 Standard ) deployed in Weblogic 6.1 server . Every time I try to access the EJB from a remote client I get the following error .
Unable to resolve jndiVisstdvariant. Resolved : ' ' Unresolved :'jndiVisstdvariant' .
Please help me to resolve this error .
Other Inputs
============
I believe this error is related to Jndi look up , but this
is exactely the name i gave to my entity bean (jndiVisstdvariant).
I am pasting the weblogic-ejb-jar.xml and ejb-jar.xml that I have created .
weblogic-ejb-jar.xml
====================
<?xml version="1.0"?>
<!DOCTYPE weblogic-ejb-jar PUBLIC '-//BEA Systems, Inc.//DTD WebLogic 5.1.0 EJB//EN' 'http://www.bea.com/servers/wls510/dtd/weblogic-ejb-jar.dtd'>
<weblogic-ejb-jar>
<weblogic-enterprise-bean>
<ejb-name>VisstdvariantBean</ejb-name>
<caching-descriptor>
<max-beans-in-cache>1000</max-beans-in-cache>
</caching-descriptor>
<persistence-descriptor>
<is-modified-method-name>isModified</is-modified-method-name>
<persistence-type>
<type-identifier>WebLogic_CMP_RDBMS</type-identifier>
<type-version>5.1.0</type-version>
<type-storage>META-INF/weblogic-cmp-rdbms-jar.xml</type-storage>
</persistence-type>
<persistence-use>
<type-identifier>WebLogic_CMP_RDBMS</type-identifier>
<type-version>5.1.0</type-version>
</persistence-use>
</persistence-descriptor>
<jndi-name>jndiVisstdvariant</jndi-name>
</weblogic-enterprise-bean>
</weblogic-ejb-jar>
ejb-jar.xml
============
<?xml version="1.0"?>
<!DOCTYPE ejb-jar PUBLIC '-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 1.1//EN' 'http://java.sun.com/j2ee/dtds/ejb-jar_1_1.dtd'>
<ejb-jar>
<enterprise-beans>
<entity>
<ejb-name>VisstdvariantBean</ejb-name>
<home>vism.masters.visstdvariant.VisstdvariantHome</home>
<remote>vism.masters.visstdvariant.Visstdvariant</remote>
<ejb-class>vism.masters.visstdvariant.VisstdvariantBean</ejb-class>
<persistence-type>Container</persistence-type>
<prim-key-class>java.lang.String</prim-key-class>
<reentrant>False</reentrant>
<cmp-field>
<field-name>variantCd</field-name>
</cmp-field>
<cmp-field>
<field-name>stdvarName</field-name>
</cmp-field>
<primkey-field>variantCd</primkey-field>
</entity>
</enterprise-beans>
<assembly-descriptor>
<container-transaction>
<method>
<ejb-name>VisstdvariantBean</ejb-name>
<method-name>*</method-name>
</method>
<trans-attribute>Required</trans-attribute>
</container-transaction>
</assembly-descriptor>
</ejb-jar>

Weblogic Server shows that the EJB is deployed .
Have I am going wrong somewhere ???

Anupam Kataki
19 years ago

Originally posted by Balaji Loganathan:
Hi,
Did anybody tried to test the new build.xml in weblogic server 6.1. I tried to do some changes on the samples/examples ejb files..but i don't how to build them up all using build.xml ...the documentation is asking us to use $ant ..the command is reconized by windows NT ..please help me how to use $ant in windows NT with web logic server 6.1
Regards
Balaji



Hi Balaji ,
Check out Build.cmd , this file actually helps you to build the examples . If you want a short cut , shut down the default server and start the examples server . In the example server the examples are pre loaded .

Anupam kataki
19 years ago
Hi Ranchers,
I wanted to know if it is possible to have comples conditions in the finder methods listed in a DD (I am Using Weblogic). For example
Complex Condition
==================
(finderDescriptors
"findByName(String name,String sname)" "(= name $name , =sname $sname)"
); end finderDescriptors
ANK