SlideShare una empresa de Scribd logo
1 de 44
Descargar para leer sin conexión
What’s new in Groovy 1.6?

Guillaume Laforge
Groovy Project Manager / SpringSource
Guillaume Laforge
Groovy Project Manager — SpringSource

  >   Working on Groovy since 2003
  >   JSR-241 Spec Lead

  >   Initiator of the Grails web framework

  >   Co-author of Groovy in Action

  >   Speaker: JavaOne, QCon, JavaPolis/Devoxx, JavaZone,
      Sun Tech Days, SpringOne/The Spring Experience, JAX,
      DSL DevCon, and more…


                                        2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone       2
                                                                                                                      2
What’s new in Groovy 1.6?
Article Published by InfoQ

  >   This presentation was prepared with the examples I’ve
      used in my article written for InfoQ

  >   http://www.infoq.com/articles/groovy-1-6

  >   Read this article for more detailed explanations of all the
      new features in Groovy 1.6




                                         2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone       3
                                                                                                                       3
Agenda
         >   Groovy Overview
         >   Performance Improvements
         >   Syntax Enhancements
         >   Compile-Time Metaprogramming
         >   The Grape Module System
         >   Swing-Related Improvements
         >   Runtime Metaprogramming Additions
         >   JSR-223 Scripting Engine Built-In
         >   JMX Builder
         >   OSGi Readiness




                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone       4
                                                                                                     4
Groovy in a Nutshell
Simplify the Life of Java Developers
   >   Groovy is a dynamic language for the Java Virtual
       Machine
          With a Meta-Object Protocol
          Compiles down to bytecode

   >   Open Source Apache licensed project

   >   Relaxed grammar derived from the Java 5 grammar
          Borrowed some good ideas from Smalltalk/Python/Ruby
          Java 5 features out of the box: annotations, generics, static
           imports, enums…
          Flat learning curve



                                               2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone       5
                                                                                                                             5
Features at a Glance
Lots More Than This!
  >   Fully Object-Oriented
  >   Joint compiler: seamless Java integration
  >   Closures: reusable blocks of code / anonymous functions
  >   Properties: forget about getters and setters
  >   Optional typing: your choice!
  >   BigDecimal arithmetic by default for floating point
  >   Handy APIs
       XML, JDBC, JMX, template engine, Swing UIs

  >   Strong ability for authoring Domain-Specific Languages
       Syntax-level “builders”

       Adding properties to numbers: 10.dollars

       Operator overloading: 10.meters + 20.kilometers



                                      2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone       6
                                                                                                                    6
A Taste of Groovy — Take 1
A Normal Java Program
  >   public class HelloWorld {
          private String name;
          public void setName(String name) {
              this.name = name;
          }
          public String getName() {
              return name;
          }
          public String greet() {
              return quot;Hello quot; + name;
          }
          public static void main(String[] args) {
              HelloWorld helloWorld = new HelloWorld();
              helloWorld.setName(quot;Groovyquot;);
              System.out.println( helloWorld.greet() );
          }
      }




                                               2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone       7
                                                                                                                             7
A Taste of Groovy — Take 2
A Valid Groovy Program
  >   public class HelloWorld {
          private String name;
          public void setName(String name) {
              this.name = name;
          }
          public String getName() {
              return name;
          }
          public String greet() {
              return quot;Hello quot; + name;
          }
          public static void main(String[] args) {
              HelloWorld helloWorld = new HelloWorld();
              helloWorld.setName(quot;Groovyquot;);
              System.out.println( helloWorld.greet() );
          }
      }




                                               2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone       8
                                                                                                                             8
A Taste of Groovy — Take 3
A Groovier Program!

  >   class HelloWorld {
          String name
          String greet() { quot;Hello $namequot; }
      }
      def helloWorld = new HelloWorld(name: quot;Groovyquot;)
      println helloWorld.greet()




                                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone       9
                                                                                                                     9
The Groovy Web Console
A Groovy Playground


  >   Groovy works nicely on Google App Engine
         You can also deploy Grails applications

  >   You can play with Groovy in the web console
         http://groovyconsole.appspot.com/




                                              2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    10
                                                                                                                            10
Agenda
         >   Groovy Overview
         >   Performance Improvements
         >   Syntax Enhancements
         >   Compile-Time Metaprogramming
         >   The Grape Module System
         >   Swing-Related Improvements
         >   Runtime Metaprogramming Additions
         >   JSR-223 Scripting Engine Built-In
         >   JMX Builder
         >   OSGi Readiness




                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    11
                                                                                                     11
Performance Improvements
Both Runtime & Compile-Time
  >   The Groovyc compiler is 3x to 5x faster
         With a clever class lookup cache

  >   Certain online micro-benchmarks show
      150% to 460% increase in performance
      compared to Groovy 1.5
         Thanks to advanced call-site caching techniques
         Beware of micro-benchmarks!

  >   Makes Groovy one of the fastest dynamic languages
      available



                                             2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    12
                                                                                                                           12
Agenda
         >   Groovy Overview
         >   Performance Improvements
         >   Syntax Enhancements
         >   Compile-Time Metaprogramming
         >   The Grape Module System
         >   Swing-Related Improvements
         >   Runtime Metaprogramming Additions
         >   JSR-223 Scripting Engine Built-In
         >   JMX Builder
         >   OSGi Readiness




                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    13
                                                                                                     13
Multiple Assignment
Assign Multiple Variables at Once
   >   Newly defined variables
          def (a, b) = [1, 2]
           assert a == 1
           assert b == 2

   >   Assign to existing variables
          def lat, lng
           (lat, lng) = geocode(‘Paris’)

   >   The classical swap case
          (a, b) = [b, a]

   >   Extra elements ⇒ not assigned to any variable
   >   Less elements ⇒ null into extra variables
                                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    14
                                                                                                                     14
More Optional Return
In if/else and try/catch Blocks
   >   The return keyword is optional for the last expression of
       a method body
        But if/else & try/catch didn’t return any value



   >   def method() { if (true) 1 else 0 }
       assert method() == 1

   >   def method(bool) {
           try {
               if (bool) throw new Exception(quot;fooquot;)
               1
           } catch(e) { 2 }
           finally    { 3 }
       }
       assert method(false) == 1
       assert method(true) == 2
                                        2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    15
                                                                                                                      15
Annotation Definition
The Missing Bit of Java 5 Support

   >   Groovy support for Java 5 features is now complete with
       the missing annotation definition

   >   Nothing to show here, it’s just normal Java :-)

   >   Note that the sole dynamic language supporting
       annotation is… Groovy
          Opens the door to EJB3 / JPA / Spring annotations / Guice /
           TestNG…




                                              2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    16
                                                                                                                            16
Agenda
         >   Groovy Overview
         >   Performance Improvements
         >   Syntax Enhancements
         >   Compile-Time Metaprogramming
         >   The Grape Module System
         >   Swing-Related Improvements
         >   Runtime Metaprogramming Additions
         >   JSR-223 Scripting Engine Built-In
         >   JMX Builder
         >   OSGi Readiness




                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    17
                                                                                                     17
Meta-What?
Meta-Programming
  >   The ability of a language to modify itself

  >   Groovy 1.6 introduces AST Transformations
         Abstract Syntax Tree

  >   Goodbye to a lot of boiler-plate technical code!

  >   Two kinds of transformations
         Global transformations
         Local transformations: triggered by annotations




                                              2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    18
                                                                                                                            18
AST Transformations in Groovy 1.6
Implement Patterns through Transformations
  >   Several transformations finds their way
         @Singleton — okay, not really a pattern ;-)
         @Immutable, @Lazy, @Delegate
         @Newify
         @Category and @Mixin
         @PackageScope
         Swing’s @Bindable and @Vetoable
         Grape’s @Grab

  >   Let’s have a look at some of them!




                                             2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    19
                                                                                                                           19
@Singleton
(Anti-)Pattern Revisited

   >   The evil Java singleton
          public class Evil {
               public static final Evil instance = new Evil ();
               private Evil () {}
               Evil getInstance() { return instance; }
           }

   >   In Groovy:
          @Singleton class Evil {}

   >   There’s also a « lazy » version
          @Singleton(lazy = true) class Evil {}



                                          2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    20
                                                                                                                        20
@Immutable
The Immutable… Boiler-Plate Code
  >   To properly implement immutable classes
         No mutators (state musn’t change)
         Private final fields
         Defensive copying of mutable components
         Proper equals() / hashCode() / toString() for
          comparisons or for keys in maps, etc.

  >   In Groovy
         @Immutable final class Coordinates {
              Double lat, lng
          }
          def c1 = new Coordinates(lat: 48.8, lng: 2.5)
          def c2 = new Coordinates(48.8, 2.5)
          assert c1 == c2
                                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    21
                                                                                                                     21
@Lazy
Not Just for Lazy Dudes!

   >   When you need to lazy evaluate / instantiate complex data
       structures for class fields, mark them as @Lazy

          class Dude {
               @Lazy pets = retriveFromSlowDB()
           }

   >   Groovy will handle the boiler-plate code for you




                                         2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    22
                                                                                                                       22
@Delegate
Not Just for Managers!

  >   You can delegate to fields of your class
         Think multiple inheritance
         class Employee {
              def doTheWork() { quot;donequot; }
          }
          class Manager {
              @Delegate
              Employee slave = new Employee()
          }
          def god = new Manager()
          assert god.doTheWork() == quot;donequot;

  >   Damn manager who will get all the praise…

                                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    23
                                                                                                                     23
Agenda
         >   Groovy Overview
         >   Performance Improvements
         >   Syntax Enhancements
         >   Compile-Time Metaprogramming
         >   The Grape Module System
         >   Swing-Related Improvements
         >   Runtime Metaprogramming Additions
         >   JSR-223 Scripting Engine Built-In
         >   JMX Builder
         >   OSGi Readiness




                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    24
                                                                                                     24
Grab a Grape
Groovy Advanced Packaging Engine
  >   Helps you distribute scripts without dependencies
  >   Just declare your dependencies with @Grab
         Will look for dependencies in Maven or Ivy repositories

  >   @Grab(group   = 'org.mortbay.jetty',
            module = 'jetty-embedded',
            version = '6.1.0')
      def startServer() {
          def srv = new Server(8080)
          def ctx = new Context(srv , quot;/quot;, SESSIONS);
          ctx.resourceBase = quot;.quot;
          ctx.addServlet(GroovyServlet, quot;*.groovyquot;)
          srv.start()
      }



                                            2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    25
                                                                                                                          25
Agenda
         >   Groovy Overview
         >   Performance Improvements
         >   Syntax Enhancements
         >   Compile-Time Metaprogramming
         >   The Grape Module System
         >   Swing-Related Improvements
         >   Runtime Metaprogramming Additions
         >   JSR-223 Scripting Engine Built-In
         >   JMX Builder
         >   OSGi Readiness




                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    26
                                                                                                     26
@Bindable (1/2)
Event-Driven Made Easy
  >   Speaking of boiler-plate code… property change listeners
  >


      import java.beans.PropertyChangeSupport;
      import java.beans.PropertyChangeListener;
      public class MyBean {
           private String prop;
           PropertyChangeSupport pcs = new PropertyChangeSupport(this);
           public void addPropertyChangeListener(PropertyChangeListener l) {
               pcs.add(l);
           }
           public void removePropertyChangeListener(PropertyChangeListener l) {
               pcs.remove(l);
           }

           public String getProp() {
               return prop;
            }

           public void setProp(String prop) {
                pcs.firePropertyChanged(quot;propquot;, this.prop, this.prop = prop);
            }
       }


                                                     2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    27
                                                                                                                                   27
@Bindable (2/2)
Event-Driven Made Easy
  >   Groovy’s solution
         class MyBean {
              @Bindable String prop
          }

  >   Interesting in Griffon and Swing builder
         textField text: bind { myBean.prop }

  >   Also of interest: @Vetoable




                                        2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    28
                                                                                                                      28
Griffon
The Swing MVC Framework

  >   Leverages Groovy’s SwingBuilder
      and Grails’ infrastructure
         http://griffon.codehaus.org

  >   Don’t miss the Griffon BOF!




                                        2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    29
                                                                                                                      29
Swing Console Improvements

  >   The console can be run as an applet
  >   Code indentation support
  >   Script drag’n drop
  >   Add JARs in the classpath from the GUI
  >   Execution results visualization plugin
  >   Clickable stacktraces and error messages

  >   Not intended to be a full-blown IDE, but handy




                                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    30
                                                                                                                     30
2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    31
                                                                              31
Agenda
         >   Groovy Overview
         >   Performance Improvements
         >   Syntax Enhancements
         >   Compile-Time Metaprogramming
         >   The Grape Module System
         >   Swing-Related Improvements
         >   Runtime Metaprogramming Additions
         >   JSR-223 Scripting Engine Built-In
         >   JMX Builder
         >   OSGi Readiness




                        2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    32
                                                                                                      32
ExpandoMetaClass DSL
Less Repetition
  >   EMC is a way to change the behavior of types at runtime

  >   Before
         Number.metaClass.multiply = { Amount amount ->
                  amount.times(delegate) }
          Number.metaClass.div = { Amount amount ->
                  amount.inverse().times(delegate) }


  >   Now in Groovy 1.6
         Number.metaClass {
            multiply { Amount amount -> amount.times(delegate) }
            div      { Amount amount ->
                       amount.inverse().times(delegate) }
          }




                                         2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    33
                                                                                                                       33
Runtime Mixins
Inject New Behavior to Types at Runtime

  >   class FlyingAbility {
          def fly() { quot;I'm ${name} and I fly!quot; }
      }

      class JamesBondVehicle {
          String getName() { quot;James Bond's vehiclequot; }
      }

      JamesBondVehicle.mixin FlyingAbility

      assert new JamesBondVehicle().fly() ==
          quot;I'm James Bond's vehicle and I fly!quot;



                                  2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    34
                                                                                                                34
Agenda
         >   Groovy Overview
         >   Performance Improvements
         >   Syntax Enhancements
         >   Compile-Time Metaprogramming
         >   The Grape Module System
         >   Swing-Related Improvements
         >   Runtime Metaprogramming Additions
         >   JSR-223 Scripting Engine Built-In
         >   JMX Builder
         >   OSGi Readiness




                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    35
                                                                                                     35
javax.script.* Scripting APIs
Groovy Scripting Engine Built-In
   >   In Groovy 1.6, the JSR-223 / javax.script.* scripting engine
       for Groovy is bundled

          import javax.script.*
           def manager = new ScriptEngineManager()
           def engine =
               manager.getEngineByName(quot;groovyquot;)
           assert engine.evaluate(quot;2 + 3quot;) == 5

   >   To evaluate Groovy scripts at runtime in your application,
       just drop the Groovy JAR in your classpath!



                                         2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    36
                                                                                                                       36
Agenda
         >   Groovy Overview
         >   Performance Improvements
         >   Syntax Enhancements
         >   Compile-Time Metaprogramming
         >   The Grape Module System
         >   Swing-Related Improvements
         >   Runtime Metaprogramming Additions
         >   JSR-223 Scripting Engine Built-In
         >   JMX Builder
         >   OSGi Readiness




                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    37
                                                                                                     37
JMX Builder (1/2)
Domain-Specific Language for JMX
  >   Simplify JMX handling with a Builder pattern approach
  >   Declaratively expose Java/Groovy objects as MBeans
  >   JMX's event model support
       Inline closures to create event handler & broadcaster

       Closures for receiving event notifications

  >   Provides a flexible registration policy for MBean
  >   Exposes attribute, constructors, operations, parameters,
      and notifications
  >   Simplified creation of connector servers & clients
  >   Support for exporting JMX timers

  >   http://groovy.codehaus.org/Groovy+JmxBuilder

                                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    38
                                                                                                                     38
JMX Builder (2/2)
Examples
   >   Create a connector server
          def jmx = new JmxBuilder()
           jmx.connectorServer(port:9000).start()
   >   Create a connector client
          jmx.connectorClient(port:9000).connect()
   >   Export a bean
          jmx.export { bean new MyService() }
   >   Defining a timer
          jmx.timer(name: quot;jmx.builder:type=Timerquot;,
               event: quot;heartbeatquot;, period: quot;1squot;).start()
   >   JMX listener
          jmx.listener(event: quot;…quot;, from: quot;fooquot;,
               call: { event -> …})


                                     2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    39
                                                                                                                   39
Agenda
         >   Groovy Overview
         >   Performance Improvements
         >   Syntax Enhancements
         >   Compile-Time Metaprogramming
         >   The Grape Module System
         >   Swing-Related Improvements
         >   Runtime Metaprogramming Additions
         >   JSR-223 Scripting Engine Built-In
         >   JMX Builder
         >   OSGi Readiness




                       2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    40
                                                                                                     40
OSGi Readiness

  >   The Groovy JAR contains OSGi metadata
         Can be reused in OSGi containers out-of-the-box

  >   Tutorials on Groovy and OSGi
       http://groovy.codehaus.org/OSGi+and+Groovy
         Will show you how to load Groovy as a service, write, publish and
          consume Groovy services, and more




                                              2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    41
                                                                                                                            41
Summary
Summary
Just Remember that Groovy Rocks! :-)
  >   Groovy 1.6 provides
         Important performance gains
         Efficient compile-time metaprogramming hooks
         New useful features (JMX, javax.script.*, etc.)
         A script dependencies system
         Various Swing-related improvements
         Several runtime metaprogramming additions

  >   Get it now!
         http://groovy.codehaus.org/Download




                                              2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone    43
                                                                                                                            43
What’s new in Groovy 1.6?




Guillaume Laforge
glaforge@gmail.com

Más contenido relacionado

La actualidad más candente

Gradle build tool that rocks with DSL JavaOne India 4th May 2012
Gradle build tool that rocks with DSL JavaOne India 4th May 2012Gradle build tool that rocks with DSL JavaOne India 4th May 2012
Gradle build tool that rocks with DSL JavaOne India 4th May 2012Rajmahendra Hegde
 
Develop Android app using Golang
Develop Android app using GolangDevelop Android app using Golang
Develop Android app using GolangSeongJae Park
 
60分鐘完送百萬edm,背後雲端ci/cd實戰大公開
60分鐘完送百萬edm,背後雲端ci/cd實戰大公開60分鐘完送百萬edm,背後雲端ci/cd實戰大公開
60分鐘完送百萬edm,背後雲端ci/cd實戰大公開KAI CHU CHUNG
 
Continuous Integration & Continuous Delivery with GCP
Continuous Integration & Continuous Delivery with GCPContinuous Integration & Continuous Delivery with GCP
Continuous Integration & Continuous Delivery with GCPKAI CHU CHUNG
 
Gradle 3.0: Unleash the Daemon!
Gradle 3.0: Unleash the Daemon!Gradle 3.0: Unleash the Daemon!
Gradle 3.0: Unleash the Daemon!Eric Wendelin
 
An Introduction to Gradle for Java Developers
An Introduction to Gradle for Java DevelopersAn Introduction to Gradle for Java Developers
An Introduction to Gradle for Java DevelopersKostas Saidis
 
Grailsx@ロンドンへ行ってきた報告。
Grailsx@ロンドンへ行ってきた報告。Grailsx@ロンドンへ行ってきた報告。
Grailsx@ロンドンへ行ってきた報告。Tsuyoshi Yamamoto
 
Develop Android/iOS app using golang
Develop Android/iOS app using golangDevelop Android/iOS app using golang
Develop Android/iOS app using golangSeongJae Park
 
コミュニティ開発に参加しよう!
コミュニティ開発に参加しよう!コミュニティ開発に参加しよう!
コミュニティ開発に参加しよう!Takahiro Itagaki
 
[Image Results] Java Build Tools: Part 2 - A Decision Maker's Guide Compariso...
[Image Results] Java Build Tools: Part 2 - A Decision Maker's Guide Compariso...[Image Results] Java Build Tools: Part 2 - A Decision Maker's Guide Compariso...
[Image Results] Java Build Tools: Part 2 - A Decision Maker's Guide Compariso...ZeroTurnaround
 
Gradle - time for a new build
Gradle - time for a new buildGradle - time for a new build
Gradle - time for a new buildIgor Khotin
 
Modern web applications infrastructure
Modern web applications infrastructureModern web applications infrastructure
Modern web applications infrastructureEPAM
 
Build and run embedded apps faster from qt creator with docker
Build and run embedded apps faster from qt creator with dockerBuild and run embedded apps faster from qt creator with docker
Build and run embedded apps faster from qt creator with dockerQt
 
NetBeans Support for EcmaScript 6
NetBeans Support for EcmaScript 6NetBeans Support for EcmaScript 6
NetBeans Support for EcmaScript 6Kostas Saidis
 
Gradle - the Enterprise Automation Tool
Gradle  - the Enterprise Automation ToolGradle  - the Enterprise Automation Tool
Gradle - the Enterprise Automation ToolIzzet Mustafaiev
 

La actualidad más candente (20)

Gradle build tool that rocks with DSL JavaOne India 4th May 2012
Gradle build tool that rocks with DSL JavaOne India 4th May 2012Gradle build tool that rocks with DSL JavaOne India 4th May 2012
Gradle build tool that rocks with DSL JavaOne India 4th May 2012
 
Develop Android app using Golang
Develop Android app using GolangDevelop Android app using Golang
Develop Android app using Golang
 
60分鐘完送百萬edm,背後雲端ci/cd實戰大公開
60分鐘完送百萬edm,背後雲端ci/cd實戰大公開60分鐘完送百萬edm,背後雲端ci/cd實戰大公開
60分鐘完送百萬edm,背後雲端ci/cd實戰大公開
 
Continuous Integration & Continuous Delivery with GCP
Continuous Integration & Continuous Delivery with GCPContinuous Integration & Continuous Delivery with GCP
Continuous Integration & Continuous Delivery with GCP
 
Gradle Introduction
Gradle IntroductionGradle Introduction
Gradle Introduction
 
Gradle 3.0: Unleash the Daemon!
Gradle 3.0: Unleash the Daemon!Gradle 3.0: Unleash the Daemon!
Gradle 3.0: Unleash the Daemon!
 
An Introduction to Gradle for Java Developers
An Introduction to Gradle for Java DevelopersAn Introduction to Gradle for Java Developers
An Introduction to Gradle for Java Developers
 
Grailsx@ロンドンへ行ってきた報告。
Grailsx@ロンドンへ行ってきた報告。Grailsx@ロンドンへ行ってきた報告。
Grailsx@ロンドンへ行ってきた報告。
 
Develop Android/iOS app using golang
Develop Android/iOS app using golangDevelop Android/iOS app using golang
Develop Android/iOS app using golang
 
Android presentation - Gradle ++
Android presentation - Gradle ++Android presentation - Gradle ++
Android presentation - Gradle ++
 
コミュニティ開発に参加しよう!
コミュニティ開発に参加しよう!コミュニティ開発に参加しよう!
コミュニティ開発に参加しよう!
 
[Image Results] Java Build Tools: Part 2 - A Decision Maker's Guide Compariso...
[Image Results] Java Build Tools: Part 2 - A Decision Maker's Guide Compariso...[Image Results] Java Build Tools: Part 2 - A Decision Maker's Guide Compariso...
[Image Results] Java Build Tools: Part 2 - A Decision Maker's Guide Compariso...
 
Gradle - time for a new build
Gradle - time for a new buildGradle - time for a new build
Gradle - time for a new build
 
Gradle presentation
Gradle presentationGradle presentation
Gradle presentation
 
Modern web applications infrastructure
Modern web applications infrastructureModern web applications infrastructure
Modern web applications infrastructure
 
Build and run embedded apps faster from qt creator with docker
Build and run embedded apps faster from qt creator with dockerBuild and run embedded apps faster from qt creator with docker
Build and run embedded apps faster from qt creator with docker
 
Tips & Tricks for Maven Tycho
Tips & Tricks for Maven TychoTips & Tricks for Maven Tycho
Tips & Tricks for Maven Tycho
 
NetBeans Support for EcmaScript 6
NetBeans Support for EcmaScript 6NetBeans Support for EcmaScript 6
NetBeans Support for EcmaScript 6
 
Streaming in grails
Streaming in grailsStreaming in grails
Streaming in grails
 
Gradle - the Enterprise Automation Tool
Gradle  - the Enterprise Automation ToolGradle  - the Enterprise Automation Tool
Gradle - the Enterprise Automation Tool
 

Destacado

Groovy to infinity and beyond - SpringOne2GX - 2010 - Guillaume Laforge
Groovy to infinity and beyond - SpringOne2GX - 2010 - Guillaume LaforgeGroovy to infinity and beyond - SpringOne2GX - 2010 - Guillaume Laforge
Groovy to infinity and beyond - SpringOne2GX - 2010 - Guillaume LaforgeGuillaume Laforge
 
Practical Groovy Domain-Specific Languages - Guillaume Laforge - Usi 2009
Practical Groovy Domain-Specific Languages - Guillaume Laforge - Usi 2009Practical Groovy Domain-Specific Languages - Guillaume Laforge - Usi 2009
Practical Groovy Domain-Specific Languages - Guillaume Laforge - Usi 2009Guillaume Laforge
 
Gaelyk - SpringOne2GX - 2010 - Guillaume Laforge
Gaelyk - SpringOne2GX - 2010 - Guillaume LaforgeGaelyk - SpringOne2GX - 2010 - Guillaume Laforge
Gaelyk - SpringOne2GX - 2010 - Guillaume LaforgeGuillaume Laforge
 
Google app-engine-cloudcamplagos2011
Google app-engine-cloudcamplagos2011Google app-engine-cloudcamplagos2011
Google app-engine-cloudcamplagos2011Opevel
 
Groovy workshop à Mix-IT 2013
Groovy workshop à Mix-IT 2013Groovy workshop à Mix-IT 2013
Groovy workshop à Mix-IT 2013Guillaume Laforge
 
Lift off with Groovy 2 at JavaOne 2013
Lift off with Groovy 2 at JavaOne 2013Lift off with Groovy 2 at JavaOne 2013
Lift off with Groovy 2 at JavaOne 2013Guillaume Laforge
 
Les nouveautés de Groovy 2 -- Mix-IT 2013
Les nouveautés de Groovy 2 -- Mix-IT 2013Les nouveautés de Groovy 2 -- Mix-IT 2013
Les nouveautés de Groovy 2 -- Mix-IT 2013Guillaume Laforge
 

Destacado (8)

Groovy to infinity and beyond - SpringOne2GX - 2010 - Guillaume Laforge
Groovy to infinity and beyond - SpringOne2GX - 2010 - Guillaume LaforgeGroovy to infinity and beyond - SpringOne2GX - 2010 - Guillaume Laforge
Groovy to infinity and beyond - SpringOne2GX - 2010 - Guillaume Laforge
 
Practical Groovy Domain-Specific Languages - Guillaume Laforge - Usi 2009
Practical Groovy Domain-Specific Languages - Guillaume Laforge - Usi 2009Practical Groovy Domain-Specific Languages - Guillaume Laforge - Usi 2009
Practical Groovy Domain-Specific Languages - Guillaume Laforge - Usi 2009
 
Gaelyk - SpringOne2GX - 2010 - Guillaume Laforge
Gaelyk - SpringOne2GX - 2010 - Guillaume LaforgeGaelyk - SpringOne2GX - 2010 - Guillaume Laforge
Gaelyk - SpringOne2GX - 2010 - Guillaume Laforge
 
Google app-engine-cloudcamplagos2011
Google app-engine-cloudcamplagos2011Google app-engine-cloudcamplagos2011
Google app-engine-cloudcamplagos2011
 
Groovy 2 and beyond
Groovy 2 and beyondGroovy 2 and beyond
Groovy 2 and beyond
 
Groovy workshop à Mix-IT 2013
Groovy workshop à Mix-IT 2013Groovy workshop à Mix-IT 2013
Groovy workshop à Mix-IT 2013
 
Lift off with Groovy 2 at JavaOne 2013
Lift off with Groovy 2 at JavaOne 2013Lift off with Groovy 2 at JavaOne 2013
Lift off with Groovy 2 at JavaOne 2013
 
Les nouveautés de Groovy 2 -- Mix-IT 2013
Les nouveautés de Groovy 2 -- Mix-IT 2013Les nouveautés de Groovy 2 -- Mix-IT 2013
Les nouveautés de Groovy 2 -- Mix-IT 2013
 

Similar a Whats New In Groovy 1.6?

Introduction to Groovy and what's New in Groovy 1.6 - SpringOne Europe 2009
Introduction to Groovy and what's New in Groovy 1.6 - SpringOne Europe 2009Introduction to Groovy and what's New in Groovy 1.6 - SpringOne Europe 2009
Introduction to Groovy and what's New in Groovy 1.6 - SpringOne Europe 2009Guillaume Laforge
 
Groovy And Grails Introduction
Groovy And Grails IntroductionGroovy And Grails Introduction
Groovy And Grails IntroductionEric Weimer
 
Groovy in the Enterprise - Case Studies - TSSJS Prague 2008 - Guillaume Laforge
Groovy in the Enterprise - Case Studies - TSSJS Prague 2008 - Guillaume LaforgeGroovy in the Enterprise - Case Studies - TSSJS Prague 2008 - Guillaume Laforge
Groovy in the Enterprise - Case Studies - TSSJS Prague 2008 - Guillaume LaforgeGuillaume Laforge
 
GR8Conf 2009: What's New in Groovy 1.6? by Guillaume Laforge
GR8Conf 2009: What's New in Groovy 1.6? by Guillaume LaforgeGR8Conf 2009: What's New in Groovy 1.6? by Guillaume Laforge
GR8Conf 2009: What's New in Groovy 1.6? by Guillaume LaforgeGR8Conf
 
Griffon - Making Swing Fun Again
Griffon - Making Swing Fun AgainGriffon - Making Swing Fun Again
Griffon - Making Swing Fun AgainDanno Ferrin
 
SF JUG - GWT Can Help You Create Amazing Apps - 2009-10-13
SF JUG - GWT Can Help You Create Amazing Apps - 2009-10-13SF JUG - GWT Can Help You Create Amazing Apps - 2009-10-13
SF JUG - GWT Can Help You Create Amazing Apps - 2009-10-13Fred Sauer
 
Groovy and Grails in Action - Devoxx 2008 - University - Guillaume Laforge
Groovy and Grails in Action - Devoxx 2008 - University - Guillaume LaforgeGroovy and Grails in Action - Devoxx 2008 - University - Guillaume Laforge
Groovy and Grails in Action - Devoxx 2008 - University - Guillaume LaforgeGuillaume Laforge
 
Groovy Finesse
Groovy FinesseGroovy Finesse
Groovy Finessemzgubin
 
Groovy Finesse
Groovy FinesseGroovy Finesse
Groovy Finessemzgubin
 
Write microservice in golang
Write microservice in golangWrite microservice in golang
Write microservice in golangBo-Yi Wu
 
Go for Mobile Games
Go for Mobile GamesGo for Mobile Games
Go for Mobile GamesTakuya Ueda
 
Javascript as a target language - GWT KickOff - Part 2/2
Javascript as a target language - GWT KickOff - Part 2/2Javascript as a target language - GWT KickOff - Part 2/2
Javascript as a target language - GWT KickOff - Part 2/2JooinK
 
JavaOne2015-What's in an Object?
JavaOne2015-What's in an Object?JavaOne2015-What's in an Object?
JavaOne2015-What's in an Object?Charlie Gracie
 
#JavaOne What's in an object?
#JavaOne What's in an object?#JavaOne What's in an object?
#JavaOne What's in an object?Charlie Gracie
 
Gretty: Managing Web Containers with Gradle
Gretty: Managing Web Containers with GradleGretty: Managing Web Containers with Gradle
Gretty: Managing Web Containers with GradleAndrey Hihlovsky
 

Similar a Whats New In Groovy 1.6? (20)

Whats New In Groovy 1.6?
Whats New In Groovy 1.6?Whats New In Groovy 1.6?
Whats New In Groovy 1.6?
 
What's New in Groovy 1.6?
What's New in Groovy 1.6?What's New in Groovy 1.6?
What's New in Groovy 1.6?
 
Introduction to Groovy and what's New in Groovy 1.6 - SpringOne Europe 2009
Introduction to Groovy and what's New in Groovy 1.6 - SpringOne Europe 2009Introduction to Groovy and what's New in Groovy 1.6 - SpringOne Europe 2009
Introduction to Groovy and what's New in Groovy 1.6 - SpringOne Europe 2009
 
Groovy And Grails Introduction
Groovy And Grails IntroductionGroovy And Grails Introduction
Groovy And Grails Introduction
 
Groovy & Grails
Groovy & GrailsGroovy & Grails
Groovy & Grails
 
Groovy in the Enterprise - Case Studies - TSSJS Prague 2008 - Guillaume Laforge
Groovy in the Enterprise - Case Studies - TSSJS Prague 2008 - Guillaume LaforgeGroovy in the Enterprise - Case Studies - TSSJS Prague 2008 - Guillaume Laforge
Groovy in the Enterprise - Case Studies - TSSJS Prague 2008 - Guillaume Laforge
 
GR8Conf 2009: What's New in Groovy 1.6? by Guillaume Laforge
GR8Conf 2009: What's New in Groovy 1.6? by Guillaume LaforgeGR8Conf 2009: What's New in Groovy 1.6? by Guillaume Laforge
GR8Conf 2009: What's New in Groovy 1.6? by Guillaume Laforge
 
Griffon - Making Swing Fun Again
Griffon - Making Swing Fun AgainGriffon - Making Swing Fun Again
Griffon - Making Swing Fun Again
 
SF JUG - GWT Can Help You Create Amazing Apps - 2009-10-13
SF JUG - GWT Can Help You Create Amazing Apps - 2009-10-13SF JUG - GWT Can Help You Create Amazing Apps - 2009-10-13
SF JUG - GWT Can Help You Create Amazing Apps - 2009-10-13
 
Groovy and Grails in Action - Devoxx 2008 - University - Guillaume Laforge
Groovy and Grails in Action - Devoxx 2008 - University - Guillaume LaforgeGroovy and Grails in Action - Devoxx 2008 - University - Guillaume Laforge
Groovy and Grails in Action - Devoxx 2008 - University - Guillaume Laforge
 
Groovy Finesse
Groovy FinesseGroovy Finesse
Groovy Finesse
 
Groovy Finesse
Groovy FinesseGroovy Finesse
Groovy Finesse
 
Write microservice in golang
Write microservice in golangWrite microservice in golang
Write microservice in golang
 
Groovy
GroovyGroovy
Groovy
 
Go for Mobile Games
Go for Mobile GamesGo for Mobile Games
Go for Mobile Games
 
OpenLogic
OpenLogicOpenLogic
OpenLogic
 
Javascript as a target language - GWT KickOff - Part 2/2
Javascript as a target language - GWT KickOff - Part 2/2Javascript as a target language - GWT KickOff - Part 2/2
Javascript as a target language - GWT KickOff - Part 2/2
 
JavaOne2015-What's in an Object?
JavaOne2015-What's in an Object?JavaOne2015-What's in an Object?
JavaOne2015-What's in an Object?
 
#JavaOne What's in an object?
#JavaOne What's in an object?#JavaOne What's in an object?
#JavaOne What's in an object?
 
Gretty: Managing Web Containers with Gradle
Gretty: Managing Web Containers with GradleGretty: Managing Web Containers with Gradle
Gretty: Managing Web Containers with Gradle
 

Más de Guillaume Laforge

Groovy 2.0 update at Devoxx 2012
Groovy 2.0 update at Devoxx 2012Groovy 2.0 update at Devoxx 2012
Groovy 2.0 update at Devoxx 2012Guillaume Laforge
 
Groovy Domain Specific Languages - SpringOne2GX 2012
Groovy Domain Specific Languages - SpringOne2GX 2012Groovy Domain Specific Languages - SpringOne2GX 2012
Groovy Domain Specific Languages - SpringOne2GX 2012Guillaume Laforge
 
Groovy update at SpringOne2GX 2012
Groovy update at SpringOne2GX 2012Groovy update at SpringOne2GX 2012
Groovy update at SpringOne2GX 2012Guillaume Laforge
 
Groovy 1.8 et 2.0 au BreizhC@mp 2012
Groovy 1.8 et 2.0 au BreizhC@mp 2012Groovy 1.8 et 2.0 au BreizhC@mp 2012
Groovy 1.8 et 2.0 au BreizhC@mp 2012Guillaume Laforge
 
Groovy 1.8 and 2.0 at GR8Conf Europe 2012
Groovy 1.8 and 2.0 at GR8Conf Europe 2012Groovy 1.8 and 2.0 at GR8Conf Europe 2012
Groovy 1.8 and 2.0 at GR8Conf Europe 2012Guillaume Laforge
 
Groovy 2.0 update - Cloud Foundry Open Tour Moscow - Guillaume Laforge
Groovy 2.0 update - Cloud Foundry Open Tour Moscow - Guillaume LaforgeGroovy 2.0 update - Cloud Foundry Open Tour Moscow - Guillaume Laforge
Groovy 2.0 update - Cloud Foundry Open Tour Moscow - Guillaume LaforgeGuillaume Laforge
 
Going to Mars with Groovy Domain-Specific Languages
Going to Mars with Groovy Domain-Specific LanguagesGoing to Mars with Groovy Domain-Specific Languages
Going to Mars with Groovy Domain-Specific LanguagesGuillaume Laforge
 
Groovy 2.0 - Devoxx France 2012
Groovy 2.0 - Devoxx France 2012Groovy 2.0 - Devoxx France 2012
Groovy 2.0 - Devoxx France 2012Guillaume Laforge
 
Groovy Update, new in 1.8 and beyond - Guillaume Laforge - Devoxx 2011
Groovy Update, new in 1.8 and beyond - Guillaume Laforge - Devoxx 2011Groovy Update, new in 1.8 and beyond - Guillaume Laforge - Devoxx 2011
Groovy Update, new in 1.8 and beyond - Guillaume Laforge - Devoxx 2011Guillaume Laforge
 
GPars et PrettyTime - Paris JUG 2011 - Guillaume Laforge
GPars et PrettyTime - Paris JUG 2011 - Guillaume LaforgeGPars et PrettyTime - Paris JUG 2011 - Guillaume Laforge
GPars et PrettyTime - Paris JUG 2011 - Guillaume LaforgeGuillaume Laforge
 
Groovy Update - Guillaume Laforge - Greach 2011
Groovy Update - Guillaume Laforge - Greach 2011Groovy Update - Guillaume Laforge - Greach 2011
Groovy Update - Guillaume Laforge - Greach 2011Guillaume Laforge
 
Gaelyk update - Guillaume Laforge - SpringOne2GX 2011
Gaelyk update - Guillaume Laforge - SpringOne2GX 2011Gaelyk update - Guillaume Laforge - SpringOne2GX 2011
Gaelyk update - Guillaume Laforge - SpringOne2GX 2011Guillaume Laforge
 
Groovy Update, what's new in Groovy 1.8 and beyond - Guillaume Laforge - Spri...
Groovy Update, what's new in Groovy 1.8 and beyond - Guillaume Laforge - Spri...Groovy Update, what's new in Groovy 1.8 and beyond - Guillaume Laforge - Spri...
Groovy Update, what's new in Groovy 1.8 and beyond - Guillaume Laforge - Spri...Guillaume Laforge
 
Groovy DSLs, from Beginner to Expert - Guillaume Laforge and Paul King - Spri...
Groovy DSLs, from Beginner to Expert - Guillaume Laforge and Paul King - Spri...Groovy DSLs, from Beginner to Expert - Guillaume Laforge and Paul King - Spri...
Groovy DSLs, from Beginner to Expert - Guillaume Laforge and Paul King - Spri...Guillaume Laforge
 
Cloud foundry intro with groovy
Cloud foundry intro with groovyCloud foundry intro with groovy
Cloud foundry intro with groovyGuillaume Laforge
 
Groovy update - S2GForum London 2011 - Guillaume Laforge
Groovy update - S2GForum London 2011 - Guillaume LaforgeGroovy update - S2GForum London 2011 - Guillaume Laforge
Groovy update - S2GForum London 2011 - Guillaume LaforgeGuillaume Laforge
 
Groovy DSLs - S2GForum London 2011 - Guillaume Laforge
Groovy DSLs - S2GForum London 2011 - Guillaume LaforgeGroovy DSLs - S2GForum London 2011 - Guillaume Laforge
Groovy DSLs - S2GForum London 2011 - Guillaume LaforgeGuillaume Laforge
 

Más de Guillaume Laforge (20)

Groovy 2.0 update at Devoxx 2012
Groovy 2.0 update at Devoxx 2012Groovy 2.0 update at Devoxx 2012
Groovy 2.0 update at Devoxx 2012
 
Groovy 2.0 webinar
Groovy 2.0 webinarGroovy 2.0 webinar
Groovy 2.0 webinar
 
Groovy Domain Specific Languages - SpringOne2GX 2012
Groovy Domain Specific Languages - SpringOne2GX 2012Groovy Domain Specific Languages - SpringOne2GX 2012
Groovy Domain Specific Languages - SpringOne2GX 2012
 
Groovy update at SpringOne2GX 2012
Groovy update at SpringOne2GX 2012Groovy update at SpringOne2GX 2012
Groovy update at SpringOne2GX 2012
 
JavaOne 2012 Groovy update
JavaOne 2012 Groovy updateJavaOne 2012 Groovy update
JavaOne 2012 Groovy update
 
Groovy 1.8 et 2.0 au BreizhC@mp 2012
Groovy 1.8 et 2.0 au BreizhC@mp 2012Groovy 1.8 et 2.0 au BreizhC@mp 2012
Groovy 1.8 et 2.0 au BreizhC@mp 2012
 
Groovy 1.8 and 2.0 at GR8Conf Europe 2012
Groovy 1.8 and 2.0 at GR8Conf Europe 2012Groovy 1.8 and 2.0 at GR8Conf Europe 2012
Groovy 1.8 and 2.0 at GR8Conf Europe 2012
 
Groovy 2.0 update - Cloud Foundry Open Tour Moscow - Guillaume Laforge
Groovy 2.0 update - Cloud Foundry Open Tour Moscow - Guillaume LaforgeGroovy 2.0 update - Cloud Foundry Open Tour Moscow - Guillaume Laforge
Groovy 2.0 update - Cloud Foundry Open Tour Moscow - Guillaume Laforge
 
Going to Mars with Groovy Domain-Specific Languages
Going to Mars with Groovy Domain-Specific LanguagesGoing to Mars with Groovy Domain-Specific Languages
Going to Mars with Groovy Domain-Specific Languages
 
Groovy 2.0 - Devoxx France 2012
Groovy 2.0 - Devoxx France 2012Groovy 2.0 - Devoxx France 2012
Groovy 2.0 - Devoxx France 2012
 
Whats new in Groovy 2.0?
Whats new in Groovy 2.0?Whats new in Groovy 2.0?
Whats new in Groovy 2.0?
 
Groovy Update, new in 1.8 and beyond - Guillaume Laforge - Devoxx 2011
Groovy Update, new in 1.8 and beyond - Guillaume Laforge - Devoxx 2011Groovy Update, new in 1.8 and beyond - Guillaume Laforge - Devoxx 2011
Groovy Update, new in 1.8 and beyond - Guillaume Laforge - Devoxx 2011
 
GPars et PrettyTime - Paris JUG 2011 - Guillaume Laforge
GPars et PrettyTime - Paris JUG 2011 - Guillaume LaforgeGPars et PrettyTime - Paris JUG 2011 - Guillaume Laforge
GPars et PrettyTime - Paris JUG 2011 - Guillaume Laforge
 
Groovy Update - Guillaume Laforge - Greach 2011
Groovy Update - Guillaume Laforge - Greach 2011Groovy Update - Guillaume Laforge - Greach 2011
Groovy Update - Guillaume Laforge - Greach 2011
 
Gaelyk update - Guillaume Laforge - SpringOne2GX 2011
Gaelyk update - Guillaume Laforge - SpringOne2GX 2011Gaelyk update - Guillaume Laforge - SpringOne2GX 2011
Gaelyk update - Guillaume Laforge - SpringOne2GX 2011
 
Groovy Update, what's new in Groovy 1.8 and beyond - Guillaume Laforge - Spri...
Groovy Update, what's new in Groovy 1.8 and beyond - Guillaume Laforge - Spri...Groovy Update, what's new in Groovy 1.8 and beyond - Guillaume Laforge - Spri...
Groovy Update, what's new in Groovy 1.8 and beyond - Guillaume Laforge - Spri...
 
Groovy DSLs, from Beginner to Expert - Guillaume Laforge and Paul King - Spri...
Groovy DSLs, from Beginner to Expert - Guillaume Laforge and Paul King - Spri...Groovy DSLs, from Beginner to Expert - Guillaume Laforge and Paul King - Spri...
Groovy DSLs, from Beginner to Expert - Guillaume Laforge and Paul King - Spri...
 
Cloud foundry intro with groovy
Cloud foundry intro with groovyCloud foundry intro with groovy
Cloud foundry intro with groovy
 
Groovy update - S2GForum London 2011 - Guillaume Laforge
Groovy update - S2GForum London 2011 - Guillaume LaforgeGroovy update - S2GForum London 2011 - Guillaume Laforge
Groovy update - S2GForum London 2011 - Guillaume Laforge
 
Groovy DSLs - S2GForum London 2011 - Guillaume Laforge
Groovy DSLs - S2GForum London 2011 - Guillaume LaforgeGroovy DSLs - S2GForum London 2011 - Guillaume Laforge
Groovy DSLs - S2GForum London 2011 - Guillaume Laforge
 

Último

My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationRidwan Fadjar
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Drew Madelung
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxMalak Abu Hammad
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Servicegiselly40
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure servicePooja Nehwal
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountPuma Security, LLC
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsMaria Levchenko
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024Results
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfEnterprise Knowledge
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersThousandEyes
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking MenDelhi Call girls
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Miguel Araújo
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)Gabriella Davis
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreternaman860154
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsEnterprise Knowledge
 

Último (20)

My Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 PresentationMy Hashitalk Indonesia April 2024 Presentation
My Hashitalk Indonesia April 2024 Presentation
 
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
Strategies for Unlocking Knowledge Management in Microsoft 365 in the Copilot...
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
The Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptxThe Codex of Business Writing Software for Real-World Solutions 2.pptx
The Codex of Business Writing Software for Real-World Solutions 2.pptx
 
CNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of ServiceCNv6 Instructor Chapter 6 Quality of Service
CNv6 Instructor Chapter 6 Quality of Service
 
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure serviceWhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
WhatsApp 9892124323 ✓Call Girls In Kalyan ( Mumbai ) secure service
 
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
#StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Breaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path MountBreaking the Kubernetes Kill Chain: Host Path Mount
Breaking the Kubernetes Kill Chain: Host Path Mount
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024A Call to Action for Generative AI in 2024
A Call to Action for Generative AI in 2024
 
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdfThe Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
The Role of Taxonomy and Ontology in Semantic Layers - Heather Hedden.pdf
 
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for PartnersEnhancing Worker Digital Experience: A Hands-on Workshop for Partners
Enhancing Worker Digital Experience: A Hands-on Workshop for Partners
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 

Whats New In Groovy 1.6?

  • 1. What’s new in Groovy 1.6? Guillaume Laforge Groovy Project Manager / SpringSource
  • 2. Guillaume Laforge Groovy Project Manager — SpringSource > Working on Groovy since 2003 > JSR-241 Spec Lead > Initiator of the Grails web framework > Co-author of Groovy in Action > Speaker: JavaOne, QCon, JavaPolis/Devoxx, JavaZone, Sun Tech Days, SpringOne/The Spring Experience, JAX, DSL DevCon, and more… 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 2 2
  • 3. What’s new in Groovy 1.6? Article Published by InfoQ > This presentation was prepared with the examples I’ve used in my article written for InfoQ > http://www.infoq.com/articles/groovy-1-6 > Read this article for more detailed explanations of all the new features in Groovy 1.6 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 3 3
  • 4. Agenda > Groovy Overview > Performance Improvements > Syntax Enhancements > Compile-Time Metaprogramming > The Grape Module System > Swing-Related Improvements > Runtime Metaprogramming Additions > JSR-223 Scripting Engine Built-In > JMX Builder > OSGi Readiness 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 4 4
  • 5. Groovy in a Nutshell Simplify the Life of Java Developers > Groovy is a dynamic language for the Java Virtual Machine  With a Meta-Object Protocol  Compiles down to bytecode > Open Source Apache licensed project > Relaxed grammar derived from the Java 5 grammar  Borrowed some good ideas from Smalltalk/Python/Ruby  Java 5 features out of the box: annotations, generics, static imports, enums…  Flat learning curve 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 5 5
  • 6. Features at a Glance Lots More Than This! > Fully Object-Oriented > Joint compiler: seamless Java integration > Closures: reusable blocks of code / anonymous functions > Properties: forget about getters and setters > Optional typing: your choice! > BigDecimal arithmetic by default for floating point > Handy APIs  XML, JDBC, JMX, template engine, Swing UIs > Strong ability for authoring Domain-Specific Languages  Syntax-level “builders”  Adding properties to numbers: 10.dollars  Operator overloading: 10.meters + 20.kilometers 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 6 6
  • 7. A Taste of Groovy — Take 1 A Normal Java Program > public class HelloWorld { private String name; public void setName(String name) { this.name = name; } public String getName() { return name; } public String greet() { return quot;Hello quot; + name; } public static void main(String[] args) { HelloWorld helloWorld = new HelloWorld(); helloWorld.setName(quot;Groovyquot;); System.out.println( helloWorld.greet() ); } } 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 7 7
  • 8. A Taste of Groovy — Take 2 A Valid Groovy Program > public class HelloWorld { private String name; public void setName(String name) { this.name = name; } public String getName() { return name; } public String greet() { return quot;Hello quot; + name; } public static void main(String[] args) { HelloWorld helloWorld = new HelloWorld(); helloWorld.setName(quot;Groovyquot;); System.out.println( helloWorld.greet() ); } } 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 8 8
  • 9. A Taste of Groovy — Take 3 A Groovier Program! > class HelloWorld { String name String greet() { quot;Hello $namequot; } } def helloWorld = new HelloWorld(name: quot;Groovyquot;) println helloWorld.greet() 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 9 9
  • 10. The Groovy Web Console A Groovy Playground > Groovy works nicely on Google App Engine  You can also deploy Grails applications > You can play with Groovy in the web console  http://groovyconsole.appspot.com/ 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 10 10
  • 11. Agenda > Groovy Overview > Performance Improvements > Syntax Enhancements > Compile-Time Metaprogramming > The Grape Module System > Swing-Related Improvements > Runtime Metaprogramming Additions > JSR-223 Scripting Engine Built-In > JMX Builder > OSGi Readiness 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 11 11
  • 12. Performance Improvements Both Runtime & Compile-Time > The Groovyc compiler is 3x to 5x faster  With a clever class lookup cache > Certain online micro-benchmarks show 150% to 460% increase in performance compared to Groovy 1.5  Thanks to advanced call-site caching techniques  Beware of micro-benchmarks! > Makes Groovy one of the fastest dynamic languages available 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 12 12
  • 13. Agenda > Groovy Overview > Performance Improvements > Syntax Enhancements > Compile-Time Metaprogramming > The Grape Module System > Swing-Related Improvements > Runtime Metaprogramming Additions > JSR-223 Scripting Engine Built-In > JMX Builder > OSGi Readiness 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 13 13
  • 14. Multiple Assignment Assign Multiple Variables at Once > Newly defined variables  def (a, b) = [1, 2] assert a == 1 assert b == 2 > Assign to existing variables  def lat, lng (lat, lng) = geocode(‘Paris’) > The classical swap case  (a, b) = [b, a] > Extra elements ⇒ not assigned to any variable > Less elements ⇒ null into extra variables 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 14 14
  • 15. More Optional Return In if/else and try/catch Blocks > The return keyword is optional for the last expression of a method body  But if/else & try/catch didn’t return any value > def method() { if (true) 1 else 0 } assert method() == 1 > def method(bool) { try { if (bool) throw new Exception(quot;fooquot;) 1 } catch(e) { 2 } finally { 3 } } assert method(false) == 1 assert method(true) == 2 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 15 15
  • 16. Annotation Definition The Missing Bit of Java 5 Support > Groovy support for Java 5 features is now complete with the missing annotation definition > Nothing to show here, it’s just normal Java :-) > Note that the sole dynamic language supporting annotation is… Groovy  Opens the door to EJB3 / JPA / Spring annotations / Guice / TestNG… 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 16 16
  • 17. Agenda > Groovy Overview > Performance Improvements > Syntax Enhancements > Compile-Time Metaprogramming > The Grape Module System > Swing-Related Improvements > Runtime Metaprogramming Additions > JSR-223 Scripting Engine Built-In > JMX Builder > OSGi Readiness 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 17 17
  • 18. Meta-What? Meta-Programming > The ability of a language to modify itself > Groovy 1.6 introduces AST Transformations  Abstract Syntax Tree > Goodbye to a lot of boiler-plate technical code! > Two kinds of transformations  Global transformations  Local transformations: triggered by annotations 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 18 18
  • 19. AST Transformations in Groovy 1.6 Implement Patterns through Transformations > Several transformations finds their way  @Singleton — okay, not really a pattern ;-)  @Immutable, @Lazy, @Delegate  @Newify  @Category and @Mixin  @PackageScope  Swing’s @Bindable and @Vetoable  Grape’s @Grab > Let’s have a look at some of them! 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 19 19
  • 20. @Singleton (Anti-)Pattern Revisited > The evil Java singleton  public class Evil { public static final Evil instance = new Evil (); private Evil () {} Evil getInstance() { return instance; } } > In Groovy:  @Singleton class Evil {} > There’s also a « lazy » version  @Singleton(lazy = true) class Evil {} 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 20 20
  • 21. @Immutable The Immutable… Boiler-Plate Code > To properly implement immutable classes  No mutators (state musn’t change)  Private final fields  Defensive copying of mutable components  Proper equals() / hashCode() / toString() for comparisons or for keys in maps, etc. > In Groovy  @Immutable final class Coordinates { Double lat, lng } def c1 = new Coordinates(lat: 48.8, lng: 2.5) def c2 = new Coordinates(48.8, 2.5) assert c1 == c2 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 21 21
  • 22. @Lazy Not Just for Lazy Dudes! > When you need to lazy evaluate / instantiate complex data structures for class fields, mark them as @Lazy  class Dude { @Lazy pets = retriveFromSlowDB() } > Groovy will handle the boiler-plate code for you 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 22 22
  • 23. @Delegate Not Just for Managers! > You can delegate to fields of your class  Think multiple inheritance  class Employee { def doTheWork() { quot;donequot; } } class Manager { @Delegate Employee slave = new Employee() } def god = new Manager() assert god.doTheWork() == quot;donequot; > Damn manager who will get all the praise… 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 23 23
  • 24. Agenda > Groovy Overview > Performance Improvements > Syntax Enhancements > Compile-Time Metaprogramming > The Grape Module System > Swing-Related Improvements > Runtime Metaprogramming Additions > JSR-223 Scripting Engine Built-In > JMX Builder > OSGi Readiness 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 24 24
  • 25. Grab a Grape Groovy Advanced Packaging Engine > Helps you distribute scripts without dependencies > Just declare your dependencies with @Grab  Will look for dependencies in Maven or Ivy repositories > @Grab(group = 'org.mortbay.jetty', module = 'jetty-embedded', version = '6.1.0') def startServer() { def srv = new Server(8080) def ctx = new Context(srv , quot;/quot;, SESSIONS); ctx.resourceBase = quot;.quot; ctx.addServlet(GroovyServlet, quot;*.groovyquot;) srv.start() } 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 25 25
  • 26. Agenda > Groovy Overview > Performance Improvements > Syntax Enhancements > Compile-Time Metaprogramming > The Grape Module System > Swing-Related Improvements > Runtime Metaprogramming Additions > JSR-223 Scripting Engine Built-In > JMX Builder > OSGi Readiness 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 26 26
  • 27. @Bindable (1/2) Event-Driven Made Easy > Speaking of boiler-plate code… property change listeners > import java.beans.PropertyChangeSupport; import java.beans.PropertyChangeListener; public class MyBean { private String prop; PropertyChangeSupport pcs = new PropertyChangeSupport(this); public void addPropertyChangeListener(PropertyChangeListener l) { pcs.add(l); } public void removePropertyChangeListener(PropertyChangeListener l) { pcs.remove(l); } public String getProp() { return prop; } public void setProp(String prop) { pcs.firePropertyChanged(quot;propquot;, this.prop, this.prop = prop); } } 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 27 27
  • 28. @Bindable (2/2) Event-Driven Made Easy > Groovy’s solution  class MyBean { @Bindable String prop } > Interesting in Griffon and Swing builder  textField text: bind { myBean.prop } > Also of interest: @Vetoable 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 28 28
  • 29. Griffon The Swing MVC Framework > Leverages Groovy’s SwingBuilder and Grails’ infrastructure  http://griffon.codehaus.org > Don’t miss the Griffon BOF! 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 29 29
  • 30. Swing Console Improvements > The console can be run as an applet > Code indentation support > Script drag’n drop > Add JARs in the classpath from the GUI > Execution results visualization plugin > Clickable stacktraces and error messages > Not intended to be a full-blown IDE, but handy 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 30 30
  • 31. 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 31 31
  • 32. Agenda > Groovy Overview > Performance Improvements > Syntax Enhancements > Compile-Time Metaprogramming > The Grape Module System > Swing-Related Improvements > Runtime Metaprogramming Additions > JSR-223 Scripting Engine Built-In > JMX Builder > OSGi Readiness 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 32 32
  • 33. ExpandoMetaClass DSL Less Repetition > EMC is a way to change the behavior of types at runtime > Before  Number.metaClass.multiply = { Amount amount -> amount.times(delegate) } Number.metaClass.div = { Amount amount -> amount.inverse().times(delegate) } > Now in Groovy 1.6  Number.metaClass { multiply { Amount amount -> amount.times(delegate) } div { Amount amount -> amount.inverse().times(delegate) } } 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 33 33
  • 34. Runtime Mixins Inject New Behavior to Types at Runtime > class FlyingAbility { def fly() { quot;I'm ${name} and I fly!quot; } } class JamesBondVehicle { String getName() { quot;James Bond's vehiclequot; } } JamesBondVehicle.mixin FlyingAbility assert new JamesBondVehicle().fly() == quot;I'm James Bond's vehicle and I fly!quot; 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 34 34
  • 35. Agenda > Groovy Overview > Performance Improvements > Syntax Enhancements > Compile-Time Metaprogramming > The Grape Module System > Swing-Related Improvements > Runtime Metaprogramming Additions > JSR-223 Scripting Engine Built-In > JMX Builder > OSGi Readiness 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 35 35
  • 36. javax.script.* Scripting APIs Groovy Scripting Engine Built-In > In Groovy 1.6, the JSR-223 / javax.script.* scripting engine for Groovy is bundled  import javax.script.* def manager = new ScriptEngineManager() def engine = manager.getEngineByName(quot;groovyquot;) assert engine.evaluate(quot;2 + 3quot;) == 5 > To evaluate Groovy scripts at runtime in your application, just drop the Groovy JAR in your classpath! 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 36 36
  • 37. Agenda > Groovy Overview > Performance Improvements > Syntax Enhancements > Compile-Time Metaprogramming > The Grape Module System > Swing-Related Improvements > Runtime Metaprogramming Additions > JSR-223 Scripting Engine Built-In > JMX Builder > OSGi Readiness 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 37 37
  • 38. JMX Builder (1/2) Domain-Specific Language for JMX > Simplify JMX handling with a Builder pattern approach > Declaratively expose Java/Groovy objects as MBeans > JMX's event model support  Inline closures to create event handler & broadcaster  Closures for receiving event notifications > Provides a flexible registration policy for MBean > Exposes attribute, constructors, operations, parameters, and notifications > Simplified creation of connector servers & clients > Support for exporting JMX timers > http://groovy.codehaus.org/Groovy+JmxBuilder 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 38 38
  • 39. JMX Builder (2/2) Examples > Create a connector server  def jmx = new JmxBuilder() jmx.connectorServer(port:9000).start() > Create a connector client  jmx.connectorClient(port:9000).connect() > Export a bean  jmx.export { bean new MyService() } > Defining a timer  jmx.timer(name: quot;jmx.builder:type=Timerquot;, event: quot;heartbeatquot;, period: quot;1squot;).start() > JMX listener  jmx.listener(event: quot;…quot;, from: quot;fooquot;, call: { event -> …}) 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 39 39
  • 40. Agenda > Groovy Overview > Performance Improvements > Syntax Enhancements > Compile-Time Metaprogramming > The Grape Module System > Swing-Related Improvements > Runtime Metaprogramming Additions > JSR-223 Scripting Engine Built-In > JMX Builder > OSGi Readiness 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 40 40
  • 41. OSGi Readiness > The Groovy JAR contains OSGi metadata  Can be reused in OSGi containers out-of-the-box > Tutorials on Groovy and OSGi  http://groovy.codehaus.org/OSGi+and+Groovy  Will show you how to load Groovy as a service, write, publish and consume Groovy services, and more 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 41 41
  • 43. Summary Just Remember that Groovy Rocks! :-) > Groovy 1.6 provides  Important performance gains  Efficient compile-time metaprogramming hooks  New useful features (JMX, javax.script.*, etc.)  A script dependencies system  Various Swing-related improvements  Several runtime metaprogramming additions > Get it now!  http://groovy.codehaus.org/Download 2009 CommunityOne Conference: EAST | developers.sun.com/events/communityone 43 43
  • 44. What’s new in Groovy 1.6? Guillaume Laforge glaforge@gmail.com