[JSR308] Concurrency annotations on blocks

Tom Ball Tom.Ball at Sun.COM
Sat Feb 3 00:37:10 EST 2007

Eugene Kuleshov wrote:
> Tom,
>  I can't speak for Intel, but from my practice, one example also not 
> mentioned in Java Concurrency in Practice is properties of the locking. 
> For instance read or write lock, optimistic vs. eager locking. It is too 
> coarse grained to express those on the method level only.

Wouldn't checking the java.util.concurrent class type or method usage 
tell you that?  I'm not arguing that those are important things to 
check, but am just trying to understand what the annotation adds that 
isn't already clearly expressed in the code.

>  regards,
>  Eugene
> Tom Ball wrote:
>> Intel's comment with their vote intrigued me:  that annotations on 
>> blocks and loops might be useful for specifying atomicity/concurrency 
>> assertions.  I believe most Java programmers don't have a full grasp 
>> of concurrency issues, and am interested in any thoughts this group 
>> might have regarding concurrency assertion ideas and what their 
>> annotations might look like.  We can start with the ones in Java 
>> Concurrency in Practice, since I doubt anyone would argue as to their 
>> importance.
>> Perhaps the best way past our logjam (uh oh, I may get spanked again 
>> ;-) is to come up with a conceptual set of cool assertion checkers 
>> whose annotations can't be placed (or can't be placed optimally), and 
>> then figure out how to remove those obstacles.  For me, the reward 
>> from working on JSRs isn't have fat specs published (and I doubt it is 
>> for anyone else), but their enabling of better technologies.  Having a 
>> new set of assertion checkers waiting to be written once this JSR is 
>> done is a strong motivator and focuser for me.
>> Tom
> _______________________________________________
> JSR308 mailing list
> JSR308 at lists.csail.mit.edu
> https://lists.csail.mit.edu/mailman/listinfo/jsr308

More information about the JSR308 mailing list