Most answers for [java] and [jvm]

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

9h
awarded Good Answer
18h
awarded Enlightened
18h
awarded Nice Answer
Jul
2
comment Memory problems with Java in the context of Hadoop
@Johannes true, but if you still need a explicit synchronizaton if you Iterate over it.
Jul
2
comment A guaranteed way to get source-order of member fields at runtime?
@Clashsoft This happens to be true, however, if just one field is not initialised this way, this won't be true and you won't know it's not true.
Jul
2
comment Why do heap memory usage and number of loaded classes keep increasing?
@DanielNewtown it's a good profiler, but I don't know how to integrate it with an IDE.
Jul
1
comment Monitoring the metrics of the API of Java application
sometimes it is easier to write a small piece of code than understand how some else's code works. I would write a simple JMX component to do this if I were you.
Jul
1
comment AtomicBitSet implementation for java
@Trejkaz good point though there is still a loop involved but you don't need to know this except for performance.
Jul
1
comment A guaranteed way to get source-order of member fields at runtime?
@Clash soft how so? Fields can be initialised in any order even if they are final.
Jul
1
comment Why do heap memory usage and number of loaded classes keep increasing?
@DanielNewton I would say that eclipse and visual vm are the third favourite IDE and profilers I come across. When I have used intellij with yourkit I haven't had a problem.
Jul
1
comment VisualVM is unable to profile a web application on Eclipse
Try running jvisualvm from the command line and attaching this to a running program. You can do the same with jmc or yourkit
Jul
1
comment Java method with return type compiles without return statement
The difference is whether the compiler can work whether you have an infinite loop or not based on the JLS.
Jun
29
answered Why do heap memory usage and number of loaded classes keep increasing?
Jun
29
comment AtomicBitSet implementation for java
@Trejkaz except you can't be sure to set a specific bit with an add operation. If two threads try to "set" 0b01 with an add operation, you will get 0b10
Jun
29
comment Convert a String to an enum in Java
@MurtazaKanchwala Can you clarify your comment? What are you trying to do?
Jun
29
comment Java Object[] and cache strading
@SvetlinZarev correct, however most of them will be so in terms of performance it will make little difference.
Jun
28
awarded Necromancer
Jun
27
comment Java Object[] and cache strading
@SvetlinZarev True, however, again the GC doesn't go out of it's way to arrange objects randomly in memory. Instead the order of discovery usually determines locality.
Jun
27
comment How to create a recursive function
This is a question better answered by the person setting the assignment. You can ask them why they want to use recursion when there is no good reason to do so.
Jun
27
answered Java Object[] and cache strading
1 2 3 4 5