SlideShare une entreprise Scribd logo
1  sur  27
Télécharger pour lire hors ligne
Scalate
      Introducing	
  the	
  Scala	
  Template	
  Engine
      James	
  Strachan,	
  FuseSource




                                                                                                                                                                    A	
  Progress	
  So3ware	
  Company
      1         Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
               A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Your	
  presenter	
  is:	
  James	
  Strachan


        James	
  Strachan
             • james@fusesource.com
             • twi1er:	
  @jstrachan
             • blog:	
  h1p://macstrac.blogspot.com/
        So3ware	
  Fellow	
  at	
  FuseSource
        long	
  term	
  Open	
  Source	
  contributor
             • created	
  Apache	
  Camel
             • created	
  the	
  Groovy	
  programming	
  language
             • co-­‐founder	
  of
                    –Apache	
  Ac6veMQ,	
  Camel,	
  ServiceMix,	
  Fabric,	
  ...
                    –Scalate

      2         Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
FuseSource	
  -­‐	
  experts	
  in	
  open	
  source	
  integra6on	
  and	
  messaging

                	
     FuseSource	
  sponsors	
  projects	
  at	
  the	
  Apache	
  So3ware	
  Founda6on


                                                                    CXF                                                                        JAX-WS, WS-*, REST
                                                                                                                                          for Web and Restful Integration


                                                                                                                                             Enterprise Messaging,
                                                                ActiveMQ                                                             multi platform and language support,
                                                                                                                                            JMS,STOMP,AMQP1.0,
                                                                                                                                      Highly available and fault tolerant



                                                                   Camel                                                                   Enterprise Integration Patterns
                                                                                                                                                     framework




                                                               ServiceMix                                                                      Enterprise Service Bus,
                                                                                                                                          distributed,clustered, OSGi, JBI




                                                                     Karaf                                                            OSGi based container, supporting
                                                                                                                                       multiple archive types, remote
                                                                                                                                     management, dynamic configuration,
                                                                                                                                               extensible shell



        3        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
             A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Some	
  recommended	
  books...




                Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Agenda




       scala	
  and	
  me
       scalate	
  overview
       geQng	
  started
       Q	
  &	
  A

      5         Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Scala	
  and	
  me




      6         Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Scalate	
  Overview




        its	
  a	
  Scala	
  based	
  Template	
  Engine
          • Scala	
  	
  T	
  E	
  =>	
  scalate
        h1p://scalate.fusesource.org/




      7         Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Design	
  Goals




        make	
  an	
  awesome	
  template	
  engine	
  
             • framework	
  &	
  container	
  agnosJc
        support	
  different	
  template	
  flavours	
  under	
  same	
  API
             • there	
  isn’t	
  really	
  a	
  one	
  size	
  fits	
  all
        reuse	
  the	
  power	
  &	
  type	
  safety	
  of	
  Scala
             • catch	
  errors	
  in	
  templates	
  at	
  edit/build	
  Jme
                    – templates	
  are	
  for	
  life,	
  not	
  just	
  for	
  Christmas!
             • IDE	
  friendly	
  for	
  smart	
  compleJon



      8         Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Features


        Templates	
  are	
  compiled	
  &	
  cached	
  as	
  fast	
  Scala	
  objects
        Template	
  objects	
  are	
  staJcally	
  typed	
  to	
  catch	
  typos
             • apart	
  from	
  Mustache
        Scalate	
  is	
  equivalent	
  to	
  the	
  combinaJon	
  of	
  JSP,	
  JSTL,	
  JSP	
  EL	
  
         &	
  SiteMesh/Tiles
             • Scala	
  replaces	
  JSP	
  EL	
  and	
  Scala	
  funcJons	
  replace	
  JSP	
  custom	
  tags
             • Scalate	
  template	
  languages	
  are	
  richer,	
  more	
  powerful	
  &	
  usually	
  more	
  
               DRY	
  than	
  JSP	
  +	
  JSTL
             • Scalate	
  has	
  in	
  built	
  layout	
  support	
  replacing	
  SiteMesh/Titles




      9         Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
How	
  Scalate	
  works


        TemplateEngine	
  is	
  used	
  to	
  load	
  Templates
             • typically	
  templates	
  are	
  converted	
  into	
  scala	
  code	
  and	
  compiled	
  to	
  
               avoid	
  runJme	
  parsing
             • can	
  customize	
  various	
  things...
                    – caching	
  &	
  reloading
                    – how	
  URIs	
  are	
  resolved	
  (classpath,	
  file	
  system	
  etc)
                    – interna6onalisa6on
        RenderContext	
  is	
  used	
  to	
  render	
  a	
  template
             • has	
  a	
  Map[String,Any]	
  like	
  set	
  of	
  a1ributes	
  for	
  passing/sharing	
  state
             • loads	
  of	
  helper	
  methods	
  for	
  use	
  inside	
  the	
  template
                    – localisa6on,	
  including	
  other	
  templates,	
  views,	
  layouts	
  etc
        template	
  languages	
  implemented	
  using	
  Scala	
  parser	
  
         generators

      10        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Scalate	
  Template	
  Languages


          SSP
          Scaml
          Jade
          Mustache
          Scuery




      11        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
SSP


        SSP	
  “Scala	
  Server	
  Pages”	
  
             • like	
  a	
  non-­‐sucky	
  JSP	
  :)
        easiest	
  template	
  engine	
  to	
  start	
  with	
  if	
  folks	
  know
             • ASP,	
  JSP,	
  GSP,	
  Erb,	
  Velocity,	
  FreeMarker	
  style	
  templates
        supports	
  JSP	
  /	
  Erb	
  style	
  syntax	
  
             • <%	
  statements	
  %>
             • <%=	
  expression	
  %>
             • ${expression}
        examples:
             • Dear	
  ${people.map(_.name).mkString(“,	
  “)}	
  how	
  are	
  you?




      12        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
SSP	
  also	
  supports	
  Velocity	
  style	
  tokens


           #if	
  (lineItems.find(_.price	
  >	
  10).isDefined)
           	
  	
  <b>Welcome	
  big	
  spender!</b>
           #end




      13        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Scaml


        Scaml	
  is	
  a	
  Scala	
  port	
  of	
  HAML
             • HAML	
  started	
  in	
  the	
  Rails	
  world	
  and	
  became	
  a	
  very	
  popular	
  alternaJve	
  
               to	
  Erb	
  templates
             • whitespace	
  sensiJve	
  (which	
  is	
  handy	
  for	
  markup,	
  avoids	
  badly	
  nested	
  
               markup)
             • uses	
  %foo	
  to	
  indicate	
  <foo>...</foo>
             • -­‐	
  for	
  statements
             • =	
  expressions




      14        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Jade


        Jade	
  out	
  in	
  JavaScript	
  /	
  Rails	
  worlds	
  as	
  a	
  simpler	
  more	
  DRY	
  
         version	
  of	
  HAML	
  /	
  Scaml	
  
             • avoid	
  the	
  %	
  to	
  indicate	
  element	
  name
                    – folks	
  tend	
  to	
  use	
  lots	
  of	
  elements;	
  few	
  are	
  mul6-­‐line	
  text	
  content
             • use	
  |	
  to	
  indicate	
  text	
  content	
  inside	
  an	
  element	
  when	
  mulJple	
  lines	
  
               required
             • Implemented	
  as	
  just	
  a	
  slightly	
  different	
  surface	
  parser	
  on	
  Scaml
        Jade	
  +	
  markdown	
  are	
  the	
  hotness!




      15        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Mustache


        no	
  logic	
  in	
  the	
  scripts	
  
        can	
  be	
  used	
  from	
  JavaScript	
  on	
  the	
  client	
  side	
  or	
  Scala	
  /	
  
         Scalate	
  on	
  the	
  server	
  side
        uses	
  {{foo}}	
  mustaches	
  for	
  values
        use	
  {{#foo}}	
  and	
  {{/foo}}	
  for	
  blocks/loops/condiJonals
        good	
  if	
  you	
  want	
  your	
  designer	
  to	
  own	
  the	
  templates
             • though	
  dynamically	
  typed




      16        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Scuery


        more	
  of	
  a	
  HTML/XHTML	
  transformaJon	
  engine	
  really
        uses	
  CSS3	
  parser	
  &	
  transformaJon	
  engine
        templates	
  are	
  regular	
  HTML	
  pages	
  (possibly	
  with	
  mock	
  data)	
  
         owned	
  by	
  your	
  designer
        use	
  the	
  transform	
  API	
  ( jQuery-­‐ish)	
  to	
  transform	
  the	
  HTML	
  to	
  
         inject/replace	
  with	
  dynamic	
  data




      17        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Tips	
  on	
  picking	
  a	
  template	
  language


        If	
  you	
  want	
  your	
  designers	
  to	
  own	
  your	
  templates
             • consider	
  mustache	
  or	
  scuery
        if	
  you	
  want	
  developers	
  to	
  hack	
  your	
  templates
             • want	
  to	
  generate	
  HTML/XML	
  really	
  DRY?	
  
                    – use	
  jade
             • otherwise	
  SSP




      18        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Scalate	
  Layouts


        TemplateEngine.layoutStrategy	
  defines	
  the	
  strategy
        default	
  implementaJon	
  uses	
  the	
  “layout”	
  a1ribute	
  to	
  define	
  
         the	
  template	
  used	
  for	
  laying	
  out	
  any	
  template
        to	
  change	
  the	
  layout	
  you	
  want	
  to	
  use...
             • -­‐	
  a1ributes(“layout”)	
  =	
  “/my/layouts/foo.jade”
        to	
  disable	
  layouts
             • -­‐	
  a1ributes(“layout”)	
  =	
  “”




      19        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Using	
  Scalate


        can	
  use	
  TemplateEngine	
  directly	
  if	
  doing	
  code	
  generaJon
        in	
  web	
  applicaJons	
  add	
  this	
  to	
  your	
  web.xml
         <filter>
           <filter-name>TemplateEngineFilter</filter-name>
           <filter-class>org.fusesource.scalate.servlet.TemplateEngineFilter</filter-class>
         </filter>
         <filter-mapping>
           <filter-name>TemplateEngineFilter</filter-name>
           <url-pattern>/*</url-pattern>
         </filter-mapping>




      20        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Framework	
  support


          bowler
          jersey
          lit
          playframework
          scalatra
          servlets
          sbt	
  /	
  lity
          spring	
  mvc
          unfiltered




      21        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
mod	
  your	
  TemplateEngine!


       package scalate

       import org.fusesource.scalate.TemplateEngine
       import java.io.File

       class Boot(engine: TemplateEngine) {

           def run: Unit = {
             // lets change the workingDirectory
             engine.workingDirectory = new File("myScalateWorkDir")
           }
       }




      22        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Precompile	
  your	
  templates

         <build>
         <plugins>
           <plugin>
             <groupId>org.fusesource.scalate</groupId>
             <artifactId>maven-scalate-plugin</artifactId>
             <version>1.5.0</version>
             <executions>
                <execution>
                  <goals>
                    <goal>precompile</goal>
                  </goals>
                </execution>
             </executions>
           </plugin>
         </plugins>
       </build>




      23        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
GeQng	
  Started


        install	
  Scalate
             • h1p://scalate.fusesource.org/download.html
             • add	
  SCALATE_HOME/bin	
  to	
  your	
  PATH
        scalate	
  create	
  jersey	
  mygroup	
  myarJfact
        cd	
  myarJfact
        mvn	
  je1y:run




      24        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Sta6c	
  site	
  genera6on


        maven	
  plugin	
  to	
  generate	
  a	
  complete	
  staJc	
  website	
  for	
  your	
  
         project	
  using	
  Scalate
        deploy	
  it	
  to	
  some	
  web	
  server	
  using	
  maven’s	
  wagon	
  
         transports
             • scp	
  /	
  webdav	
  etc
        allows	
  real	
  Jme	
  updates	
  of	
  templates	
  &	
  layouts	
  while	
  
         ediJng	
  docs
        your	
  own	
  personal	
  offline	
  wiki	
  using	
  git	
  for	
  source	
  control	
  &	
  
         versioning
             • use	
  a	
  text	
  editor	
  to	
  edit,	
  erm,	
  text	
  files!	
  :)




      25        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Demo	
  6me!

                                                                                      Demo	
  templates	
  &	
  web	
  app	
  here:
                         hhps://github.com/scalate/scalate/tree/master/samples/scalate-­‐example




      26        Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011
Any	
  Ques6ons?



                                                                               h1p://scalate.fusesource.org/




                                                                                                twiher:	
  @jstrachan
                                                                                               hhp://fusesource.com
       27       Copyright	
  ©	
  2010	
  Progress	
  So3ware	
  Corpora6on	
  and/or	
  its	
  subsidiaries	
  or	
  affiliates.	
  All	
  rights	
  reserved.	
     A	
  Progress	
  So3ware	
  Company

Thursday, June 16, 2011

Contenu connexe

Tendances

Fusesource camel-persistence-part1-webinar-charles-moulliard
Fusesource camel-persistence-part1-webinar-charles-moulliardFusesource camel-persistence-part1-webinar-charles-moulliard
Fusesource camel-persistence-part1-webinar-charles-moulliardCharles Moulliard
 
GIDS 2012: Java Message Service 2.0
GIDS 2012: Java Message Service 2.0GIDS 2012: Java Message Service 2.0
GIDS 2012: Java Message Service 2.0Arun Gupta
 
Java EE 6 and GlassFish v3: Paving the path for future
Java EE 6 and GlassFish v3: Paving the path for futureJava EE 6 and GlassFish v3: Paving the path for future
Java EE 6 and GlassFish v3: Paving the path for futureArun Gupta
 
TDC 2011: The Java EE 7 Platform: Developing for the Cloud
TDC 2011: The Java EE 7 Platform: Developing for the CloudTDC 2011: The Java EE 7 Platform: Developing for the Cloud
TDC 2011: The Java EE 7 Platform: Developing for the CloudArun Gupta
 
GlassFish REST Administration Backend
GlassFish REST Administration BackendGlassFish REST Administration Backend
GlassFish REST Administration BackendArun Gupta
 
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...Arun Gupta
 
OSGi & Java EE in GlassFish @ Silicon Valley Code Camp 2010
OSGi & Java EE in GlassFish @ Silicon Valley Code Camp 2010OSGi & Java EE in GlassFish @ Silicon Valley Code Camp 2010
OSGi & Java EE in GlassFish @ Silicon Valley Code Camp 2010Arun Gupta
 
Running your Java EE 6 applications in the Cloud @ Silicon Valley Code Camp 2010
Running your Java EE 6 applications in the Cloud @ Silicon Valley Code Camp 2010Running your Java EE 6 applications in the Cloud @ Silicon Valley Code Camp 2010
Running your Java EE 6 applications in the Cloud @ Silicon Valley Code Camp 2010Arun Gupta
 
GlassFish 3.1 at JCertif 2011
GlassFish 3.1 at JCertif 2011GlassFish 3.1 at JCertif 2011
GlassFish 3.1 at JCertif 2011Arun Gupta
 
(Oleg zhurakousky)spring integration-scala-intro
(Oleg zhurakousky)spring integration-scala-intro(Oleg zhurakousky)spring integration-scala-intro
(Oleg zhurakousky)spring integration-scala-introSkills Matter Talks
 
Groovy Power Features
Groovy Power FeaturesGroovy Power Features
Groovy Power FeaturesPaul King
 
OSGi Best Practices - Tim Ward
OSGi Best Practices - Tim WardOSGi Best Practices - Tim Ward
OSGi Best Practices - Tim Wardmfrancis
 
Whats Cool in Java E 6
Whats Cool in Java E 6Whats Cool in Java E 6
Whats Cool in Java E 6Arun Gupta
 
Java EE7 Demystified
Java EE7 DemystifiedJava EE7 Demystified
Java EE7 DemystifiedAnkara JUG
 
Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010
Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010
Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010Arun Gupta
 
Java EE7 in action
Java EE7 in actionJava EE7 in action
Java EE7 in actionAnkara JUG
 
Ankara JUG Ağustos 2013 - Oracle ADF
Ankara JUG Ağustos 2013 - Oracle ADFAnkara JUG Ağustos 2013 - Oracle ADF
Ankara JUG Ağustos 2013 - Oracle ADFAnkara JUG
 
Java EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 India
Java EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 IndiaJava EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 India
Java EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 IndiaArun Gupta
 
Pointwest. Agility Defined.
Pointwest. Agility Defined.Pointwest. Agility Defined.
Pointwest. Agility Defined.Pointwest
 

Tendances (20)

Fusesource camel-persistence-part1-webinar-charles-moulliard
Fusesource camel-persistence-part1-webinar-charles-moulliardFusesource camel-persistence-part1-webinar-charles-moulliard
Fusesource camel-persistence-part1-webinar-charles-moulliard
 
GIDS 2012: Java Message Service 2.0
GIDS 2012: Java Message Service 2.0GIDS 2012: Java Message Service 2.0
GIDS 2012: Java Message Service 2.0
 
Java EE 6 and GlassFish v3: Paving the path for future
Java EE 6 and GlassFish v3: Paving the path for futureJava EE 6 and GlassFish v3: Paving the path for future
Java EE 6 and GlassFish v3: Paving the path for future
 
TDC 2011: The Java EE 7 Platform: Developing for the Cloud
TDC 2011: The Java EE 7 Platform: Developing for the CloudTDC 2011: The Java EE 7 Platform: Developing for the Cloud
TDC 2011: The Java EE 7 Platform: Developing for the Cloud
 
GlassFish REST Administration Backend
GlassFish REST Administration BackendGlassFish REST Administration Backend
GlassFish REST Administration Backend
 
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...
Java EE 6 & GlassFish 3: Light-weight, Extensible, and Powerful @ Silicon Val...
 
OSGi & Java EE in GlassFish @ Silicon Valley Code Camp 2010
OSGi & Java EE in GlassFish @ Silicon Valley Code Camp 2010OSGi & Java EE in GlassFish @ Silicon Valley Code Camp 2010
OSGi & Java EE in GlassFish @ Silicon Valley Code Camp 2010
 
Running your Java EE 6 applications in the Cloud @ Silicon Valley Code Camp 2010
Running your Java EE 6 applications in the Cloud @ Silicon Valley Code Camp 2010Running your Java EE 6 applications in the Cloud @ Silicon Valley Code Camp 2010
Running your Java EE 6 applications in the Cloud @ Silicon Valley Code Camp 2010
 
GlassFish 3.1 at JCertif 2011
GlassFish 3.1 at JCertif 2011GlassFish 3.1 at JCertif 2011
GlassFish 3.1 at JCertif 2011
 
(Oleg zhurakousky)spring integration-scala-intro
(Oleg zhurakousky)spring integration-scala-intro(Oleg zhurakousky)spring integration-scala-intro
(Oleg zhurakousky)spring integration-scala-intro
 
Groovy Power Features
Groovy Power FeaturesGroovy Power Features
Groovy Power Features
 
Java EE 6 and GlassFish portfolio
Java EE 6 and GlassFish portfolioJava EE 6 and GlassFish portfolio
Java EE 6 and GlassFish portfolio
 
OSGi Best Practices - Tim Ward
OSGi Best Practices - Tim WardOSGi Best Practices - Tim Ward
OSGi Best Practices - Tim Ward
 
Whats Cool in Java E 6
Whats Cool in Java E 6Whats Cool in Java E 6
Whats Cool in Java E 6
 
Java EE7 Demystified
Java EE7 DemystifiedJava EE7 Demystified
Java EE7 Demystified
 
Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010
Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010
Java EE 6 & GlassFish v3: Paving the path for the future - Spark IT 2010
 
Java EE7 in action
Java EE7 in actionJava EE7 in action
Java EE7 in action
 
Ankara JUG Ağustos 2013 - Oracle ADF
Ankara JUG Ağustos 2013 - Oracle ADFAnkara JUG Ağustos 2013 - Oracle ADF
Ankara JUG Ağustos 2013 - Oracle ADF
 
Java EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 India
Java EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 IndiaJava EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 India
Java EE 6 & GlassFish v3: Paving the path for the future - Tech Days 2010 India
 
Pointwest. Agility Defined.
Pointwest. Agility Defined.Pointwest. Agility Defined.
Pointwest. Agility Defined.
 

Similaire à Scalate Template Engine Overview

Be jug 090611_apacheservicemix
Be jug 090611_apacheservicemixBe jug 090611_apacheservicemix
Be jug 090611_apacheservicemixCharles Moulliard
 
Apache camel overview dec 2011
Apache camel overview dec 2011Apache camel overview dec 2011
Apache camel overview dec 2011Marcelo Jabali
 
RESTful Services and Distributed OSGi - 04/2009
RESTful Services and Distributed OSGi - 04/2009RESTful Services and Distributed OSGi - 04/2009
RESTful Services and Distributed OSGi - 04/2009Roland Tritsch
 
Shake Hooves With BeEF - OWASP AppSec APAC 2012
Shake Hooves With BeEF - OWASP AppSec APAC 2012Shake Hooves With BeEF - OWASP AppSec APAC 2012
Shake Hooves With BeEF - OWASP AppSec APAC 2012Christian Frichot
 
Introduction to ActiveMQ Apollo
Introduction to ActiveMQ ApolloIntroduction to ActiveMQ Apollo
Introduction to ActiveMQ Apollodejanb
 
Survey of restful web services frameworks
Survey of restful web services frameworksSurvey of restful web services frameworks
Survey of restful web services frameworksVijay Prasad Gupta
 
Make easier Integration of your services with Fuse Solutions - RedHat 2013
Make easier Integration of your services with Fuse Solutions - RedHat 2013Make easier Integration of your services with Fuse Solutions - RedHat 2013
Make easier Integration of your services with Fuse Solutions - RedHat 2013Charles Moulliard
 
20100907 fuse-community-evening-adrian-trenaman-no-logo
20100907 fuse-community-evening-adrian-trenaman-no-logo20100907 fuse-community-evening-adrian-trenaman-no-logo
20100907 fuse-community-evening-adrian-trenaman-no-logoAdrian Trenaman
 
Project Avatar (Lyon JUG & Alpes JUG - March 2014)
Project Avatar (Lyon JUG & Alpes JUG  - March 2014)Project Avatar (Lyon JUG & Alpes JUG  - March 2014)
Project Avatar (Lyon JUG & Alpes JUG - March 2014)David Delabassee
 
Java EE 7 et ensuite pourquoi pas JavaScript sur le serveur!
Java EE 7 et ensuite pourquoi pas JavaScript sur le serveur! Java EE 7 et ensuite pourquoi pas JavaScript sur le serveur!
Java EE 7 et ensuite pourquoi pas JavaScript sur le serveur! David Delabassee
 
Succeding with the Apache SOA stack
Succeding with the Apache SOA stackSucceding with the Apache SOA stack
Succeding with the Apache SOA stackJohan Edstrom
 
OSGi for real in the enterprise: Apache Karaf - NLJUG J-FALL 2010
OSGi for real in the enterprise: Apache Karaf - NLJUG J-FALL 2010OSGi for real in the enterprise: Apache Karaf - NLJUG J-FALL 2010
OSGi for real in the enterprise: Apache Karaf - NLJUG J-FALL 2010Adrian Trenaman
 
Jason Hunter Slides from NoSQL Oakland meetup
Jason Hunter Slides from NoSQL Oakland meetupJason Hunter Slides from NoSQL Oakland meetup
Jason Hunter Slides from NoSQL Oakland meetupDave Kellogg
 
Andre Tost Service Models Java
Andre  Tost    Service Models JavaAndre  Tost    Service Models Java
Andre Tost Service Models JavaSOA Symposium
 
JavaOne 2011 - Going Mobile With Java Based Technologies Today
JavaOne 2011 - Going Mobile With Java Based Technologies TodayJavaOne 2011 - Going Mobile With Java Based Technologies Today
JavaOne 2011 - Going Mobile With Java Based Technologies TodayWesley Hales
 
Updated resume
Updated resumeUpdated resume
Updated resumepavani p
 
RMOUG MySQL 5.7 New Features
RMOUG MySQL 5.7 New FeaturesRMOUG MySQL 5.7 New Features
RMOUG MySQL 5.7 New FeaturesDave Stokes
 
groovy and concurrency
groovy and concurrencygroovy and concurrency
groovy and concurrencyPaul King
 
Java EE 7: Developing for the Cloud at Java Day, Istanbul, May 2012
Java EE 7: Developing for the Cloud at Java Day, Istanbul, May 2012Java EE 7: Developing for the Cloud at Java Day, Istanbul, May 2012
Java EE 7: Developing for the Cloud at Java Day, Istanbul, May 2012Arun Gupta
 

Similaire à Scalate Template Engine Overview (20)

Be jug 090611_apacheservicemix
Be jug 090611_apacheservicemixBe jug 090611_apacheservicemix
Be jug 090611_apacheservicemix
 
Apache camel overview dec 2011
Apache camel overview dec 2011Apache camel overview dec 2011
Apache camel overview dec 2011
 
RESTful Services and Distributed OSGi - 04/2009
RESTful Services and Distributed OSGi - 04/2009RESTful Services and Distributed OSGi - 04/2009
RESTful Services and Distributed OSGi - 04/2009
 
Shake Hooves With BeEF - OWASP AppSec APAC 2012
Shake Hooves With BeEF - OWASP AppSec APAC 2012Shake Hooves With BeEF - OWASP AppSec APAC 2012
Shake Hooves With BeEF - OWASP AppSec APAC 2012
 
Introduction to ActiveMQ Apollo
Introduction to ActiveMQ ApolloIntroduction to ActiveMQ Apollo
Introduction to ActiveMQ Apollo
 
FraSCAti with OSGi
FraSCAti with OSGiFraSCAti with OSGi
FraSCAti with OSGi
 
Survey of restful web services frameworks
Survey of restful web services frameworksSurvey of restful web services frameworks
Survey of restful web services frameworks
 
Make easier Integration of your services with Fuse Solutions - RedHat 2013
Make easier Integration of your services with Fuse Solutions - RedHat 2013Make easier Integration of your services with Fuse Solutions - RedHat 2013
Make easier Integration of your services with Fuse Solutions - RedHat 2013
 
20100907 fuse-community-evening-adrian-trenaman-no-logo
20100907 fuse-community-evening-adrian-trenaman-no-logo20100907 fuse-community-evening-adrian-trenaman-no-logo
20100907 fuse-community-evening-adrian-trenaman-no-logo
 
Project Avatar (Lyon JUG & Alpes JUG - March 2014)
Project Avatar (Lyon JUG & Alpes JUG  - March 2014)Project Avatar (Lyon JUG & Alpes JUG  - March 2014)
Project Avatar (Lyon JUG & Alpes JUG - March 2014)
 
Java EE 7 et ensuite pourquoi pas JavaScript sur le serveur!
Java EE 7 et ensuite pourquoi pas JavaScript sur le serveur! Java EE 7 et ensuite pourquoi pas JavaScript sur le serveur!
Java EE 7 et ensuite pourquoi pas JavaScript sur le serveur!
 
Succeding with the Apache SOA stack
Succeding with the Apache SOA stackSucceding with the Apache SOA stack
Succeding with the Apache SOA stack
 
OSGi for real in the enterprise: Apache Karaf - NLJUG J-FALL 2010
OSGi for real in the enterprise: Apache Karaf - NLJUG J-FALL 2010OSGi for real in the enterprise: Apache Karaf - NLJUG J-FALL 2010
OSGi for real in the enterprise: Apache Karaf - NLJUG J-FALL 2010
 
Jason Hunter Slides from NoSQL Oakland meetup
Jason Hunter Slides from NoSQL Oakland meetupJason Hunter Slides from NoSQL Oakland meetup
Jason Hunter Slides from NoSQL Oakland meetup
 
Andre Tost Service Models Java
Andre  Tost    Service Models JavaAndre  Tost    Service Models Java
Andre Tost Service Models Java
 
JavaOne 2011 - Going Mobile With Java Based Technologies Today
JavaOne 2011 - Going Mobile With Java Based Technologies TodayJavaOne 2011 - Going Mobile With Java Based Technologies Today
JavaOne 2011 - Going Mobile With Java Based Technologies Today
 
Updated resume
Updated resumeUpdated resume
Updated resume
 
RMOUG MySQL 5.7 New Features
RMOUG MySQL 5.7 New FeaturesRMOUG MySQL 5.7 New Features
RMOUG MySQL 5.7 New Features
 
groovy and concurrency
groovy and concurrencygroovy and concurrency
groovy and concurrency
 
Java EE 7: Developing for the Cloud at Java Day, Istanbul, May 2012
Java EE 7: Developing for the Cloud at Java Day, Istanbul, May 2012Java EE 7: Developing for the Cloud at Java Day, Istanbul, May 2012
Java EE 7: Developing for the Cloud at Java Day, Istanbul, May 2012
 

Dernier

#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
 
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
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
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
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
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
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGSujit Pal
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Alan Dix
 
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
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxOnBoard
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Paola De la Torre
 
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
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Allon Mureinik
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonetsnaman860154
 
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
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘RTylerCroy
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking MenDelhi Call girls
 
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
 
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
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024BookNet Canada
 

Dernier (20)

#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
 
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...
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
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
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
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
 
Google AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAGGoogle AI Hackathon: LLM based Evaluator for RAG
Google AI Hackathon: LLM based Evaluator for RAG
 
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...Swan(sea) Song – personal research during my six years at Swansea ... and bey...
Swan(sea) Song – personal research during my six years at Swansea ... and bey...
 
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
 
Maximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptxMaximizing Board Effectiveness 2024 Webinar.pptx
Maximizing Board Effectiveness 2024 Webinar.pptx
 
Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101Salesforce Community Group Quito, Salesforce 101
Salesforce Community Group Quito, Salesforce 101
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)Injustice - Developers Among Us (SciFiDevCon 2024)
Injustice - Developers Among Us (SciFiDevCon 2024)
 
How to convert PDF to text with Nanonets
How to convert PDF to text with NanonetsHow to convert PDF to text with Nanonets
How to convert PDF to text with Nanonets
 
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
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
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
 
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
 
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
Transcript: #StandardsGoals for 2024: What’s new for BISAC - Tech Forum 2024
 

Scalate Template Engine Overview

  • 1. Scalate Introducing  the  Scala  Template  Engine James  Strachan,  FuseSource A  Progress  So3ware  Company 1 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 2. Your  presenter  is:  James  Strachan  James  Strachan • james@fusesource.com • twi1er:  @jstrachan • blog:  h1p://macstrac.blogspot.com/  So3ware  Fellow  at  FuseSource  long  term  Open  Source  contributor • created  Apache  Camel • created  the  Groovy  programming  language • co-­‐founder  of –Apache  Ac6veMQ,  Camel,  ServiceMix,  Fabric,  ... –Scalate 2 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 3. FuseSource  -­‐  experts  in  open  source  integra6on  and  messaging   FuseSource  sponsors  projects  at  the  Apache  So3ware  Founda6on CXF JAX-WS, WS-*, REST for Web and Restful Integration Enterprise Messaging, ActiveMQ multi platform and language support, JMS,STOMP,AMQP1.0, Highly available and fault tolerant Camel Enterprise Integration Patterns framework ServiceMix Enterprise Service Bus, distributed,clustered, OSGi, JBI Karaf OSGi based container, supporting multiple archive types, remote management, dynamic configuration, extensible shell 3 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 4. Some  recommended  books... Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 5. Agenda scala  and  me scalate  overview geQng  started Q  &  A 5 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 6. Scala  and  me 6 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 7. Scalate  Overview  its  a  Scala  based  Template  Engine • Scala    T  E  =>  scalate  h1p://scalate.fusesource.org/ 7 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 8. Design  Goals  make  an  awesome  template  engine   • framework  &  container  agnosJc  support  different  template  flavours  under  same  API • there  isn’t  really  a  one  size  fits  all  reuse  the  power  &  type  safety  of  Scala • catch  errors  in  templates  at  edit/build  Jme – templates  are  for  life,  not  just  for  Christmas! • IDE  friendly  for  smart  compleJon 8 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 9. Features  Templates  are  compiled  &  cached  as  fast  Scala  objects  Template  objects  are  staJcally  typed  to  catch  typos • apart  from  Mustache  Scalate  is  equivalent  to  the  combinaJon  of  JSP,  JSTL,  JSP  EL   &  SiteMesh/Tiles • Scala  replaces  JSP  EL  and  Scala  funcJons  replace  JSP  custom  tags • Scalate  template  languages  are  richer,  more  powerful  &  usually  more   DRY  than  JSP  +  JSTL • Scalate  has  in  built  layout  support  replacing  SiteMesh/Titles 9 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 10. How  Scalate  works  TemplateEngine  is  used  to  load  Templates • typically  templates  are  converted  into  scala  code  and  compiled  to   avoid  runJme  parsing • can  customize  various  things... – caching  &  reloading – how  URIs  are  resolved  (classpath,  file  system  etc) – interna6onalisa6on  RenderContext  is  used  to  render  a  template • has  a  Map[String,Any]  like  set  of  a1ributes  for  passing/sharing  state • loads  of  helper  methods  for  use  inside  the  template – localisa6on,  including  other  templates,  views,  layouts  etc  template  languages  implemented  using  Scala  parser   generators 10 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 11. Scalate  Template  Languages  SSP  Scaml  Jade  Mustache  Scuery 11 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 12. SSP  SSP  “Scala  Server  Pages”   • like  a  non-­‐sucky  JSP  :)  easiest  template  engine  to  start  with  if  folks  know • ASP,  JSP,  GSP,  Erb,  Velocity,  FreeMarker  style  templates  supports  JSP  /  Erb  style  syntax   • <%  statements  %> • <%=  expression  %> • ${expression}  examples: • Dear  ${people.map(_.name).mkString(“,  “)}  how  are  you? 12 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 13. SSP  also  supports  Velocity  style  tokens #if  (lineItems.find(_.price  >  10).isDefined)    <b>Welcome  big  spender!</b> #end 13 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 14. Scaml  Scaml  is  a  Scala  port  of  HAML • HAML  started  in  the  Rails  world  and  became  a  very  popular  alternaJve   to  Erb  templates • whitespace  sensiJve  (which  is  handy  for  markup,  avoids  badly  nested   markup) • uses  %foo  to  indicate  <foo>...</foo> • -­‐  for  statements • =  expressions 14 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 15. Jade  Jade  out  in  JavaScript  /  Rails  worlds  as  a  simpler  more  DRY   version  of  HAML  /  Scaml   • avoid  the  %  to  indicate  element  name – folks  tend  to  use  lots  of  elements;  few  are  mul6-­‐line  text  content • use  |  to  indicate  text  content  inside  an  element  when  mulJple  lines   required • Implemented  as  just  a  slightly  different  surface  parser  on  Scaml  Jade  +  markdown  are  the  hotness! 15 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 16. Mustache  no  logic  in  the  scripts    can  be  used  from  JavaScript  on  the  client  side  or  Scala  /   Scalate  on  the  server  side  uses  {{foo}}  mustaches  for  values  use  {{#foo}}  and  {{/foo}}  for  blocks/loops/condiJonals  good  if  you  want  your  designer  to  own  the  templates • though  dynamically  typed 16 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 17. Scuery  more  of  a  HTML/XHTML  transformaJon  engine  really  uses  CSS3  parser  &  transformaJon  engine  templates  are  regular  HTML  pages  (possibly  with  mock  data)   owned  by  your  designer  use  the  transform  API  ( jQuery-­‐ish)  to  transform  the  HTML  to   inject/replace  with  dynamic  data 17 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 18. Tips  on  picking  a  template  language  If  you  want  your  designers  to  own  your  templates • consider  mustache  or  scuery  if  you  want  developers  to  hack  your  templates • want  to  generate  HTML/XML  really  DRY?   – use  jade • otherwise  SSP 18 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 19. Scalate  Layouts  TemplateEngine.layoutStrategy  defines  the  strategy  default  implementaJon  uses  the  “layout”  a1ribute  to  define   the  template  used  for  laying  out  any  template  to  change  the  layout  you  want  to  use... • -­‐  a1ributes(“layout”)  =  “/my/layouts/foo.jade”  to  disable  layouts • -­‐  a1ributes(“layout”)  =  “” 19 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 20. Using  Scalate  can  use  TemplateEngine  directly  if  doing  code  generaJon  in  web  applicaJons  add  this  to  your  web.xml   <filter>     <filter-name>TemplateEngineFilter</filter-name>     <filter-class>org.fusesource.scalate.servlet.TemplateEngineFilter</filter-class>   </filter>   <filter-mapping>     <filter-name>TemplateEngineFilter</filter-name>     <url-pattern>/*</url-pattern>   </filter-mapping> 20 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 21. Framework  support  bowler  jersey  lit  playframework  scalatra  servlets  sbt  /  lity  spring  mvc  unfiltered 21 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 22. mod  your  TemplateEngine! package scalate import org.fusesource.scalate.TemplateEngine import java.io.File class Boot(engine: TemplateEngine) { def run: Unit = { // lets change the workingDirectory engine.workingDirectory = new File("myScalateWorkDir") } } 22 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 23. Precompile  your  templates <build> <plugins> <plugin> <groupId>org.fusesource.scalate</groupId> <artifactId>maven-scalate-plugin</artifactId> <version>1.5.0</version> <executions> <execution> <goals> <goal>precompile</goal> </goals> </execution> </executions> </plugin> </plugins> </build> 23 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 24. GeQng  Started  install  Scalate • h1p://scalate.fusesource.org/download.html • add  SCALATE_HOME/bin  to  your  PATH  scalate  create  jersey  mygroup  myarJfact  cd  myarJfact  mvn  je1y:run 24 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 25. Sta6c  site  genera6on  maven  plugin  to  generate  a  complete  staJc  website  for  your   project  using  Scalate  deploy  it  to  some  web  server  using  maven’s  wagon   transports • scp  /  webdav  etc  allows  real  Jme  updates  of  templates  &  layouts  while   ediJng  docs  your  own  personal  offline  wiki  using  git  for  source  control  &   versioning • use  a  text  editor  to  edit,  erm,  text  files!  :) 25 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 26. Demo  6me! Demo  templates  &  web  app  here: hhps://github.com/scalate/scalate/tree/master/samples/scalate-­‐example 26 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011
  • 27. Any  Ques6ons? h1p://scalate.fusesource.org/ twiher:  @jstrachan hhp://fusesource.com 27 Copyright  ©  2010  Progress  So3ware  Corpora6on  and/or  its  subsidiaries  or  affiliates.  All  rights  reserved.   A  Progress  So3ware  Company Thursday, June 16, 2011