Third for [java] and second for [concurrency]

First to get the silver [jvm] badge, second to gold [performance] badge.

answered Why the main thread is blocked
comment Collections hierarchy should be Collection (Read Only) -> ModifiableCollection
If you pass a mutable collection to a method which assumes it's immutable, but you change this collection elsewhere in code, possibly in another thread. Then its not really immutable, just that the callee can't change it, unless the method with the immutable reference casts it to a mutable one ...
comment When can threads enter synchronised methods?
Perhaps you could explain what you doubt is and this would lead to a more informed answer. I suggest you read the Javadoc for Object, and it will explain the second answer.
revised Adding additional methods for a thread in Java?
added 2 characters in body
comment Float and double datatype in java
I have used 4 byte and even 2 byte fixed precision numbers to save memory, but unless you have billions of these it is unlikely to be worth it. The time it takes you to write "double" instead of "float" (it has one more letter) is worth 1000x more than the extra memory you use, but if using double rather than float saves you from a precision related bug, it is worth it.
answered format date in groovy and save in desired format with milliseconds
comment Typecast Object type to user defined POJO in java
If you give these objects the same parent interface, it will make it simpler to work with both types without duplicating your code.
answered Java - Millions of records, HashMap throws OutOfMemoryError
answered Adding additional methods for a thread in Java?
comment How to print max and min value?
Each of the wrapper types has a MIN_VALUE and MAX_VALUE, except Boolean, Void and the MIN_VALUE of float and double is the smallest positive value.
comment how to implement a data aware cache using java application ? If possible can i get the source code?
There is many examples of open source caches from the simple to the complex. Usually these caches have their own eviction strategies. You need to do more research as you what you actually need to give a sensible answer. Most likely you can re-use one of the many free caches. like ehcache or hazelcast.
comment i wrote this code and it was not working
@siddo To include the code, you copy-and-paste it, then press the {} to include code. To get an answer, you need to ask a question. Before you ask a question about a bug I suggest you try using your debugger as this is what it is for.
revised i wrote this code and it was not working
added 18 characters in body
comment Exception in java thread
Why are you using a thread if you don't want it to run independently?
answered Exception in java thread
answered Can I log/save All Assert statment result after execution?
answered Avoiding promotion failed in Java CMS GC
comment Ljava.lang.Object; cannot be cast to [Ljava.lang.Integer
Can you show us the line where this happens as neither of these lines need to have a class cast exception.
comment Generating all binary numbers based on the pattern
@shekharsuman cheers.
answered What information does a serialized object store?
1 2 3 4 5