[concurrency-interest] java fork-join getting-started notes for beginners <-> Java 7

Rémi Forax forax at univ-mlv.fr
Thu Aug 18 16:20:56 EDT 2011


Eclipse Indigo's compiler is not updated for Java 7,
all language enhancements of Java 7 are not recognized,
that's why you have this warning, the release 3.7.1 (not yet release) 
should be Ok,
you can already test the compiler behaviour by installing the 3.8M1.

Rémi

On 08/18/2011 09:56 PM, Doug Lea wrote:
> On 08/16/11 18:00, Dan Grossman wrote:
>> Short version:
>>
>> I'm looking for quick confirmation that using the fork-join framework
>> with the Java 7 JRE is just as easy as it seems and that I'm pointing
>> students to the right stable versions of things.
>
> I'm still hoping that someone else replies about most of this,
> since I normally experimental run releases without IDE support.
> But otherwise -- yes, things should Just Work.
>
> -Doug
>
>>
>> Long version:
>>
>> Background:
>>
>> As I've mentioned on this list a couple times, I've developed a
>> course-unit for second-year undergraduates that introduces parallelism
>> and concurrency using Java and the Fork-Join Framework (though it's
>> not really that Java-specific).  At Washington, we've used this unit
>> in our required data-structures course for 1.5 years now and it's been
>> picked up by 5 other schools so far.  In all, 10 instructors, most
>> non-experts in Java, parallelism, or both have used it and they all
>> claim success and, "I will do this again."  For more information,
>> http://www.cs.washington.edu/homes/djg/teachingMaterials/spac/
>>
>> One thing that has proven absolutely essential is step-by-step
>> instructions suitable for beginners, specialized to just what they
>> need: ForkJoinPool, RecursiveTask, RecursiveAction.  This was
>> particularly important for Java 1.6.  The url
>> http://www.cs.washington.edu/homes/djg/teachingMaterials/spac/grossmanSPAC_forkJoinFramework.html 
>>
>> has these instructions and was last updated a few months ago.  For
>> those of you who have not taught undergraduates, let me assure you
>> that there are, nonetheless, a mind-boggling number of ways to enter
>> -Xbootclasspath/p:jsr166.jar incorrectly. :-)
>>
>> So what now:
>>
>> It seems time to update my step-by-step instructions to say:
>>    1. Please use Java 7 following steps a, b, c.
>>    2. If you really can't, then here are the more complicated steps for
>> using Java 6 following steps, d, e, f, g.
>>
>> In preparation for this, I downloaded JDK 7 onto a [Windows 7, 64-bit]
>> machine that has never had Java on it, installed Eclipse IDE for Java
>> Developers, indigo release (my instructions prefer but don't mandate
>> eclipse), set the Java Project JRE to JavaSE-1.7, and ran the attached
>> file.  It Just Worked.  This is So Wonderful and I send my heartfelt
>> appreciation to everyone on this list who helped make it happen.
>>
>> Now my questions -- I think the answers are all 'yes' but this is the
>> place to confirm and I'm most concerned about (C):
>>
>> A. Java 7: Is this the real deal -- the framework will use the
>> available processors and, after suitable VM warmup, be the parallel
>> execution engine we expect?
>>
>> B. Installation: Will upgrading on machines that already have Java 6
>> be just as seamless?
>>
>> C. Code: Is the attached file the way to show things to beginners?
>> (Note: My point is to show them the reduction explicitly rather than
>> using a library method.  This is for pedagogical purposes.  So no
>> complaining about that.)
>>
>> D. Eclipse: When choosing JavaSE1-1.7, Eclipse Indigo release warns,
>> "The 1.7 compiler compliance level
>>     is not yet supported.  The new project will use a project specific
>> compiler compliance level of 1.6".  Am I correct that this can be
>> ignored since I'm not using any new /language/ features, just a new
>> /library/? (Note: My understanding is there are Eclipse versions
>> available with 1.7 compilers, but if we're okay with the most standard
>> most stable Eclipse release, this is extremely helpful.)
>>
>> E: Anything else I can do to make this as bullet-proof for beginners
>> as possible?
>>
>> Thanks!
>>
>> --Dan
>>
>>
>>
>> _______________________________________________
>> Concurrency-interest mailing list
>> Concurrency-interest at cs.oswego.edu
>> http://cs.oswego.edu/mailman/listinfo/concurrency-interest
>
> _______________________________________________
> Concurrency-interest mailing list
> Concurrency-interest at cs.oswego.edu
> http://cs.oswego.edu/mailman/listinfo/concurrency-interest



More information about the Concurrency-interest mailing list