SlideShare une entreprise Scribd logo
1  sur  32
Télécharger pour lire hors ligne
Dynamic Languages in
GlassFish v3 Prelude
GlassFish Webinar


Vivek Pandey
Developer, Glassfish Team
Sun Microsysems, Inc.

                            1
2
GlassFish v3 - A Dynamic AppServer
Productivity, performance

• GlassFish v3
   > Lightweight, Modular, Extensible, Embeddable
• Reasonable and efficient deployment choice
   > Native, WAR style, embedded GlassFish
• App Server feature for everyone
   >   Database connection pooling
   >   Native threading, non-blocking IO, ARP
   >   Management – Monitor, Deploy, Troubleshooting
   >   Access to enterprise stack
       – Metro, Jersey, JMS/MQ, Grizzly, JBI etc.      3
Overall Architecture




                       4
JRuby on Rails




                 5
Why Ruby on GlassFish?
• GlassFish v3 server is tested platform
  > Co-host Java and Rails
  > Known Deployment and Management
• “Green” alternative – One command, One instance,
  One process
• Multiple Requests by a Single Application
• Database Connection Pooling
• Not just Rails – Merb, Sinatra...

                                                     6
More benefits...
• No packaging, simple deployment
    > asadmin deploy depot/
• Deploy as WAR
    > warble #creates WAR file
    > asadmin deploy depot.war
• Tested JRuby runtime at Updatecenter
    > bin/updatetool
    > No more config needed
• Commercially supported by Sun
•   http://wiki.glassfish.java.net/Wiki.jsp?page=GettingStartedGuide

                                                                       7
GlassFish v3 Runtime


                  Grizzly Listener

                               .
         Rails      Web        .      XXX
        Adapter    Adapter           Adapter
                               .

                             Rails
                                     Runtime
                                        Pool
                             JRuby

                                               8
Runtime Pool Management
• Automatic JRuby runtime pool management

          Gem         Create
                       JRuby     Rails
         Startup      Runtime
                                 JRuby
                    Load Rails
                   Environment


                      Add to       Rails
                     Runtime
                       Pool       JRuby

                                            9
Configuring JRuby Runtime Pool
• On GlassFish v3 Prelude Server
  > System properties
     – -Djruby.runtime.min : Sets the fewest runtimes to have in the
       pool
     – -Djruby.runtime : Sets the initial number of runtimes to create
     – -Djruby.runtime.max : Sets the maximum number of runtimes to
       have active
  > Add these system properties as <jvm-options> elements
    inside domain.xml
  > Or, if using java CLI simply provide it using -D option
     – java -Djruby.home=... -Djruby.runtime.max=2 -jar
       modules/glassfish.jar


                                                                         10
Configuring JRuby Runtime Pool
• GlassFish gem
  > CLI options
     – -n, --runtimes
           –   Number of JRuby runtimes to crete initially
     – --runtimes-min
           –   Minimum JRuby runtimes to crete
     – --runtimes-max
           –   Maximum number of JRuby runtimes to crete
  > glassfish -n 2 –runtimes-min 1 –runtimes-max 6
     – Starts glassfish gem with 2 JRuby runtimes, the minimum pool
       size is 1 and maximum size it can grow up to is 6


                                                                      11
JRuby Bundle - Updatecenter
• glassfish-install/bin/updatetool




                                     12
NetBeans Tooling
• NetBeans support
  > Develop, deploy debug
  > Screencast
    – http://weblogs.java.net/blog/arungupta/archive/2008/11/screencast_26_d.html




                                                                                    13
GlassFish gem
•   Rails developer friendly
•   Based on GlassFish v3 nucleus
•   Distributed as ruby gem
•   Install
    > gem install glassfish
• Run
    > cd myAp
    > glassfish
• More info
    > http://glassfishgem.rubyforge.org/
                                           14
GlassFish Gem
• Latest 0.9.0 released
• Features
   > Rack based architecture
      – Pluggable ruby frameworks
   > Merb support
      – JRuby and Merb native extension issue
        $jruby -S gem install merb-core merb-more
        $merb-gen core hello
        $cd hello
        $glassfish
• Framework auto-detection
   > Need just one command 'glassfish'
• Details at: http://glassfishgems.rubyforge.org/   15
Demo – GlassFish Gem
• Demo screencast
  > http://mediacast.sun.com/users/vivek.pandey/media/gemdemo




                                                                16
Groovy on Grails




                   17
Groovy on Grails
• An MVC frameworks
• Based on Groovy, Spring, Hibernate, SiteMesh
  > But hides all the complexity
• Adopts Rails paradigms




                                                 18
Grails – Setup and Installation
• Install Grails IPS package using updatetool
  > Grails package is installed inside 'glassfish' directory
• Grails IPS package
  > Provides the following benefits over Grails distributions
    found elsewhere
     – grails shaed-war
          –   Lightweight, efficient application WAR
          –   Less prone to OOM due to lack of PermGen space on hot deployments
     – grails run-app
          –   Runs GlassFish v3 Prelude in embedded mode
          –   Develop and test your grails app on the same server you would deploy
              during production

• Set GRAILS_HOME environment variable
  > export GRAILS_HOME=glassfish-install/grails
                                                                                     19
Groovy on Grails - Updatecenter
• glassfish-install/bin/updatetool




                                     20
Groovy on Grails
• Development and production on the same server
  > Develop using GlassFish v3 embedded server
    – grails run-app




                                                  21
Groovy on Grails
• Development and production on the same server
  > Develop using GlassFish v3 embedded server
    – grails run-app
  > Production deployment
    – asadmin deploy grailsApp.war




                                                  22
Groovy on Grails
• Development and production on the same server
  > Develop using GlassFish v3 embedded server
     – grails run-app
  > Production deployment
     – asadmin deploy grailsApp.war

• Efficient WAR packaging
  > grails shared-war
     – Creates smaller WARs ~200KB vs 18MB
     – asadmin deploy –-libraries $GRAILS_HOME/lib/glassfish-
       grails.jar grailsApp.war




                                                                23
Groovy on Grails
• Development and production on the same server
  > Develop using GlassFish v3 embedded server
      – grails run-app
  > Production deployment
      – asadmin deploy grailsApp.war

• Efficient WAR packaging
  > grails shared-war
     – Creates smaller WARs ~200KB vs 18MB
      – asadmin deploy –-libraries $GRAILS_HOME/lib/glassfish-
        grails grailsApp.war

• For details
  > http://wiki.glassfish.java.net/Wiki.jsp?page=GrailsGettingStarted

                                                                        24
Groovy on Grails – Screencast
• From Zero to Grails in 5 minutes with GlassFish v3 Prelude
   > https://slx.sun.com/1179271912




                                                               25
Jython on Django
• Jython 2.5 nearing release
  > Jython 2.5 beta out
  > Being developed at
     – http://www.jython.org/Project/
• Currently WAR deployment approach
  > Using Django-Jython project
     – http://django-jython.googlecode.com/
• Native Django application deployment in works



                                                  26
PHP




      27
PHP
• Quercus (Caucho)
  > Open Source (GPL) PHP 5 implementation in Java
  > WAR packaging
  > WordPress, MediaWiki, phpBB, Joomla
• PHP/Java Bridge
  >   Open Source (LGPL)
  >   XML based network protocol for native PHP
  >   Faster, easier than JNI
  >   Java native threads used for concurrent requests
  >   PHP and JSP session sharing

                                                         28
Scala on Lift




                29
Scala on Lift
• Lifts apps packaged as WAR
  >   asadmin deploy liftApp.war

• For details on developing and deploying Lift
  applications see
  > http://wiki.glassfish.java.net/Wiki.jsp?page=GettingStartedWithLiftOnGlassFish




                                                                                     30
References
• GlassFish
   > https://glassfish.dev.java.net
• GlassFish Scripting Project
   > https://glassfish-scripting.dev.java.net
• Scripting Wiki
   > http://wiki.glassfish.java.net/Wiki.jsp?page=Scripting
• Mailing List
   > webtier@glassfish.dev.java.net
• IssueTracker
   > https://glassfish.dev.java.net/servlets/ProjectIssues
• TheAquarium
   > http://blogs.sun.com/theaquarium
                                                              31
Q&A




      32

Contenu connexe

Tendances

Puppet and Vagrant in development
Puppet and Vagrant in developmentPuppet and Vagrant in development
Puppet and Vagrant in developmentAdam Culp
 
Docker workshop
Docker workshopDocker workshop
Docker workshopEvans Ye
 
Dockerizing development workflow
Dockerizing development workflowDockerizing development workflow
Dockerizing development workflowOrest Ivasiv
 
Openstack Third-Party CI and the review of a few Openstack Infrastructure pro...
Openstack Third-Party CI and the review of a few Openstack Infrastructure pro...Openstack Third-Party CI and the review of a few Openstack Infrastructure pro...
Openstack Third-Party CI and the review of a few Openstack Infrastructure pro...Evgeny Antyshev
 
Iniciando com Docker
Iniciando com DockerIniciando com Docker
Iniciando com DockerEmmanuel Neri
 
Vagrant or docker for java dev environment
Vagrant or docker for java dev environmentVagrant or docker for java dev environment
Vagrant or docker for java dev environmentOrest Ivasiv
 
A Hitchhiker's Guide to Cloud Native Java EE
A Hitchhiker's Guide to Cloud Native Java EEA Hitchhiker's Guide to Cloud Native Java EE
A Hitchhiker's Guide to Cloud Native Java EEMario-Leander Reimer
 
From Ant to Maven to Gradle a tale of CI tools for JVM
From Ant to Maven to Gradle a tale of CI tools for JVMFrom Ant to Maven to Gradle a tale of CI tools for JVM
From Ant to Maven to Gradle a tale of CI tools for JVMBucharest Java User Group
 
Docker and Puppet — Puppet Camp L.A. — SCALE12X
Docker and Puppet — Puppet Camp L.A. — SCALE12XDocker and Puppet — Puppet Camp L.A. — SCALE12X
Docker and Puppet — Puppet Camp L.A. — SCALE12XJérôme Petazzoni
 
Why everyone is excited about Docker (and you should too...) - Carlo Bonamic...
Why everyone is excited about Docker (and you should too...) -  Carlo Bonamic...Why everyone is excited about Docker (and you should too...) -  Carlo Bonamic...
Why everyone is excited about Docker (and you should too...) - Carlo Bonamic...Codemotion
 
Vagrant + Docker provider [+Puppet]
Vagrant + Docker provider [+Puppet]Vagrant + Docker provider [+Puppet]
Vagrant + Docker provider [+Puppet]Nicolas Poggi
 
Real World Experience of Running Docker in Development and Production
Real World Experience of Running Docker in Development and ProductionReal World Experience of Running Docker in Development and Production
Real World Experience of Running Docker in Development and ProductionBen Hall
 
Continuous delivery with docker
Continuous delivery with dockerContinuous delivery with docker
Continuous delivery with dockerJohan Janssen
 
Python virtualenv & pip in 90 minutes
Python virtualenv & pip in 90 minutesPython virtualenv & pip in 90 minutes
Python virtualenv & pip in 90 minutesLarry Cai
 
Running Docker in Development & Production (DevSum 2015)
Running Docker in Development & Production (DevSum 2015)Running Docker in Development & Production (DevSum 2015)
Running Docker in Development & Production (DevSum 2015)Ben Hall
 
Learn docker in 90 minutes
Learn docker in 90 minutesLearn docker in 90 minutes
Learn docker in 90 minutesLarry Cai
 

Tendances (20)

Puppet and Vagrant in development
Puppet and Vagrant in developmentPuppet and Vagrant in development
Puppet and Vagrant in development
 
Docker workshop
Docker workshopDocker workshop
Docker workshop
 
A Hands-on Introduction to Docker
A Hands-on Introduction to DockerA Hands-on Introduction to Docker
A Hands-on Introduction to Docker
 
Dockerizing development workflow
Dockerizing development workflowDockerizing development workflow
Dockerizing development workflow
 
Docker by Example - Quiz
Docker by Example - QuizDocker by Example - Quiz
Docker by Example - Quiz
 
ABCs of docker
ABCs of dockerABCs of docker
ABCs of docker
 
Openstack Third-Party CI and the review of a few Openstack Infrastructure pro...
Openstack Third-Party CI and the review of a few Openstack Infrastructure pro...Openstack Third-Party CI and the review of a few Openstack Infrastructure pro...
Openstack Third-Party CI and the review of a few Openstack Infrastructure pro...
 
Iniciando com Docker
Iniciando com DockerIniciando com Docker
Iniciando com Docker
 
Vagrant or docker for java dev environment
Vagrant or docker for java dev environmentVagrant or docker for java dev environment
Vagrant or docker for java dev environment
 
A Hitchhiker's Guide to Cloud Native Java EE
A Hitchhiker's Guide to Cloud Native Java EEA Hitchhiker's Guide to Cloud Native Java EE
A Hitchhiker's Guide to Cloud Native Java EE
 
From Ant to Maven to Gradle a tale of CI tools for JVM
From Ant to Maven to Gradle a tale of CI tools for JVMFrom Ant to Maven to Gradle a tale of CI tools for JVM
From Ant to Maven to Gradle a tale of CI tools for JVM
 
Docker and Puppet — Puppet Camp L.A. — SCALE12X
Docker and Puppet — Puppet Camp L.A. — SCALE12XDocker and Puppet — Puppet Camp L.A. — SCALE12X
Docker and Puppet — Puppet Camp L.A. — SCALE12X
 
Docker by Example - Basics
Docker by Example - Basics Docker by Example - Basics
Docker by Example - Basics
 
Why everyone is excited about Docker (and you should too...) - Carlo Bonamic...
Why everyone is excited about Docker (and you should too...) -  Carlo Bonamic...Why everyone is excited about Docker (and you should too...) -  Carlo Bonamic...
Why everyone is excited about Docker (and you should too...) - Carlo Bonamic...
 
Vagrant + Docker provider [+Puppet]
Vagrant + Docker provider [+Puppet]Vagrant + Docker provider [+Puppet]
Vagrant + Docker provider [+Puppet]
 
Real World Experience of Running Docker in Development and Production
Real World Experience of Running Docker in Development and ProductionReal World Experience of Running Docker in Development and Production
Real World Experience of Running Docker in Development and Production
 
Continuous delivery with docker
Continuous delivery with dockerContinuous delivery with docker
Continuous delivery with docker
 
Python virtualenv & pip in 90 minutes
Python virtualenv & pip in 90 minutesPython virtualenv & pip in 90 minutes
Python virtualenv & pip in 90 minutes
 
Running Docker in Development & Production (DevSum 2015)
Running Docker in Development & Production (DevSum 2015)Running Docker in Development & Production (DevSum 2015)
Running Docker in Development & Production (DevSum 2015)
 
Learn docker in 90 minutes
Learn docker in 90 minutesLearn docker in 90 minutes
Learn docker in 90 minutes
 

Similaire à Scripting Support in GFv3 Prelude - Full Version

Scripting Support in GlassFish v3 Prelude
Scripting Support in GlassFish v3 PreludeScripting Support in GlassFish v3 Prelude
Scripting Support in GlassFish v3 PreludeEduardo Pelegri-Llopart
 
Dynamic Languages & Web Frameworks in GlassFish
Dynamic Languages & Web Frameworks in GlassFishDynamic Languages & Web Frameworks in GlassFish
Dynamic Languages & Web Frameworks in GlassFishIndicThreads
 
Dynamic Languages Web Frameworks Indicthreads 2009
Dynamic Languages Web Frameworks Indicthreads 2009Dynamic Languages Web Frameworks Indicthreads 2009
Dynamic Languages Web Frameworks Indicthreads 2009Arun Gupta
 
GlassFish can support multiple Ruby frameworks ... really ?
GlassFish can support multiple Ruby frameworks ... really ?GlassFish can support multiple Ruby frameworks ... really ?
GlassFish can support multiple Ruby frameworks ... really ?Arun Gupta
 
Glass fish rubyconf-india-2010-Arun gupta
Glass fish rubyconf-india-2010-Arun gupta Glass fish rubyconf-india-2010-Arun gupta
Glass fish rubyconf-india-2010-Arun gupta ThoughtWorks
 
Develop With Pleasure Deploy With Fun Glass Fish And Net Beans For A Better...
Develop With Pleasure  Deploy With Fun  Glass Fish And Net Beans For A Better...Develop With Pleasure  Deploy With Fun  Glass Fish And Net Beans For A Better...
Develop With Pleasure Deploy With Fun Glass Fish And Net Beans For A Better...railsconf
 
JRuby on Rails Deployment: What They Didn't Tell You
JRuby on Rails Deployment: What They Didn't Tell YouJRuby on Rails Deployment: What They Didn't Tell You
JRuby on Rails Deployment: What They Didn't Tell Youelliando dias
 
Deploying And Monitoring Rails
Deploying And Monitoring RailsDeploying And Monitoring Rails
Deploying And Monitoring RailsJonathan Weiss
 
Jaoo Michael Neale 09
Jaoo Michael Neale 09Jaoo Michael Neale 09
Jaoo Michael Neale 09Michael Neale
 
GraalVM - OpenSlava 2019-10-18
GraalVM - OpenSlava 2019-10-18GraalVM - OpenSlava 2019-10-18
GraalVM - OpenSlava 2019-10-18Jorge Hidalgo
 
Master your java_applications_in_kubernetes
Master your java_applications_in_kubernetesMaster your java_applications_in_kubernetes
Master your java_applications_in_kubernetesAndy Moncsek
 
GraalVM - MadridJUG 2019-10-22
GraalVM - MadridJUG 2019-10-22GraalVM - MadridJUG 2019-10-22
GraalVM - MadridJUG 2019-10-22Jorge Hidalgo
 
GraalVM - JBCNConf 2019-05-28
GraalVM - JBCNConf 2019-05-28GraalVM - JBCNConf 2019-05-28
GraalVM - JBCNConf 2019-05-28Jorge Hidalgo
 
Running your Java EE 6 applications in the Cloud (FISL 12)
Running your Java EE 6 applications in the Cloud (FISL 12)Running your Java EE 6 applications in the Cloud (FISL 12)
Running your Java EE 6 applications in the Cloud (FISL 12)Arun Gupta
 
Grails 101
Grails 101Grails 101
Grails 101Lim Kin
 

Similaire à Scripting Support in GFv3 Prelude - Full Version (20)

Scripting Support in GlassFish v3 Prelude
Scripting Support in GlassFish v3 PreludeScripting Support in GlassFish v3 Prelude
Scripting Support in GlassFish v3 Prelude
 
Dynamic Languages & Web Frameworks in GlassFish
Dynamic Languages & Web Frameworks in GlassFishDynamic Languages & Web Frameworks in GlassFish
Dynamic Languages & Web Frameworks in GlassFish
 
GlassFish v3 Prelude Aquarium Paris
GlassFish v3 Prelude Aquarium ParisGlassFish v3 Prelude Aquarium Paris
GlassFish v3 Prelude Aquarium Paris
 
Dynamic Languages Web Frameworks Indicthreads 2009
Dynamic Languages Web Frameworks Indicthreads 2009Dynamic Languages Web Frameworks Indicthreads 2009
Dynamic Languages Web Frameworks Indicthreads 2009
 
GlassFish v3 : En Route Java EE 6
GlassFish v3 : En Route Java EE 6GlassFish v3 : En Route Java EE 6
GlassFish v3 : En Route Java EE 6
 
GlassFish can support multiple Ruby frameworks ... really ?
GlassFish can support multiple Ruby frameworks ... really ?GlassFish can support multiple Ruby frameworks ... really ?
GlassFish can support multiple Ruby frameworks ... really ?
 
Glass fish rubyconf-india-2010-Arun gupta
Glass fish rubyconf-india-2010-Arun gupta Glass fish rubyconf-india-2010-Arun gupta
Glass fish rubyconf-india-2010-Arun gupta
 
Develop With Pleasure Deploy With Fun Glass Fish And Net Beans For A Better...
Develop With Pleasure  Deploy With Fun  Glass Fish And Net Beans For A Better...Develop With Pleasure  Deploy With Fun  Glass Fish And Net Beans For A Better...
Develop With Pleasure Deploy With Fun Glass Fish And Net Beans For A Better...
 
JRuby on Rails Deployment: What They Didn't Tell You
JRuby on Rails Deployment: What They Didn't Tell YouJRuby on Rails Deployment: What They Didn't Tell You
JRuby on Rails Deployment: What They Didn't Tell You
 
Deploying And Monitoring Rails
Deploying And Monitoring RailsDeploying And Monitoring Rails
Deploying And Monitoring Rails
 
Jaoo Michael Neale 09
Jaoo Michael Neale 09Jaoo Michael Neale 09
Jaoo Michael Neale 09
 
GlassFish Embedded API
GlassFish Embedded APIGlassFish Embedded API
GlassFish Embedded API
 
GraalVM - OpenSlava 2019-10-18
GraalVM - OpenSlava 2019-10-18GraalVM - OpenSlava 2019-10-18
GraalVM - OpenSlava 2019-10-18
 
Whats New In Groovy 1.6?
Whats New In Groovy 1.6?Whats New In Groovy 1.6?
Whats New In Groovy 1.6?
 
Master your java_applications_in_kubernetes
Master your java_applications_in_kubernetesMaster your java_applications_in_kubernetes
Master your java_applications_in_kubernetes
 
GlassFish v2 Clustering
GlassFish v2 ClusteringGlassFish v2 Clustering
GlassFish v2 Clustering
 
GraalVM - MadridJUG 2019-10-22
GraalVM - MadridJUG 2019-10-22GraalVM - MadridJUG 2019-10-22
GraalVM - MadridJUG 2019-10-22
 
GraalVM - JBCNConf 2019-05-28
GraalVM - JBCNConf 2019-05-28GraalVM - JBCNConf 2019-05-28
GraalVM - JBCNConf 2019-05-28
 
Running your Java EE 6 applications in the Cloud (FISL 12)
Running your Java EE 6 applications in the Cloud (FISL 12)Running your Java EE 6 applications in the Cloud (FISL 12)
Running your Java EE 6 applications in the Cloud (FISL 12)
 
Grails 101
Grails 101Grails 101
Grails 101
 

Plus de Eduardo Pelegri-Llopart

Pelegri Desarrollando en una nueva era de software
Pelegri   Desarrollando en una nueva era de software Pelegri   Desarrollando en una nueva era de software
Pelegri Desarrollando en una nueva era de software Eduardo Pelegri-Llopart
 
Market trends in IT - exchange cala - October 2015
Market trends in IT - exchange cala - October 2015Market trends in IT - exchange cala - October 2015
Market trends in IT - exchange cala - October 2015Eduardo Pelegri-Llopart
 
The impact of IOT - exchange cala - 2015
The impact of IOT - exchange cala - 2015The impact of IOT - exchange cala - 2015
The impact of IOT - exchange cala - 2015Eduardo Pelegri-Llopart
 
What is IoT and how Modulus and Pacific can Help - Featuring Node.js and Roll...
What is IoT and how Modulus and Pacific can Help - Featuring Node.js and Roll...What is IoT and how Modulus and Pacific can Help - Featuring Node.js and Roll...
What is IoT and how Modulus and Pacific can Help - Featuring Node.js and Roll...Eduardo Pelegri-Llopart
 
What is the Internet of Things and How it Impacts You
What is the Internet of Things and How it Impacts YouWhat is the Internet of Things and How it Impacts You
What is the Internet of Things and How it Impacts YouEduardo Pelegri-Llopart
 
Ehcache Architecture, Features And Usage Patterns
Ehcache Architecture, Features And Usage PatternsEhcache Architecture, Features And Usage Patterns
Ehcache Architecture, Features And Usage PatternsEduardo Pelegri-Llopart
 

Plus de Eduardo Pelegri-Llopart (20)

Juggling at freenome
Juggling   at freenomeJuggling   at freenome
Juggling at freenome
 
Csumb capstone-fall2016
Csumb capstone-fall2016Csumb capstone-fall2016
Csumb capstone-fall2016
 
Digital activitymanagement
Digital activitymanagementDigital activitymanagement
Digital activitymanagement
 
Progress next iot_pelegri
Progress next iot_pelegriProgress next iot_pelegri
Progress next iot_pelegri
 
Pelegri Desarrollando en una nueva era de software
Pelegri   Desarrollando en una nueva era de software Pelegri   Desarrollando en una nueva era de software
Pelegri Desarrollando en una nueva era de software
 
Market trends in IT - exchange cala - October 2015
Market trends in IT - exchange cala - October 2015Market trends in IT - exchange cala - October 2015
Market trends in IT - exchange cala - October 2015
 
The impact of IOT - exchange cala - 2015
The impact of IOT - exchange cala - 2015The impact of IOT - exchange cala - 2015
The impact of IOT - exchange cala - 2015
 
IOT - Presentation to PEP @ Progress
IOT - Presentation to PEP @ ProgressIOT - Presentation to PEP @ Progress
IOT - Presentation to PEP @ Progress
 
Node.js as an IOT Bridge
Node.js as an IOT BridgeNode.js as an IOT Bridge
Node.js as an IOT Bridge
 
What is IoT and how Modulus and Pacific can Help - Featuring Node.js and Roll...
What is IoT and how Modulus and Pacific can Help - Featuring Node.js and Roll...What is IoT and how Modulus and Pacific can Help - Featuring Node.js and Roll...
What is IoT and how Modulus and Pacific can Help - Featuring Node.js and Roll...
 
What is the Internet of Things and How it Impacts You
What is the Internet of Things and How it Impacts YouWhat is the Internet of Things and How it Impacts You
What is the Internet of Things and How it Impacts You
 
Community Update 25 Mar2010 - English
Community Update 25 Mar2010 - EnglishCommunity Update 25 Mar2010 - English
Community Update 25 Mar2010 - English
 
GlassFish Community Update 25 Mar2010
GlassFish Community Update 25 Mar2010GlassFish Community Update 25 Mar2010
GlassFish Community Update 25 Mar2010
 
Glass Fish Portfolio C1 West V3.Mini
Glass Fish Portfolio C1 West V3.MiniGlass Fish Portfolio C1 West V3.Mini
Glass Fish Portfolio C1 West V3.Mini
 
Virtual Box Aquarium May09
Virtual Box Aquarium May09Virtual Box Aquarium May09
Virtual Box Aquarium May09
 
Introduction To Web Beans
Introduction To Web BeansIntroduction To Web Beans
Introduction To Web Beans
 
Ehcache Architecture, Features And Usage Patterns
Ehcache Architecture, Features And Usage PatternsEhcache Architecture, Features And Usage Patterns
Ehcache Architecture, Features And Usage Patterns
 
OpenDS Primer Aquarium
OpenDS Primer AquariumOpenDS Primer Aquarium
OpenDS Primer Aquarium
 
Fuji Overview
Fuji OverviewFuji Overview
Fuji Overview
 
Nuxeo 5.2 Glassfish
Nuxeo 5.2 GlassfishNuxeo 5.2 Glassfish
Nuxeo 5.2 Glassfish
 

Dernier

Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Mark Goldstein
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security ObservabilityGlenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security Observabilityitnewsafrica
 
Connecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfConnecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfNeo4j
 
Testing tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examplesTesting tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examplesKari Kakkonen
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersNicole Novielli
 
Generative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptxGenerative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptxfnnc6jmgwh
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
Emixa Mendix Meetup 11 April 2024 about Mendix Native development
Emixa Mendix Meetup 11 April 2024 about Mendix Native developmentEmixa Mendix Meetup 11 April 2024 about Mendix Native development
Emixa Mendix Meetup 11 April 2024 about Mendix Native developmentPim van der Noll
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityIES VE
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Hiroshi SHIBATA
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxLoriGlavin3
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Kaya Weers
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch TuesdayIvanti
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfIngrid Airi González
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsNathaniel Shimoni
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsRavi Sanghani
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Alkin Tezuysal
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI AgeCprime
 

Dernier (20)

Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security ObservabilityGlenn Lazarus- Why Your Observability Strategy Needs Security Observability
Glenn Lazarus- Why Your Observability Strategy Needs Security Observability
 
Connecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdfConnecting the Dots for Information Discovery.pdf
Connecting the Dots for Information Discovery.pdf
 
Testing tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examplesTesting tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examples
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software Developers
 
Generative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptxGenerative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptx
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
Emixa Mendix Meetup 11 April 2024 about Mendix Native development
Emixa Mendix Meetup 11 April 2024 about Mendix Native developmentEmixa Mendix Meetup 11 April 2024 about Mendix Native development
Emixa Mendix Meetup 11 April 2024 about Mendix Native development
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a reality
 
Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024Long journey of Ruby standard library at RubyConf AU 2024
Long journey of Ruby standard library at RubyConf AU 2024
 
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch Tuesday
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdf
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directions
 
Potential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and InsightsPotential of AI (Generative AI) in Business: Learnings and Insights
Potential of AI (Generative AI) in Business: Learnings and Insights
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI Age
 

Scripting Support in GFv3 Prelude - Full Version

  • 1. Dynamic Languages in GlassFish v3 Prelude GlassFish Webinar Vivek Pandey Developer, Glassfish Team Sun Microsysems, Inc. 1
  • 2. 2
  • 3. GlassFish v3 - A Dynamic AppServer Productivity, performance • GlassFish v3 > Lightweight, Modular, Extensible, Embeddable • Reasonable and efficient deployment choice > Native, WAR style, embedded GlassFish • App Server feature for everyone > Database connection pooling > Native threading, non-blocking IO, ARP > Management – Monitor, Deploy, Troubleshooting > Access to enterprise stack – Metro, Jersey, JMS/MQ, Grizzly, JBI etc. 3
  • 6. Why Ruby on GlassFish? • GlassFish v3 server is tested platform > Co-host Java and Rails > Known Deployment and Management • “Green” alternative – One command, One instance, One process • Multiple Requests by a Single Application • Database Connection Pooling • Not just Rails – Merb, Sinatra... 6
  • 7. More benefits... • No packaging, simple deployment > asadmin deploy depot/ • Deploy as WAR > warble #creates WAR file > asadmin deploy depot.war • Tested JRuby runtime at Updatecenter > bin/updatetool > No more config needed • Commercially supported by Sun • http://wiki.glassfish.java.net/Wiki.jsp?page=GettingStartedGuide 7
  • 8. GlassFish v3 Runtime Grizzly Listener . Rails Web . XXX Adapter Adapter Adapter . Rails Runtime Pool JRuby 8
  • 9. Runtime Pool Management • Automatic JRuby runtime pool management Gem Create JRuby Rails Startup Runtime JRuby Load Rails Environment Add to Rails Runtime Pool JRuby 9
  • 10. Configuring JRuby Runtime Pool • On GlassFish v3 Prelude Server > System properties – -Djruby.runtime.min : Sets the fewest runtimes to have in the pool – -Djruby.runtime : Sets the initial number of runtimes to create – -Djruby.runtime.max : Sets the maximum number of runtimes to have active > Add these system properties as <jvm-options> elements inside domain.xml > Or, if using java CLI simply provide it using -D option – java -Djruby.home=... -Djruby.runtime.max=2 -jar modules/glassfish.jar 10
  • 11. Configuring JRuby Runtime Pool • GlassFish gem > CLI options – -n, --runtimes – Number of JRuby runtimes to crete initially – --runtimes-min – Minimum JRuby runtimes to crete – --runtimes-max – Maximum number of JRuby runtimes to crete > glassfish -n 2 –runtimes-min 1 –runtimes-max 6 – Starts glassfish gem with 2 JRuby runtimes, the minimum pool size is 1 and maximum size it can grow up to is 6 11
  • 12. JRuby Bundle - Updatecenter • glassfish-install/bin/updatetool 12
  • 13. NetBeans Tooling • NetBeans support > Develop, deploy debug > Screencast – http://weblogs.java.net/blog/arungupta/archive/2008/11/screencast_26_d.html 13
  • 14. GlassFish gem • Rails developer friendly • Based on GlassFish v3 nucleus • Distributed as ruby gem • Install > gem install glassfish • Run > cd myAp > glassfish • More info > http://glassfishgem.rubyforge.org/ 14
  • 15. GlassFish Gem • Latest 0.9.0 released • Features > Rack based architecture – Pluggable ruby frameworks > Merb support – JRuby and Merb native extension issue $jruby -S gem install merb-core merb-more $merb-gen core hello $cd hello $glassfish • Framework auto-detection > Need just one command 'glassfish' • Details at: http://glassfishgems.rubyforge.org/ 15
  • 16. Demo – GlassFish Gem • Demo screencast > http://mediacast.sun.com/users/vivek.pandey/media/gemdemo 16
  • 18. Groovy on Grails • An MVC frameworks • Based on Groovy, Spring, Hibernate, SiteMesh > But hides all the complexity • Adopts Rails paradigms 18
  • 19. Grails – Setup and Installation • Install Grails IPS package using updatetool > Grails package is installed inside 'glassfish' directory • Grails IPS package > Provides the following benefits over Grails distributions found elsewhere – grails shaed-war – Lightweight, efficient application WAR – Less prone to OOM due to lack of PermGen space on hot deployments – grails run-app – Runs GlassFish v3 Prelude in embedded mode – Develop and test your grails app on the same server you would deploy during production • Set GRAILS_HOME environment variable > export GRAILS_HOME=glassfish-install/grails 19
  • 20. Groovy on Grails - Updatecenter • glassfish-install/bin/updatetool 20
  • 21. Groovy on Grails • Development and production on the same server > Develop using GlassFish v3 embedded server – grails run-app 21
  • 22. Groovy on Grails • Development and production on the same server > Develop using GlassFish v3 embedded server – grails run-app > Production deployment – asadmin deploy grailsApp.war 22
  • 23. Groovy on Grails • Development and production on the same server > Develop using GlassFish v3 embedded server – grails run-app > Production deployment – asadmin deploy grailsApp.war • Efficient WAR packaging > grails shared-war – Creates smaller WARs ~200KB vs 18MB – asadmin deploy –-libraries $GRAILS_HOME/lib/glassfish- grails.jar grailsApp.war 23
  • 24. Groovy on Grails • Development and production on the same server > Develop using GlassFish v3 embedded server – grails run-app > Production deployment – asadmin deploy grailsApp.war • Efficient WAR packaging > grails shared-war – Creates smaller WARs ~200KB vs 18MB – asadmin deploy –-libraries $GRAILS_HOME/lib/glassfish- grails grailsApp.war • For details > http://wiki.glassfish.java.net/Wiki.jsp?page=GrailsGettingStarted 24
  • 25. Groovy on Grails – Screencast • From Zero to Grails in 5 minutes with GlassFish v3 Prelude > https://slx.sun.com/1179271912 25
  • 26. Jython on Django • Jython 2.5 nearing release > Jython 2.5 beta out > Being developed at – http://www.jython.org/Project/ • Currently WAR deployment approach > Using Django-Jython project – http://django-jython.googlecode.com/ • Native Django application deployment in works 26
  • 27. PHP 27
  • 28. PHP • Quercus (Caucho) > Open Source (GPL) PHP 5 implementation in Java > WAR packaging > WordPress, MediaWiki, phpBB, Joomla • PHP/Java Bridge > Open Source (LGPL) > XML based network protocol for native PHP > Faster, easier than JNI > Java native threads used for concurrent requests > PHP and JSP session sharing 28
  • 30. Scala on Lift • Lifts apps packaged as WAR > asadmin deploy liftApp.war • For details on developing and deploying Lift applications see > http://wiki.glassfish.java.net/Wiki.jsp?page=GettingStartedWithLiftOnGlassFish 30
  • 31. References • GlassFish > https://glassfish.dev.java.net • GlassFish Scripting Project > https://glassfish-scripting.dev.java.net • Scripting Wiki > http://wiki.glassfish.java.net/Wiki.jsp?page=Scripting • Mailing List > webtier@glassfish.dev.java.net • IssueTracker > https://glassfish.dev.java.net/servlets/ProjectIssues • TheAquarium > http://blogs.sun.com/theaquarium 31
  • 32. Q&A 32