Re: Kotin, mutability, reactor and thread-safety (JMM actually)

2020-04-19 Thread yawkat
Hey, Am Sonntag, 19. April 2020 14:00:06 UTC+2 schrieb Jacob P: > > Thanks a lot for your response. It seems that I understand everything, but > some doubts appear so if you can look at my thoughts, please. > > > >> Finally, if there are parallel executions of doOnNext and you are >> mutating

Re: Kotin, mutability, reactor and thread-safety (JMM actually)

2020-04-19 Thread yawkat
Hi, With many high-level APIs there are no solid specified happens-before relations. However, there are two reasons that point towards the code being thread-safe: - The parameters are all captured variables. This means they are final in the anonymous class:

Re: Happens before between putting and getting from and to ConcurrentHashMap

2018-11-18 Thread yawkat
According to JCIP, a happens-before order also constitutes a safe publication of the objects involved. Since there is a HB edge between the put and the get, this leads to a safe publication of the object stored in the map (safe publication is another JCIP term). JCIP also mentions CM

Re: Happens before between putting and getting from and to ConcurrentHashMap

2018-11-17 Thread yawkat
I don't think this is correct. First of all, it's not really relevant if String is immutable or not, in this case: It could already break at the (non-final, non-volatile) field x, which could be null if an instance of P was unsafely published. Of course, String being immutable has the

Re: Pushing Terrabytes of files across a WAN

2018-09-14 Thread yawkat
UDT ( https://en.wikipedia.org/wiki/UDP-based_Data_Transfer_Protocol ) was made exactly for this purpose, but I'm not familiar with how well it works as a standalone tool. Am Donnerstag, 13. September 2018 22:15:23 UTC+2 schrieb Jay Askren: > > Todd Montgomvery, > > Correct, robocopy uses TCP.