usha mocherla

Ranch Hand
+ Follow
since Sep 24, 2004
Cows and Likes
Total received
In last 30 days
Total given
Total received
Received in last 30 days
Total given
Given in last 30 days
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by usha mocherla

Just now started preparations for SCDJWS...

what I understood from previous posts is

J2EE web serives by Richard Monson Haefel is good for preparation.

Do I need to read the entire book?

please help me with your valueble suggestions.

Thanks in advance,

I guess option a is correct.

If a client receives 2 entity references from the same Home, it can determine whether they refer to the same or different beans by comparing

1. Their primary keys using the equals() method.

2. by comparing their references on isIdentical() method. (always use this method to compare references)

Note: you should never use == operator or equals method to compare two object references.
Got It,

issue exits only in CMT session beans.(statefull)
Hi friends,

I have a doubt regarding session synchronization.

1.statefull session beans only will implement sessionSynchronization interface.
2. container will use these 3 methods(afterbegin(),beforeCompletion(),afterCompletion) as call back methods to synchronize the state of the bean with database.
3. the purpose of implementing this interface, and using these methods will come in transactions.

Now my doubt is: when these methods will be used by container?

1. in Bean Managed transaction ?
2. or Container Managed Transactions?

please clear my doubt,

Thanks in advance.

I am developing a small email application in struts.I am unable to implement the "reply mail" logic.Here is my problem:
After getting a content of the mail from the subject from INBOX,i am putting the link to "reply.jsp" page.This page is similar to "Compose.jsp" where we compose our mail to send.The only difference is that we should get the "TO" address automatically when "reply.jsp" page is displayed.This "TO" address is the same "FROM" address whose content we intend to see from the subject from the "INBOX".
I am displaying my "INBOX" in "success.jsp" page.To see the content i am moving to "content.jsp",from where i need to go to the "reply.jsp".
How to get the "TO" address automatically in the text box in "reply.jsp" page?I am unable to solve this.
Can anybody help me please?Its urgent.

Thanks n regards
15 years ago
Hi all
I am trying to send the attachment but i am getting this exception.
Below is the detail exception:
Exception thrown in sendSending failed;
nested exception is:
javax.mail.MessagingException: IOException while sending message;
nested exception is: web1.xml (No such file or directory)

I am doing this application in the struts framework.When i am trying to run the logic in the simple java program,i have to give the complete path of the file and then it is taking the file,otherwise not.
In struts from the jsp page i am getting only filename and not the complete path.How to get the complete the complete path of the file from the jsp page.
To take the file name from the system i am using html:file tag.
Can anybody help me.
Thanks and regards
You can write javascript function behind each button and pass to the struts config file.On the click of each button javascript function will be called.
15 years ago
I am tring to implement JMS in struts.I started with displaying messages from my inbox.Now i am trying to download attachment by describing the logic of writing to file in action class.I am calling this action class through the following code in jsp:

<a href="<%=fname%>&inputstream=<%=istream%>"><font color="RED">Download</font></a></td>

I have following problem:I am unable to take the control to the action class defined in the struts config file,as i am unable to see the "system.out.println" in my console.

Can anybody help me please.

15 years ago
I am new user of java.
Can anybody help me in changing from string to InputStream.
This is following code:
String inputstream=request.getParameter("inputstream");
InputStream in=request.getParameter("inputstream");
It gives error "cannot convert from string to InputStream"
Plz help me.
15 years ago
Hi all,
can any body give me idea...I have a java class with me which I want to do unit test.On that class there is a method which takes input parameter as a result set...I am unable to find the way how to test it.Here I am giving the code for that method

public void setBlobList(OracleResultSet results,String labelname)
throws SQLException,FileNotFoundException,IOException{

Properties props = archiveFolderPath("");
//For Windows
File file = new File(props.getProperty("archivefolder")+"\\"+labelname);
//For Linux
//File file = new File(props.getProperty("archivefolder")+"/"+labelname);
while( {
String docid=""+results.getInt("docid");
oracle.sql.BLOB blb = (oracle.sql.BLOB)results.getBLOB("doccontent");
InputStream io = blb.getBinaryStream();
byte[] data = new byte[blb.getBufferSize()];;
//For Windows
File f=new File(props.getProperty("archivefolder")+"\\"+labelname+"\\"+results.getInt("docid")+"_"+results.getString("filename"));
//For Linux
//File f=new File(props.getProperty("archivefolder")+"/"+labelname+"/"+results.getInt("docid")+"_"+results.getString("filename"));
FileOutputStream fo=new FileOutputStream(f);
VTLArchiveBlob document = new VTLArchiveBlob(docid,f);
// add to document list

welcome for suggestions
16 years ago
I am new to LoadRunner tool.I am able to generate script successfully,but when I am trying to run the script following error is occuring:

"Error -27987: Requested image not found [MsgId: MERR-27987]
Action.c(100): web_image("greybullet.gif") highest severity level was "ERROR", 0 body bytes, 0 header bytes [MsgId: MMSG-26388]"

Because of this error I am not able to run the load test in the controller.If trying also it is ,obviously,giving all the action result as failed,contrary to the actual performance of the application.

Kindly help.
Thanx and Regards.
16 years ago
Thanks Sona
but i wanted to know the limit of the for looop which will be running for creating objects.
I think th e solution will work for general dynamically changing values.
I want to deal with "Objects".
Kindly let me know how to do this.
Thnaks in advance
16 years ago
I am trying to create array of objects.For that i have taken a constant number as the size of the array.
Now my requirement is that i want to change the number as per the requirement.
Can anybody help me how to change the "number" in number of objects dynamically.That is i want the program to take the number as required for creating the objects.
Thanks in advance
16 years ago
Hi Anup
I am thankful for your efforts,but sorry to say that even this is not working.
The page is going blank.
Is there any other option?If possible please let me know.
16 years ago
i m trying to write the following html:radio tag in two ways from which i m getting only one.

<td><html:radio property="criteria" value="sel1" />Select Date<a href="javascript:NewCal('seldate','ddmmyyyy')"> 
<img src="image-files/calendar_icon.gif" width="16" height="16" border="0" alt="Pick a date" /><input type="text" name="seldate"></td>

this code snoppet is working

due to the presence of <input> tag,it ia voilating struts i have to use <html:text> tag,which is not working.

<td><html:radio property="criteria" value="sel1" />Select Date<a href="javascript:NewCal('seldate','ddmmyyyy')"> 
<img src="image-files/calendar_icon.gif" width="16" height="16" border="0" alt="Pick a date" /><html:text property="sdate"/></td>

bcause of adding html:taxt tag,the page is not getting displayed and also not giving any error.

can anybody tell me the reason?
16 years ago