Venkat Ramayanam

Greenhorn
+ Follow
since Apr 25, 2006
Merit badge: grant badges
For More
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 Venkat Ramayanam

Hi,
I am connecting to Teradata using Hibernate using the below connection URL
jdbc:teradata://IPAddress/TMODE=ANSI,CHARSET=UTF8
I am able to connect properly and do database operations.
Now my requirement is to connect using a DSN as my tables are scattred across different IP adresses.
What I mean by the above is for exmaple if i have 3 tables, table1 is on IPADDRESS1, table2 is on IPADDRESS2 and table3 is on IPADDRESS3 but all the tables are on the same Database.
So we have to use a DSN(??).
Please note that I am using only J2SE and no JNDI stuff.
Please let me know how to specify the DSN in the connection url.


Thanks in advance,
RV
[ November 28, 2008: Message edited by: Venkat Ramayanam ]
So We are not only making it completely thread safe but avoiding the performance hit at the same time by just synchronizing the necessary methods as against using a synchronized collection where its use is less.

Originally posted by Henry Wong:


Amit,

Peter is not saying that certain operations don't have to be synchronized -- I believe he is pointing out that just synchronization at the collection level is not enough.

For example, I have to iterate through the collection, in a thread safe manner. In this case, only getting the iterator is synchronized, which is not good enough. I have to synchronize at a higher scope -- getting the iterator, iterating through the values to calculate a result, and possibly placing the result back.

You have to look at what you are doing and synchronize accordingly -- not just synchronize a collection because it is used by many threads.

Henry

Hi,
We all know that Vector and Hashtable are synchronized while their counter parts ArrayList and HashMap are not.
Is there a way to synchronize their methods?
If so How?
I have been asked the same question by many interviewers.
First of all what is the need when you have the synchronized methods in Vector and ArrayList Classes.
Hi,
Pls could some one tell me how to find the size of an object??
I know that there is no sizeof operator in java,but is there any direct way of finding it out?
Does the following code accomplish the task?

java.lang.instrument.Instrumentation.getObjectSize(Object objectToSize)
17 years ago
Hi Vivek,
Can u pls send the PDF to rv_Narayana@yahoo.co.in??

Thanks in advance,
RV