bval-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Romain Manni-Bucau <rmannibu...@gmail.com>
Subject Re: copy annotations in multithreaded environments
Date Sat, 22 Oct 2016 09:13:18 GMT
it is when the model is built so in a thread safe manner (enclosing code),
no?


Romain Manni-Bucau
@rmannibucau <https://twitter.com/rmannibucau> |  Blog
<https://blog-rmannibucau.rhcloud.com> | Old Wordpress Blog
<http://rmannibucau.wordpress.com> | Github <https://github.com/rmannibucau> |
LinkedIn <https://www.linkedin.com/in/rmannibucau> | Tomitriber
<http://www.tomitribe.com> | JavaEE Factory
<https://javaeefactory-rmannibucau.rhcloud.com>

2016-10-22 10:59 GMT+02:00 Mark Struberg <struberg@yahoo.de.invalid>:

> Hi!
>
> Just stumbled across the following code which is not thread safe. Do we
> need this?
> Or can we assume that this happens in a single thread anyway?
>
> public void addAnnotation(final Annotation annotation) {
> this.annotations = ArrayUtils.add(annotations, annotation);
> }
>
> LieGrue,
> strub

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message