GWT noDTO Distilled



   Francois Wauquier
        @wokier
      Artisan du SI
GWT

    Transcripteur Java->Javascript

    Widgets

    Outils de développement

    Code performant pour l'utilisateur
    
        Compression
    
        Découpage du code par navigateur/locale




Productivity for developers, performance for users
Google ? Web Toolkit
Ray Cromwell (Google representative and acting
 Committee Chair)
Artur Signell (Vaadin representative)
Mike Brock (RedHat representative)
David Chandler (Developer Advocate at Google)
Daniel Kurka (mgwt, gwt-phonegap)
Bhaskar Janakiraman (Google)
DTO


Serveur                                         Client

    MonEntite                            MonDTO




          Mais j'écris mes classes 2 fois !!!
DTO


Serveur                                          Client

    MonEntite                             MonDTO



  Dozer http://dozer.sourceforge.net/

  Setget Factory

  Reflection Factory (BeanUtils)

  Ubiquity http://larochef.github.io/ubiquity/
noDTO


Serveur               Client

          MonEntite
DTOs
Pros


    Isole

    Définit une API stable

    Sous-ensemble de
    l'entité pour
    
        les perf
    
        La sécurité

No source code is
 available for type…
DTOs
Pros                         Cons


    Isole                    
                                 Duplique

    Définit une API stable   
                                 Duplique

    Sous-ensemble de
    l'entité pour
                             
                                 Duplique
    
        les perf             
                                 Si l'API est publique
    
        La sécurité          
                                 Doit rester l'exception
No source code is
 available for type…
Lever les contraintes




       No DTO
Utilitaires

    Guava-gwt : Google common
https://code.google.com/p/guava-libraries/
Validation
• Bean-validation : contraintes
http://beanvalidation.org/
https://developers.google.com/web-toolkit/doc/latest/D
ToString Equals HashCode

    Lombock : Génération Code
http://projectlombok.org/


    GWT-TEH : Annotations
https://github.com/wokier/GWT-TEH
Persistance

    Objectify : Appengine BigTable
https://code.google.com/p/objectify-appengine/


    Gilead : Hibernate
http://sourceforge.net/projects/gilead/
Log

    GWT Logging
https://developers.google.com/web-toolkit/doc/latest/D


    GWT Usefull Logging
https://code.google.com/p/gwt-usefull-logging/


    gwt-log
https://code.google.com/p/gwt-log/
Conclusion
Performances

       No-dto
                Ubiquity                 Set-get Factory (à la main)

                               Reflection Factory
                           Dozer




                                                      Temps de dévelopement
Exemple
Demo
http://gwt-nodto-quickie.appspot.com/


Code
https://github.com/wokier/GwtNoDtoQuickie
Questions / Réponses
Merci
Francois Wauquier
     @wokier
   Artisan du SI

GWT no-dto

  • 1.
    GWT noDTO Distilled Francois Wauquier @wokier Artisan du SI
  • 2.
    GWT  Transcripteur Java->Javascript  Widgets  Outils de développement  Code performant pour l'utilisateur  Compression  Découpage du code par navigateur/locale Productivity for developers, performance for users
  • 3.
    Google ? WebToolkit Ray Cromwell (Google representative and acting Committee Chair) Artur Signell (Vaadin representative) Mike Brock (RedHat representative) David Chandler (Developer Advocate at Google) Daniel Kurka (mgwt, gwt-phonegap) Bhaskar Janakiraman (Google)
  • 5.
    DTO Serveur Client MonEntite MonDTO Mais j'écris mes classes 2 fois !!!
  • 7.
    DTO Serveur Client MonEntite MonDTO  Dozer http://dozer.sourceforge.net/  Setget Factory  Reflection Factory (BeanUtils)  Ubiquity http://larochef.github.io/ubiquity/
  • 9.
    noDTO Serveur Client MonEntite
  • 10.
    DTOs Pros  Isole  Définit une API stable  Sous-ensemble de l'entité pour  les perf  La sécurité No source code is available for type…
  • 11.
    DTOs Pros Cons  Isole  Duplique  Définit une API stable  Duplique  Sous-ensemble de l'entité pour  Duplique  les perf  Si l'API est publique  La sécurité  Doit rester l'exception No source code is available for type…
  • 12.
  • 14.
    Utilitaires  Guava-gwt : Google common https://code.google.com/p/guava-libraries/
  • 15.
    Validation • Bean-validation :contraintes http://beanvalidation.org/ https://developers.google.com/web-toolkit/doc/latest/D
  • 16.
    ToString Equals HashCode  Lombock : Génération Code http://projectlombok.org/  GWT-TEH : Annotations https://github.com/wokier/GWT-TEH
  • 17.
    Persistance  Objectify : Appengine BigTable https://code.google.com/p/objectify-appengine/  Gilead : Hibernate http://sourceforge.net/projects/gilead/
  • 18.
    Log  GWT Logging https://developers.google.com/web-toolkit/doc/latest/D  GWT Usefull Logging https://code.google.com/p/gwt-usefull-logging/  gwt-log https://code.google.com/p/gwt-log/
  • 20.
    Conclusion Performances No-dto Ubiquity Set-get Factory (à la main) Reflection Factory Dozer Temps de dévelopement
  • 21.
  • 22.
  • 23.
    Merci Francois Wauquier @wokier Artisan du SI