I was studying this to understand the behavior of final fields in the new JMM (5 onwards). This concept is clear: guaranteed visibility of initialized final fields to all threads after the object is properly constructed.
But then at the end of the section, I read this, which simply confuses me:
Now, having said all of this, if, after a thread constructs an immutable object (that is, an object that only contains final fields), you want to ensure that it is seen correctly by all of the other thread, you still typically need to use synchronization. There is no other way to ensure, for example, that the reference to the immutable object will be seen by the second thread.
Does this means that though individual final fields (that compose an immutable object) do not have synchronization(say, visibility here) issues. But the immutable object itself when first created in a thread may not be visible (as properly created) in other threads?
If so, though we can share initialized immutable objects across threads without any thread-un-safe worries, but at the time of creation, they need 'special care' for thread safety just like for other mutables?